Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]
Groups > linux.kernel > #1492362 > unrolled thread
| Started by | Greg Kroah-Hartman <gregkh@linuxfoundation.org> |
|---|---|
| First post | 2016-09-28 11:10 +0200 |
| Last post | 2016-09-29 17:30 +0200 |
| Articles | 20 on this page of 70 — 4 participants |
Back to article view | Back to linux.kernel
[PATCH 4.7 00/69] 4.7.6-stable review Greg Kroah-Hartman <gregkh@linuxfoundation.org> - 2016-09-28 11:10 +0200
[PATCH 4.7 06/69] ocfs2/dlm: fix race between convert and migration Greg Kroah-Hartman <gregkh@linuxfoundation.org> - 2016-09-28 11:10 +0200
[PATCH 4.7 56/69] PM / hibernate: Restore processor state before using per-CPU variables Greg Kroah-Hartman <gregkh@linuxfoundation.org> - 2016-09-28 11:20 +0200
[PATCH 4.7 47/69] MIPS: Remove compact branch policy Kconfig entries Greg Kroah-Hartman <gregkh@linuxfoundation.org> - 2016-09-28 11:20 +0200
[PATCH 4.7 12/69] Makefile: Mute warning for __builtin_return_address(>0) for tracing only Greg Kroah-Hartman <gregkh@linuxfoundation.org> - 2016-09-28 11:20 +0200
[PATCH 4.7 66/69] kasan: avoid overflowing quarantine size on low memory systems Greg Kroah-Hartman <gregkh@linuxfoundation.org> - 2016-09-28 11:20 +0200
[PATCH 4.7 52/69] libceph: add an ONSTACK initializer for oids Greg Kroah-Hartman <gregkh@linuxfoundation.org> - 2016-09-28 11:20 +0200
[PATCH 4.7 38/69] btrfs: ensure that file descriptor used with subvol ioctls is a dir Greg Kroah-Hartman <gregkh@linuxfoundation.org> - 2016-09-28 11:20 +0200
[PATCH 4.7 57/69] PM / hibernate: Fix rtree_next_node() to avoid walking off list ends Greg Kroah-Hartman <gregkh@linuxfoundation.org> - 2016-09-28 11:20 +0200
[PATCH 4.7 51/69] x86/mm/pat: Prevent hang during boot when mapping pages Greg Kroah-Hartman <gregkh@linuxfoundation.org> - 2016-09-28 11:20 +0200
[PATCH 4.7 68/69] iw_cxgb4: stop MPA_REPLY timer when disconnecting Greg Kroah-Hartman <gregkh@linuxfoundation.org> - 2016-09-28 11:20 +0200
[PATCH 4.7 32/69] tracing: Move mutex to protect against resetting of seq data Greg Kroah-Hartman <gregkh@linuxfoundation.org> - 2016-09-28 11:20 +0200
[PATCH 4.7 13/69] xfs: prevent dropping ioend completions during buftarg wait Greg Kroah-Hartman <gregkh@linuxfoundation.org> - 2016-09-28 11:20 +0200
[PATCH 4.7 64/69] qxl: check for kmap failures Greg Kroah-Hartman <gregkh@linuxfoundation.org> - 2016-09-28 11:20 +0200
[PATCH 4.7 43/69] i2c: qup: skip qup_i2c_suspend if the device is already runtime suspended Greg Kroah-Hartman <gregkh@linuxfoundation.org> - 2016-09-28 11:20 +0200
[PATCH 4.7 27/69] reset: Return -ENOTSUPP when not configured Greg Kroah-Hartman <gregkh@linuxfoundation.org> - 2016-09-28 11:20 +0200
[PATCH 4.7 45/69] MIPS: SMP: Fix possibility of deadlock when bringing CPUs online Greg Kroah-Hartman <gregkh@linuxfoundation.org> - 2016-09-28 11:20 +0200
[PATCH 4.7 09/69] autofs: use dentry flags to block walks during expire Greg Kroah-Hartman <gregkh@linuxfoundation.org> - 2016-09-28 11:20 +0200
[PATCH 4.7 49/69] MIPS: Add a missing ".set pop" in an early commit Greg Kroah-Hartman <gregkh@linuxfoundation.org> - 2016-09-28 11:20 +0200
[PATCH 4.7 34/69] can: flexcan: fix resume function Greg Kroah-Hartman <gregkh@linuxfoundation.org> - 2016-09-28 11:20 +0200
[PATCH 4.7 62/69] igb: fix adjusting PTP timestamps for Tx/Rx latency Greg Kroah-Hartman <gregkh@linuxfoundation.org> - 2016-09-28 11:20 +0200
[PATCH 4.7 10/69] Disable "maybe-uninitialized" warning globally Greg Kroah-Hartman <gregkh@linuxfoundation.org> - 2016-09-28 11:20 +0200
[PATCH 4.7 61/69] ixgbe: Re-enable ability to toggle VLAN filtering Greg Kroah-Hartman <gregkh@linuxfoundation.org> - 2016-09-28 11:20 +0200
[PATCH 4.7 53/69] ceph: fix symbol versioning for ceph_monc_do_statfs Greg Kroah-Hartman <gregkh@linuxfoundation.org> - 2016-09-28 11:20 +0200
[PATCH 4.7 40/69] irqchip/mips-gic: Fix local interrupts Greg Kroah-Hartman <gregkh@linuxfoundation.org> - 2016-09-28 11:20 +0200
[PATCH 4.7 46/69] MIPS: vDSO: Fix Malta EVA mapping to vDSO page structs Greg Kroah-Hartman <gregkh@linuxfoundation.org> - 2016-09-28 11:20 +0200
[PATCH 4.7 29/69] power: reset: hisi-reboot: Unmap region obtained by of_iomap Greg Kroah-Hartman <gregkh@linuxfoundation.org> - 2016-09-28 11:20 +0200
[PATCH 4.7 41/69] i2c-eg20t: fix race between i2c init and interrupt enable Greg Kroah-Hartman <gregkh@linuxfoundation.org> - 2016-09-28 11:20 +0200
[PATCH 4.7 60/69] ixgbe: Force VLNCTRL.VFE to be set in all VMDq paths Greg Kroah-Hartman <gregkh@linuxfoundation.org> - 2016-09-28 11:20 +0200
[PATCH 4.7 55/69] libceph: fix return value check in alloc_msg_with_page_vector() Greg Kroah-Hartman <gregkh@linuxfoundation.org> - 2016-09-28 11:20 +0200
[PATCH 4.7 65/69] hostfs: Freeing an ERR_PTR in hostfs_fill_sb_common() Greg Kroah-Hartman <gregkh@linuxfoundation.org> - 2016-09-28 11:20 +0200
[PATCH 4.7 59/69] power: supply: max17042_battery: fix model download bug. Greg Kroah-Hartman <gregkh@linuxfoundation.org> - 2016-09-28 11:20 +0200
[PATCH 4.7 67/69] mm/kasan: dont reduce quarantine in atomic contexts Greg Kroah-Hartman <gregkh@linuxfoundation.org> - 2016-09-28 11:20 +0200
[PATCH 4.7 44/69] MIPS: Fix pre-r6 emulation FPU initialisation Greg Kroah-Hartman <gregkh@linuxfoundation.org> - 2016-09-28 11:20 +0200
[PATCH 4.7 48/69] MIPS: Avoid a BUG warning during prctl(PR_SET_FP_MODE, ...) Greg Kroah-Hartman <gregkh@linuxfoundation.org> - 2016-09-28 11:20 +0200
[PATCH 4.7 58/69] power_supply: tps65217-charger: fix missing platform_set_drvdata() Greg Kroah-Hartman <gregkh@linuxfoundation.org> - 2016-09-28 11:20 +0200
[PATCH 4.7 37/69] nl80211: validate number of probe response CSA counters Greg Kroah-Hartman <gregkh@linuxfoundation.org> - 2016-09-28 11:20 +0200
[PATCH 4.7 07/69] ocfs2: fix start offset to ocfs2_zero_range_for_truncate() Greg Kroah-Hartman <gregkh@linuxfoundation.org> - 2016-09-28 11:20 +0200
[PATCH 4.7 35/69] net: can: ifi: Configure transmitter delay Greg Kroah-Hartman <gregkh@linuxfoundation.org> - 2016-09-28 11:20 +0200
[PATCH 4.7 42/69] i2c: mux: pca954x: retry updating the mux selection on failure Greg Kroah-Hartman <gregkh@linuxfoundation.org> - 2016-09-28 11:20 +0200
[PATCH 4.7 63/69] soc/tegra: pmc: Dont probe PMC if early initialisation fails Greg Kroah-Hartman <gregkh@linuxfoundation.org> - 2016-09-28 11:20 +0200
[PATCH 4.7 25/69] mtd: pmcmsp-flash: Allocating too much in init_msp_flash() Greg Kroah-Hartman <gregkh@linuxfoundation.org> - 2016-09-28 11:30 +0200
[PATCH 4.7 36/69] iwlwifi: mvm: update TX queue before making a copy of the skb Greg Kroah-Hartman <gregkh@linuxfoundation.org> - 2016-09-28 11:30 +0200
[PATCH 4.7 22/69] configfs: Return -EFBIG from configfs_write_bin_file. Greg Kroah-Hartman <gregkh@linuxfoundation.org> - 2016-09-28 11:30 +0200
[PATCH 4.7 26/69] mtd: spi-nor: fix wrong "fully unlocked" test Greg Kroah-Hartman <gregkh@linuxfoundation.org> - 2016-09-28 11:30 +0200
[PATCH 4.7 31/69] fix memory leaks in tracing_buffers_splice_read() Greg Kroah-Hartman <gregkh@linuxfoundation.org> - 2016-09-28 11:30 +0200
[PATCH 4.7 20/69] KEYS: Fix skcipher IV clobbering Greg Kroah-Hartman <gregkh@linuxfoundation.org> - 2016-09-28 11:30 +0200
[PATCH 4.7 16/69] fanotify: fix list corruption in fanotify_get_response() Greg Kroah-Hartman <gregkh@linuxfoundation.org> - 2016-09-28 11:30 +0200
[PATCH 4.7 30/69] mac80211: reject TSPEC TIDs (TSIDs) for aggregation Greg Kroah-Hartman <gregkh@linuxfoundation.org> - 2016-09-28 11:30 +0200
[PATCH 4.7 18/69] cgroup: duplicate cgroup reference when cloning sockets Greg Kroah-Hartman <gregkh@linuxfoundation.org> - 2016-09-28 11:30 +0200
[PATCH 4.7 19/69] fix fault_in_multipages_...() on architectures with no-op access_ok() Greg Kroah-Hartman <gregkh@linuxfoundation.org> - 2016-09-28 11:30 +0200
[PATCH 4.7 17/69] mm: memcontrol: make per-cpu charge cache IRQ-safe for socket accounting Greg Kroah-Hartman <gregkh@linuxfoundation.org> - 2016-09-28 11:30 +0200
[PATCH 4.7 15/69] fsnotify: add a way to stop queueing events on group shutdown Greg Kroah-Hartman <gregkh@linuxfoundation.org> - 2016-09-28 11:30 +0200
[PATCH 4.7 33/69] mm: delete unnecessary and unsafe init_tlb_ubc() Greg Kroah-Hartman <gregkh@linuxfoundation.org> - 2016-09-28 11:30 +0200
[PATCH 4.7 08/69] Revert "ocfs2: bump up o2cb network protocol version" Greg Kroah-Hartman <gregkh@linuxfoundation.org> - 2016-09-28 11:30 +0200
[PATCH 4.7 28/69] rtc: ds1307: Fix relying on reset value for weekday Greg Kroah-Hartman <gregkh@linuxfoundation.org> - 2016-09-28 11:30 +0200
[PATCH 4.7 14/69] mm: fix the page_swap_info() BUG_ON check Greg Kroah-Hartman <gregkh@linuxfoundation.org> - 2016-09-28 11:30 +0200
[PATCH 4.7 39/69] x86/efi: Only map RAM into EFI page tables if in mixed-mode Greg Kroah-Hartman <gregkh@linuxfoundation.org> - 2016-09-28 11:30 +0200
[PATCH 4.7 24/69] mtd: maps: sa1100-flash: potential NULL dereference Greg Kroah-Hartman <gregkh@linuxfoundation.org> - 2016-09-28 11:30 +0200
[PATCH 4.7 50/69] MIPS: paravirt: Fix undefined reference to smp_bootstrap Greg Kroah-Hartman <gregkh@linuxfoundation.org> - 2016-09-28 11:30 +0200
[PATCH 4.7 54/69] ceph: Correctly return NXIO errors from ceph_llseek Greg Kroah-Hartman <gregkh@linuxfoundation.org> - 2016-09-28 11:30 +0200
[PATCH 4.7 21/69] arm64: Call numa_store_cpu_info() earlier. Greg Kroah-Hartman <gregkh@linuxfoundation.org> - 2016-09-28 11:30 +0200
[PATCH 4.7 04/69] crypto: skcipher - Fix blkcipher walk OOM crash Greg Kroah-Hartman <gregkh@linuxfoundation.org> - 2016-09-28 11:40 +0200
Re: [PATCH 4.7 00/69] 4.7.6-stable review Shuah Khan <shuah.kh@samsung.com> - 2016-09-28 18:50 +0200
Re: [PATCH 4.7 00/69] 4.7.6-stable review Greg Kroah-Hartman <gregkh@linuxfoundation.org> - 2016-09-29 11:10 +0200
Re: [PATCH 4.7 00/69] 4.7.6-stable review Guenter Roeck <linux@roeck-us.net> - 2016-09-29 00:50 +0200
Re: [PATCH 4.7 00/69] 4.7.6-stable review Greg Kroah-Hartman <gregkh@linuxfoundation.org> - 2016-09-29 11:10 +0200
Re: [PATCH 4.7 00/69] 4.7.6-stable review Greg Kroah-Hartman <gregkh@linuxfoundation.org> - 2016-09-29 10:40 +0200
Re: [PATCH 4.7 00/69] 4.7.6-stable review Kevin Hilman <khilman@baylibre.com> - 2016-09-29 16:50 +0200
Re: [PATCH 4.7 00/69] 4.7.6-stable review Greg Kroah-Hartman <gregkh@linuxfoundation.org> - 2016-09-29 17:30 +0200
Page 1 of 4 [1] 2 3 4 Next page →
| From | Greg Kroah-Hartman <gregkh@linuxfoundation.org> |
|---|---|
| Date | 2016-09-28 11:10 +0200 |
| Subject | [PATCH 4.7 00/69] 4.7.6-stable review |
| Message-ID | <smj2h-4LM-15@gated-at.bofh.it> |
This is the start of the stable review cycle for the 4.7.6 release.
There are 69 patches in this series, all will be posted as a response
to this one. If anyone has any issues with these being applied, please
let me know.
Responses should be made by Fri Sep 30 09:04:31 UTC 2016.
Anything received after that time might be too late.
The whole patch series can be found in one patch at:
kernel.org/pub/linux/kernel/v4.x/stable-review/patch-4.7.6-rc1.gz
or in the git tree and branch at:
git://git.kernel.org/pub/scm/linux/kernel/git/stable/linux-stable-rc.git linux-4.7.y
and the diffstat can be found below.
thanks,
greg k-h
-------------
Pseudo-Shortlog of commits:
Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Linux 4.7.6-rc1
Wilfried Klaebe <linux-kernel@lebenslange-mailadresse.de>
builddeb: really include objtool binary in headers package
Steve Wise <swise@opengridcomputing.com>
iw_cxgb4: stop MPA_REPLY timer when disconnecting
Andrey Ryabinin <aryabinin@virtuozzo.com>
mm/kasan: don't reduce quarantine in atomic contexts
Alexander Potapenko <glider@google.com>
kasan: avoid overflowing quarantine size on low memory systems
Dan Carpenter <dan.carpenter@oracle.com>
hostfs: Freeing an ERR_PTR in hostfs_fill_sb_common()
Dan Carpenter <dan.carpenter@oracle.com>
qxl: check for kmap failures
Jon Hunter <jonathanh@nvidia.com>
soc/tegra: pmc: Don't probe PMC if early initialisation fails
Kshitiz Gupta <kshitiz.gupta@ni.com>
igb: fix adjusting PTP timestamps for Tx/Rx latency
Alexander Duyck <alexander.h.duyck@intel.com>
ixgbe: Re-enable ability to toggle VLAN filtering
Alexander Duyck <alexander.h.duyck@intel.com>
ixgbe: Force VLNCTRL.VFE to be set in all VMDq paths
Sven Van Asbroeck <thesven73@gmail.com>
power: supply: max17042_battery: fix model download bug.
Wei Yongjun <weiyj.lk@gmail.com>
power_supply: tps65217-charger: fix missing platform_set_drvdata()
James Morse <james.morse@arm.com>
PM / hibernate: Fix rtree_next_node() to avoid walking off list ends
Thomas Garnier <thgarnie@google.com>
PM / hibernate: Restore processor state before using per-CPU variables
Wei Yongjun <weiyj.lk@gmail.com>
libceph: fix return value check in alloc_msg_with_page_vector()
Phil Turnbull <phil.turnbull@oracle.com>
ceph: Correctly return NXIO errors from ceph_llseek
Arnd Bergmann <arnd@arndb.de>
ceph: fix symbol versioning for ceph_monc_do_statfs
Ilya Dryomov <idryomov@gmail.com>
libceph: add an ONSTACK initializer for oids
Matt Fleming <matt@codeblueprint.co.uk>
x86/mm/pat: Prevent hang during boot when mapping pages
Matt Redfearn <matt.redfearn@imgtec.com>
MIPS: paravirt: Fix undefined reference to smp_bootstrap
Huacai Chen <chenhc@lemote.com>
MIPS: Add a missing ".set pop" in an early commit
Marcin Nowakowski <marcin.nowakowski@imgtec.com>
MIPS: Avoid a BUG warning during prctl(PR_SET_FP_MODE, ...)
Paul Burton <paul.burton@imgtec.com>
MIPS: Remove compact branch policy Kconfig entries
James Hogan <james.hogan@imgtec.com>
MIPS: vDSO: Fix Malta EVA mapping to vDSO page structs
Matt Redfearn <matt.redfearn@imgtec.com>
MIPS: SMP: Fix possibility of deadlock when bringing CPUs online
Paul Burton <paul.burton@imgtec.com>
MIPS: Fix pre-r6 emulation FPU initialisation
Sudeep Holla <Sudeep.Holla@arm.com>
i2c: qup: skip qup_i2c_suspend if the device is already runtime suspended
Peter Rosin <peda@axentia.se>
i2c: mux: pca954x: retry updating the mux selection on failure
Yadi.hu <yadi.hu@windriver.com>
i2c-eg20t: fix race between i2c init and interrupt enable
Paul Burton <paul.burton@imgtec.com>
irqchip/mips-gic: Fix local interrupts
Matt Fleming <matt@codeblueprint.co.uk>
x86/efi: Only map RAM into EFI page tables if in mixed-mode
Jeff Mahoney <jeffm@suse.com>
btrfs: ensure that file descriptor used with subvol ioctls is a dir
Johannes Berg <johannes.berg@intel.com>
nl80211: validate number of probe response CSA counters
Beni Lev <beni.lev@intel.com>
iwlwifi: mvm: update TX queue before making a copy of the skb
Marek Vasut <marex@denx.de>
net: can: ifi: Configure transmitter delay
Fabio Estevam <fabio.estevam@nxp.com>
can: flexcan: fix resume function
Hugh Dickins <hughd@google.com>
mm: delete unnecessary and unsafe init_tlb_ubc()
Steven Rostedt (Red Hat) <rostedt@goodmis.org>
tracing: Move mutex to protect against resetting of seq data
Al Viro <viro@zeniv.linux.org.uk>
fix memory leaks in tracing_buffers_splice_read()
Johannes Berg <johannes.berg@intel.com>
mac80211: reject TSPEC TIDs (TSIDs) for aggregation
Arvind Yadav <arvind.yadav.cs@gmail.com>
power: reset: hisi-reboot: Unmap region obtained by of_iomap
Keerthy <j-keerthy@ti.com>
rtc: ds1307: Fix relying on reset value for weekday
John Youn <johnyoun@synopsys.com>
reset: Return -ENOTSUPP when not configured
Brian Norris <computersforpeace@gmail.com>
mtd: spi-nor: fix wrong "fully unlocked" test
Dan Carpenter <dan.carpenter@oracle.com>
mtd: pmcmsp-flash: Allocating too much in init_msp_flash()
Dan Carpenter <dan.carpenter@oracle.com>
mtd: maps: sa1100-flash: potential NULL dereference
Lothar Waßmann <LW@KARO-electronics.de>
mtd: nand: mxc: fix obiwan error in mxc_nand_v[12]_ooblayout_free() functions
Phil Turnbull <phil.turnbull@oracle.com>
configfs: Return -EFBIG from configfs_write_bin_file.
David Daney <david.daney@cavium.com>
arm64: Call numa_store_cpu_info() earlier.
Herbert Xu <herbert@gondor.apana.org.au>
KEYS: Fix skcipher IV clobbering
Al Viro <viro@ZenIV.linux.org.uk>
fix fault_in_multipages_...() on architectures with no-op access_ok()
Johannes Weiner <jweiner@fb.com>
cgroup: duplicate cgroup reference when cloning sockets
Johannes Weiner <jweiner@fb.com>
mm: memcontrol: make per-cpu charge cache IRQ-safe for socket accounting
Jan Kara <jack@suse.cz>
fanotify: fix list corruption in fanotify_get_response()
Jan Kara <jack@suse.cz>
fsnotify: add a way to stop queueing events on group shutdown
Santosh Shilimkar <santosh.shilimkar@oracle.com>
mm: fix the page_swap_info() BUG_ON check
Brian Foster <bfoster@redhat.com>
xfs: prevent dropping ioend completions during buftarg wait
Steven Rostedt <rostedt@goodmis.org>
Makefile: Mute warning for __builtin_return_address(>0) for tracing only
Linus Torvalds <torvalds@linux-foundation.org>
Disable "frame-address" warning
Linus Torvalds <torvalds@linux-foundation.org>
Disable "maybe-uninitialized" warning globally
Ian Kent <raven@themaw.net>
autofs: use dentry flags to block walks during expire
Junxiao Bi <junxiao.bi@oracle.com>
Revert "ocfs2: bump up o2cb network protocol version"
Ashish Samant <ashish.samant@oracle.com>
ocfs2: fix start offset to ocfs2_zero_range_for_truncate()
Joseph Qi <joseph.qi@huawei.com>
ocfs2/dlm: fix race between convert and migration
Herbert Xu <herbert@gondor.apana.org.au>
crypto: echainiv - Replace chaining with multiplication
Herbert Xu <herbert@gondor.apana.org.au>
crypto: skcipher - Fix blkcipher walk OOM crash
Ard Biesheuvel <ard.biesheuvel@linaro.org>
crypto: arm/aes-ctr - fix NULL dereference in tail processing
Ard Biesheuvel <ard.biesheuvel@linaro.org>
crypto: arm64/aes-ctr - fix NULL dereference in tail processing
Jeff Mahoney <jeffm@suse.com>
reiserfs: fix "new_insert_key may be used uninitialized ..."
-------------
Diffstat:
Makefile | 11 +-
arch/arc/Makefile | 4 +-
arch/arm/crypto/aes-ce-glue.c | 2 +-
arch/arm64/crypto/aes-glue.c | 2 +-
arch/arm64/kernel/smp.c | 14 ++-
arch/mips/Kconfig.debug | 36 -------
arch/mips/Makefile | 4 -
arch/mips/include/asm/asmmacro.h | 1 +
.../include/asm/mach-paravirt/kernel-entry-init.h | 2 +
arch/mips/kernel/mips-r2-to-r6-emul.c | 2 +
arch/mips/kernel/process.c | 8 +-
arch/mips/kernel/smp.c | 7 +-
arch/mips/kernel/vdso.c | 8 +-
arch/x86/mm/pageattr.c | 21 ++--
arch/x86/platform/efi/efi_64.c | 2 +-
crypto/blkcipher.c | 3 +-
crypto/echainiv.c | 115 +++++----------------
drivers/gpu/drm/qxl/qxl_draw.c | 2 +
drivers/i2c/busses/i2c-eg20t.c | 18 ++--
drivers/i2c/busses/i2c-qup.c | 3 +-
drivers/i2c/muxes/i2c-mux-pca954x.c | 2 +-
drivers/infiniband/hw/cxgb4/cm.c | 12 ++-
drivers/irqchip/irq-mips-gic.c | 105 +++++++++----------
drivers/mtd/maps/pmcmsp-flash.c | 6 +-
drivers/mtd/maps/sa1100-flash.c | 4 +-
drivers/mtd/nand/mxc_nand.c | 2 +-
drivers/mtd/spi-nor/spi-nor.c | 2 +-
drivers/net/can/flexcan.c | 13 ++-
drivers/net/can/ifi_canfd/ifi_canfd.c | 11 +-
drivers/net/ethernet/intel/igb/igb_ptp.c | 26 ++++-
drivers/net/ethernet/intel/ixgbe/ixgbe_main.c | 19 ++--
drivers/net/wireless/intel/iwlwifi/mvm/tx.c | 19 ++--
drivers/power/max17042_battery.c | 15 +--
drivers/power/reset/hisi-reboot.c | 5 +-
drivers/power/tps65217_charger.c | 1 +
drivers/rtc/rtc-ds1307.c | 28 ++++-
drivers/soc/tegra/pmc.c | 8 ++
fs/autofs4/expire.c | 55 +++++++---
fs/btrfs/ioctl.c | 12 +++
fs/ceph/file.c | 12 +--
fs/ceph/ioctl.c | 2 +-
fs/configfs/file.c | 1 +
fs/hostfs/hostfs_kern.c | 7 +-
fs/notify/fanotify/fanotify.c | 13 +--
fs/notify/fanotify/fanotify_user.c | 36 ++++---
fs/notify/group.c | 19 ++++
fs/notify/notification.c | 23 ++---
fs/ocfs2/cluster/tcp_internal.h | 5 +-
fs/ocfs2/dlm/dlmconvert.c | 12 +--
fs/ocfs2/file.c | 34 ++++--
fs/reiserfs/ibalance.c | 3 +-
fs/xfs/xfs_buf.c | 2 +-
include/linux/ceph/libceph.h | 3 +-
include/linux/ceph/osdmap.h | 5 +
include/linux/fsnotify_backend.h | 6 +-
include/linux/pagemap.h | 38 +++----
include/linux/reset.h | 4 +-
kernel/cgroup.c | 6 ++
kernel/power/hibernate.c | 4 +-
kernel/power/snapshot.c | 10 +-
kernel/trace/Makefile | 4 +
kernel/trace/trace.c | 29 +++---
mm/kasan/kasan.c | 4 +-
mm/kasan/quarantine.c | 9 +-
mm/memcontrol.c | 31 ++++--
mm/page_io.c | 3 +
mm/swapfile.c | 1 -
mm/vmscan.c | 19 ----
net/ceph/osd_client.c | 2 +-
net/core/sock.c | 5 +-
net/mac80211/agg-rx.c | 8 +-
net/mac80211/agg-tx.c | 3 +
net/wireless/nl80211.c | 2 +-
scripts/Makefile.ubsan | 4 -
scripts/package/builddeb | 6 +-
security/keys/encrypted-keys/encrypted.c | 11 +-
76 files changed, 540 insertions(+), 456 deletions(-)
[toc] | [next] | [standalone]
| From | Greg Kroah-Hartman <gregkh@linuxfoundation.org> |
|---|---|
| Date | 2016-09-28 11:10 +0200 |
| Subject | [PATCH 4.7 06/69] ocfs2/dlm: fix race between convert and migration |
| Message-ID | <smj2i-4LM-29@gated-at.bofh.it> |
| In reply to | #1492362 |
4.7-stable review patch. If anyone has any objections, please let me know.
------------------
From: Joseph Qi <joseph.qi@huawei.com>
commit e6f0c6e6170fec175fe676495f29029aecdf486c upstream.
Commit ac7cf246dfdb ("ocfs2/dlm: fix race between convert and recovery")
checks if lockres master has changed to identify whether new master has
finished recovery or not. This will introduce a race that right after
old master does umount ( means master will change), a new convert
request comes.
In this case, it will reset lockres state to DLM_RECOVERING and then
retry convert, and then fail with lockres->l_action being set to
OCFS2_AST_INVALID, which will cause inconsistent lock level between
ocfs2 and dlm, and then finally BUG.
Since dlm recovery will clear lock->convert_pending in
dlm_move_lockres_to_recovery_list, we can use it to correctly identify
the race case between convert and recovery. So fix it.
Fixes: ac7cf246dfdb ("ocfs2/dlm: fix race between convert and recovery")
Link: http://lkml.kernel.org/r/57CE1569.8010704@huawei.com
Signed-off-by: Joseph Qi <joseph.qi@huawei.com>
Signed-off-by: Jun Piao <piaojun@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>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
---
fs/ocfs2/dlm/dlmconvert.c | 12 ++++++------
1 file changed, 6 insertions(+), 6 deletions(-)
--- a/fs/ocfs2/dlm/dlmconvert.c
+++ b/fs/ocfs2/dlm/dlmconvert.c
@@ -268,7 +268,6 @@ enum dlm_status dlmconvert_remote(struct
struct dlm_lock *lock, int flags, int type)
{
enum dlm_status status;
- u8 old_owner = res->owner;
mlog(0, "type=%d, convert_type=%d, busy=%d\n", lock->ml.type,
lock->ml.convert_type, res->state & DLM_LOCK_RES_IN_PROGRESS);
@@ -335,7 +334,6 @@ enum dlm_status dlmconvert_remote(struct
spin_lock(&res->spinlock);
res->state &= ~DLM_LOCK_RES_IN_PROGRESS;
- lock->convert_pending = 0;
/* if it failed, move it back to granted queue.
* if master returns DLM_NORMAL and then down before sending ast,
* it may have already been moved to granted queue, reset to
@@ -344,12 +342,14 @@ enum dlm_status dlmconvert_remote(struct
if (status != DLM_NOTQUEUED)
dlm_error(status);
dlm_revert_pending_convert(res, lock);
- } else if ((res->state & DLM_LOCK_RES_RECOVERING) ||
- (old_owner != res->owner)) {
- mlog(0, "res %.*s is in recovering or has been recovered.\n",
- res->lockname.len, res->lockname.name);
+ } else if (!lock->convert_pending) {
+ mlog(0, "%s: res %.*s, owner died and lock has been moved back "
+ "to granted list, retry convert.\n",
+ dlm->name, res->lockname.len, res->lockname.name);
status = DLM_RECOVERING;
}
+
+ lock->convert_pending = 0;
bail:
spin_unlock(&res->spinlock);
[toc] | [prev] | [next] | [standalone]
| From | Greg Kroah-Hartman <gregkh@linuxfoundation.org> |
|---|---|
| Date | 2016-09-28 11:20 +0200 |
| Subject | [PATCH 4.7 56/69] PM / hibernate: Restore processor state before using per-CPU variables |
| Message-ID | <smjbX-4Pw-3@gated-at.bofh.it> |
| In reply to | #1492362 |
4.7-stable review patch. If anyone has any objections, please let me know.
------------------
From: Thomas Garnier <thgarnie@google.com>
commit 62822e2ec4ad091ba31f823f577ef80db52e3c2c upstream.
Restore the processor state before calling any other functions to
ensure per-CPU variables can be used with KASLR memory randomization.
Tracing functions use per-CPU variables (GS based on x86) and one was
called just before restoring the processor state fully. It resulted
in a double fault when both the tracing & the exception handler
functions tried to use a per-CPU variable.
Fixes: bb3632c6101b (PM / sleep: trace events for suspend/resume)
Reported-and-tested-by: Borislav Petkov <bp@suse.de>
Reported-by: Jiri Kosina <jikos@kernel.org>
Tested-by: Rafael J. Wysocki <rafael@kernel.org>
Tested-by: Jiri Kosina <jkosina@suse.cz>
Signed-off-by: Thomas Garnier <thgarnie@google.com>
Acked-by: Pavel Machek <pavel@ucw.cz>
Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
---
kernel/power/hibernate.c | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
--- a/kernel/power/hibernate.c
+++ b/kernel/power/hibernate.c
@@ -299,12 +299,12 @@ static int create_image(int platform_mod
save_processor_state();
trace_suspend_resume(TPS("machine_suspend"), PM_EVENT_HIBERNATE, true);
error = swsusp_arch_suspend();
+ /* Restore control flow magically appears here */
+ restore_processor_state();
trace_suspend_resume(TPS("machine_suspend"), PM_EVENT_HIBERNATE, false);
if (error)
printk(KERN_ERR "PM: Error %d creating hibernation image\n",
error);
- /* Restore control flow magically appears here */
- restore_processor_state();
if (!in_suspend)
events_check_enabled = false;
[toc] | [prev] | [next] | [standalone]
| From | Greg Kroah-Hartman <gregkh@linuxfoundation.org> |
|---|---|
| Date | 2016-09-28 11:20 +0200 |
| Subject | [PATCH 4.7 47/69] MIPS: Remove compact branch policy Kconfig entries |
| Message-ID | <smjbX-4Pw-1@gated-at.bofh.it> |
| In reply to | #1492362 |
4.7-stable review patch. If anyone has any objections, please let me know.
------------------
From: Paul Burton <paul.burton@imgtec.com>
commit b03c1e3b8eed9026733c473071d1f528358a0e50 upstream.
Commit c1a0e9bc885d ("MIPS: Allow compact branch policy to be changed")
added Kconfig entries allowing for the compact branch policy used by the
compiler for MIPSr6 kernels to be specified. This can be useful for
debugging, particularly in systems where compact branches have recently
been introduced.
Unfortunately mainline gcc 5.x supports MIPSr6 but not the
-mcompact-branches compiler flag, leading to MIPSr6 kernels failing to
build with gcc 5.x with errors such as:
mipsel-linux-gnu-gcc: error: unrecognized command line option '-mcompact-branches=optimal'
make[2]: *** [kernel/bounds.s] Error 1
Fixing this by hiding the Kconfig entry behind another seems to be more
hassle than it's worth, as MIPSr6 & compact branches have been around
for a while now and if policy does need to be set for debug it can be
done easily enough with KCFLAGS. Therefore remove the compact branch
policy Kconfig entries & their handling in the Makefile.
This reverts commit c1a0e9bc885d ("MIPS: Allow compact branch policy to
be changed").
Signed-off-by: Paul Burton <paul.burton@imgtec.com>
Reported-by: kbuild test robot <fengguang.wu@intel.com>
Fixes: c1a0e9bc885d ("MIPS: Allow compact branch policy to be changed")
Cc: linux-mips@linux-mips.org
Patchwork: https://patchwork.linux-mips.org/patch/14241/
Signed-off-by: Ralf Baechle <ralf@linux-mips.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
---
arch/mips/Kconfig.debug | 36 ------------------------------------
arch/mips/Makefile | 4 ----
2 files changed, 40 deletions(-)
--- a/arch/mips/Kconfig.debug
+++ b/arch/mips/Kconfig.debug
@@ -113,42 +113,6 @@ config SPINLOCK_TEST
help
Add several files to the debugfs to test spinlock speed.
-if CPU_MIPSR6
-
-choice
- prompt "Compact branch policy"
- default MIPS_COMPACT_BRANCHES_OPTIMAL
-
-config MIPS_COMPACT_BRANCHES_NEVER
- bool "Never (force delay slot branches)"
- help
- Pass the -mcompact-branches=never flag to the compiler in order to
- force it to always emit branches with delay slots, and make no use
- of the compact branch instructions introduced by MIPSr6. This is
- useful if you suspect there may be an issue with compact branches in
- either the compiler or the CPU.
-
-config MIPS_COMPACT_BRANCHES_OPTIMAL
- bool "Optimal (use where beneficial)"
- help
- Pass the -mcompact-branches=optimal flag to the compiler in order for
- it to make use of compact branch instructions where it deems them
- beneficial, and use branches with delay slots elsewhere. This is the
- default compiler behaviour, and should be used unless you have a
- reason to choose otherwise.
-
-config MIPS_COMPACT_BRANCHES_ALWAYS
- bool "Always (force compact branches)"
- help
- Pass the -mcompact-branches=always flag to the compiler in order to
- force it to always emit compact branches, making no use of branch
- instructions with delay slots. This can result in more compact code
- which may be beneficial in some scenarios.
-
-endchoice
-
-endif # CPU_MIPSR6
-
config SCACHE_DEBUGFS
bool "L2 cache debugfs entries"
depends on DEBUG_FS
--- a/arch/mips/Makefile
+++ b/arch/mips/Makefile
@@ -203,10 +203,6 @@ endif
toolchain-virt := $(call cc-option-yn,$(mips-cflags) -mvirt)
cflags-$(toolchain-virt) += -DTOOLCHAIN_SUPPORTS_VIRT
-cflags-$(CONFIG_MIPS_COMPACT_BRANCHES_NEVER) += -mcompact-branches=never
-cflags-$(CONFIG_MIPS_COMPACT_BRANCHES_OPTIMAL) += -mcompact-branches=optimal
-cflags-$(CONFIG_MIPS_COMPACT_BRANCHES_ALWAYS) += -mcompact-branches=always
-
#
# Firmware support
#
[toc] | [prev] | [next] | [standalone]
| From | Greg Kroah-Hartman <gregkh@linuxfoundation.org> |
|---|---|
| Date | 2016-09-28 11:20 +0200 |
| Subject | [PATCH 4.7 12/69] Makefile: Mute warning for __builtin_return_address(>0) for tracing only |
| Message-ID | <smjbX-4Pw-5@gated-at.bofh.it> |
| In reply to | #1492362 |
4.7-stable review patch. If anyone has any objections, please let me know. ------------------ From: Steven Rostedt <rostedt@goodmis.org> commit 377ccbb483738f84400ddf5840c7dd8825716985 upstream. With the latest gcc compilers, they give a warning if __builtin_return_address() parameter is greater than 0. That is because if it is used by a function called by a top level function (or in the case of the kernel, by assembly), it can try to access stack frames outside the stack and crash the system. The tracing system uses __builtin_return_address() of up to 2! But it is well aware of the dangers that it may have, and has even added precautions to protect against it (see the thunk code in arch/x86/entry/thunk*.S) Linus originally added KBUILD_CFLAGS that would suppress the warning for the entire kernel, as simply adding KBUILD_CFLAGS to the tracing directory wouldn't work. The tracing directory plays a bit with the CFLAGS and requires a little more logic. This adds that special logic to only suppress the warning for the tracing directory. If it is used anywhere else outside of tracing, the warning will still be triggered. Link: http://lkml.kernel.org/r/20160728223043.51996267@grimm.local.home Tested-by: Linus Torvalds <torvalds@linux-foundation.org> Signed-off-by: Steven Rostedt <rostedt@goodmis.org> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> --- Makefile | 1 - kernel/trace/Makefile | 4 ++++ 2 files changed, 4 insertions(+), 1 deletion(-) --- a/Makefile +++ b/Makefile @@ -620,7 +620,6 @@ include arch/$(SRCARCH)/Makefile KBUILD_CFLAGS += $(call cc-option,-fno-delete-null-pointer-checks,) KBUILD_CFLAGS += $(call cc-disable-warning,maybe-uninitialized,) -KBUILD_CFLAGS += $(call cc-disable-warning,frame-address,) ifdef CONFIG_CC_OPTIMIZE_FOR_SIZE KBUILD_CFLAGS += -Os --- a/kernel/trace/Makefile +++ b/kernel/trace/Makefile @@ -1,4 +1,8 @@ +# We are fully aware of the dangers of __builtin_return_address() +FRAME_CFLAGS := $(call cc-disable-warning,frame-address) +KBUILD_CFLAGS += $(FRAME_CFLAGS) + # Do not instrument the tracer itself: ifdef CONFIG_FUNCTION_TRACER
[toc] | [prev] | [next] | [standalone]
| From | Greg Kroah-Hartman <gregkh@linuxfoundation.org> |
|---|---|
| Date | 2016-09-28 11:20 +0200 |
| Subject | [PATCH 4.7 66/69] kasan: avoid overflowing quarantine size on low memory systems |
| Message-ID | <smjbY-4Pw-11@gated-at.bofh.it> |
| In reply to | #1492362 |
4.7-stable review patch. If anyone has any objections, please let me know.
------------------
From: Alexander Potapenko <glider@google.com>
commit c3cee372282cb6bcdf19ac1457581d5dd5ecb554 upstream.
If the total amount of memory assigned to quarantine is less than the
amount of memory assigned to per-cpu quarantines, |new_quarantine_size|
may overflow. Instead, set it to zero.
[akpm@linux-foundation.org: cleanup: use WARN_ONCE return value]
Link: http://lkml.kernel.org/r/1470063563-96266-1-git-send-email-glider@google.com
Fixes: 55834c59098d ("mm: kasan: initial memory quarantine implementation")
Signed-off-by: Alexander Potapenko <glider@google.com>
Reported-by: Dmitry Vyukov <dvyukov@google.com>
Cc: Andrey Ryabinin <aryabinin@virtuozzo.com>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
---
mm/kasan/quarantine.c | 9 +++++++--
1 file changed, 7 insertions(+), 2 deletions(-)
--- a/mm/kasan/quarantine.c
+++ b/mm/kasan/quarantine.c
@@ -196,7 +196,7 @@ void quarantine_put(struct kasan_free_me
void quarantine_reduce(void)
{
- size_t new_quarantine_size;
+ size_t new_quarantine_size, percpu_quarantines;
unsigned long flags;
struct qlist_head to_free = QLIST_INIT;
size_t size_to_free = 0;
@@ -214,7 +214,12 @@ void quarantine_reduce(void)
*/
new_quarantine_size = (READ_ONCE(totalram_pages) << PAGE_SHIFT) /
QUARANTINE_FRACTION;
- new_quarantine_size -= QUARANTINE_PERCPU_SIZE * num_online_cpus();
+ percpu_quarantines = QUARANTINE_PERCPU_SIZE * num_online_cpus();
+ if (WARN_ONCE(new_quarantine_size < percpu_quarantines,
+ "Too little memory, disabling global KASAN quarantine.\n"))
+ new_quarantine_size = 0;
+ else
+ new_quarantine_size -= percpu_quarantines;
WRITE_ONCE(quarantine_size, new_quarantine_size);
last = global_quarantine.head;
[toc] | [prev] | [next] | [standalone]
| From | Greg Kroah-Hartman <gregkh@linuxfoundation.org> |
|---|---|
| Date | 2016-09-28 11:20 +0200 |
| Subject | [PATCH 4.7 52/69] libceph: add an ONSTACK initializer for oids |
| Message-ID | <smjbY-4Pw-17@gated-at.bofh.it> |
| In reply to | #1492362 |
4.7-stable review patch. If anyone has any objections, please let me know.
------------------
From: Ilya Dryomov <idryomov@gmail.com>
commit 281dbe5db81c6137def9757e07a7aea14b1ed86e upstream.
An on-stack oid in ceph_ioctl_get_dataloc() is not initialized,
resulting in a WARN and a NULL pointer dereference later on. We will
have more of these on-stack in the future, so fix it with a convenience
macro.
Fixes: d30291b985d1 ("libceph: variable-sized ceph_object_id")
Signed-off-by: Ilya Dryomov <idryomov@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
---
fs/ceph/ioctl.c | 2 +-
include/linux/ceph/osdmap.h | 5 +++++
2 files changed, 6 insertions(+), 1 deletion(-)
--- a/fs/ceph/ioctl.c
+++ b/fs/ceph/ioctl.c
@@ -183,7 +183,7 @@ static long ceph_ioctl_get_dataloc(struc
struct ceph_osd_client *osdc =
&ceph_sb_to_client(inode->i_sb)->client->osdc;
struct ceph_object_locator oloc;
- struct ceph_object_id oid;
+ CEPH_DEFINE_OID_ONSTACK(oid);
u64 len = 1, olen;
u64 tmp;
struct ceph_pg pgid;
--- a/include/linux/ceph/osdmap.h
+++ b/include/linux/ceph/osdmap.h
@@ -115,6 +115,11 @@ static inline void ceph_oid_init(struct
oid->name_len = 0;
}
+#define CEPH_OID_INIT_ONSTACK(oid) \
+ ({ ceph_oid_init(&oid); oid; })
+#define CEPH_DEFINE_OID_ONSTACK(oid) \
+ struct ceph_object_id oid = CEPH_OID_INIT_ONSTACK(oid)
+
static inline bool ceph_oid_empty(const struct ceph_object_id *oid)
{
return oid->name == oid->inline_name && !oid->name_len;
[toc] | [prev] | [next] | [standalone]
| From | Greg Kroah-Hartman <gregkh@linuxfoundation.org> |
|---|---|
| Date | 2016-09-28 11:20 +0200 |
| Subject | [PATCH 4.7 38/69] btrfs: ensure that file descriptor used with subvol ioctls is a dir |
| Message-ID | <smjbY-4Pw-21@gated-at.bofh.it> |
| In reply to | #1492362 |
4.7-stable review patch. If anyone has any objections, please let me know. ------------------ From: Jeff Mahoney <jeffm@suse.com> commit 325c50e3cebb9208009083e841550f98a863bfa0 upstream. If the subvol/snapshot create/destroy ioctls are passed a regular file with execute permissions set, we'll eventually Oops while trying to do inode->i_op->lookup via lookup_one_len. This patch ensures that the file descriptor refers to a directory. Fixes: cb8e70901d (Btrfs: Fix subvolume creation locking rules) Fixes: 76dda93c6a (Btrfs: add snapshot/subvolume destroy ioctl) Signed-off-by: Jeff Mahoney <jeffm@suse.com> Signed-off-by: Chris Mason <clm@fb.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> --- fs/btrfs/ioctl.c | 12 ++++++++++++ 1 file changed, 12 insertions(+) --- a/fs/btrfs/ioctl.c +++ b/fs/btrfs/ioctl.c @@ -1634,6 +1634,9 @@ static noinline int btrfs_ioctl_snap_cre int namelen; int ret = 0; + if (!S_ISDIR(file_inode(file)->i_mode)) + return -ENOTDIR; + ret = mnt_want_write_file(file); if (ret) goto out; @@ -1691,6 +1694,9 @@ static noinline int btrfs_ioctl_snap_cre struct btrfs_ioctl_vol_args *vol_args; int ret; + if (!S_ISDIR(file_inode(file)->i_mode)) + return -ENOTDIR; + vol_args = memdup_user(arg, sizeof(*vol_args)); if (IS_ERR(vol_args)) return PTR_ERR(vol_args); @@ -1714,6 +1720,9 @@ static noinline int btrfs_ioctl_snap_cre bool readonly = false; struct btrfs_qgroup_inherit *inherit = NULL; + if (!S_ISDIR(file_inode(file)->i_mode)) + return -ENOTDIR; + vol_args = memdup_user(arg, sizeof(*vol_args)); if (IS_ERR(vol_args)) return PTR_ERR(vol_args); @@ -2358,6 +2367,9 @@ static noinline int btrfs_ioctl_snap_des int ret; int err = 0; + if (!S_ISDIR(dir->i_mode)) + return -ENOTDIR; + vol_args = memdup_user(arg, sizeof(*vol_args)); if (IS_ERR(vol_args)) return PTR_ERR(vol_args);
[toc] | [prev] | [next] | [standalone]
| From | Greg Kroah-Hartman <gregkh@linuxfoundation.org> |
|---|---|
| Date | 2016-09-28 11:20 +0200 |
| Subject | [PATCH 4.7 57/69] PM / hibernate: Fix rtree_next_node() to avoid walking off list ends |
| Message-ID | <smjbY-4Pw-19@gated-at.bofh.it> |
| In reply to | #1492362 |
4.7-stable review patch. If anyone has any objections, please let me know.
------------------
From: James Morse <james.morse@arm.com>
commit 924d8696751c4b9e58263bc82efdafcf875596a6 upstream.
rtree_next_node() walks the linked list of leaf nodes to find the next
block of pages in the struct memory_bitmap. If it walks off the end of
the list of nodes, it walks the list of memory zones to find the next
region of memory. If it walks off the end of the list of zones, it
returns false.
This leaves the struct bm_position's node and zone pointers pointing
at their respective struct list_heads in struct mem_zone_bm_rtree.
memory_bm_find_bit() uses struct bm_position's node and zone pointers
to avoid walking lists and trees if the next bit appears in the same
node/zone. It handles these values being stale.
Swap rtree_next_node()s 'step then test' to 'test-next then step',
this means if we reach the end of memory we return false and leave
the node and zone pointers as they were.
This fixes a panic on resume using AMD Seattle with 64K pages:
[ 6.868732] Freezing user space processes ... (elapsed 0.000 seconds) done.
[ 6.875753] Double checking all user space processes after OOM killer disable... (elapsed 0.000 seconds)
[ 6.896453] PM: Using 3 thread(s) for decompression.
[ 6.896453] PM: Loading and decompressing image data (5339 pages)...
[ 7.318890] PM: Image loading progress: 0%
[ 7.323395] Unable to handle kernel paging request at virtual address 00800040
[ 7.330611] pgd = ffff000008df0000
[ 7.334003] [00800040] *pgd=00000083fffe0003, *pud=00000083fffe0003, *pmd=00000083fffd0003, *pte=0000000000000000
[ 7.344266] Internal error: Oops: 96000005 [#1] PREEMPT SMP
[ 7.349825] Modules linked in:
[ 7.352871] CPU: 2 PID: 1 Comm: swapper/0 Tainted: G W I 4.8.0-rc1 #4737
[ 7.360512] Hardware name: AMD Overdrive/Supercharger/Default string, BIOS ROD1002C 04/08/2016
[ 7.369109] task: ffff8003c0220000 task.stack: ffff8003c0280000
[ 7.375020] PC is at set_bit+0x18/0x30
[ 7.378758] LR is at memory_bm_set_bit+0x24/0x30
[ 7.383362] pc : [<ffff00000835bbc8>] lr : [<ffff0000080faf18>] pstate: 60000045
[ 7.390743] sp : ffff8003c0283b00
[ 7.473551]
[ 7.475031] Process swapper/0 (pid: 1, stack limit = 0xffff8003c0280020)
[ 7.481718] Stack: (0xffff8003c0283b00 to 0xffff8003c0284000)
[ 7.800075] Call trace:
[ 7.887097] [<ffff00000835bbc8>] set_bit+0x18/0x30
[ 7.891876] [<ffff0000080fb038>] duplicate_memory_bitmap.constprop.38+0x54/0x70
[ 7.899172] [<ffff0000080fcc40>] snapshot_write_next+0x22c/0x47c
[ 7.905166] [<ffff0000080fe1b4>] load_image_lzo+0x754/0xa88
[ 7.910725] [<ffff0000080ff0a8>] swsusp_read+0x144/0x230
[ 7.916025] [<ffff0000080fa338>] load_image_and_restore+0x58/0x90
[ 7.922105] [<ffff0000080fa660>] software_resume+0x2f0/0x338
[ 7.927752] [<ffff000008083350>] do_one_initcall+0x38/0x11c
[ 7.933314] [<ffff000008b40cc0>] kernel_init_freeable+0x14c/0x1ec
[ 7.939395] [<ffff0000087ce564>] kernel_init+0x10/0xfc
[ 7.944520] [<ffff000008082e90>] ret_from_fork+0x10/0x40
[ 7.949820] Code: d2800022 8b400c21 f9800031 9ac32043 (c85f7c22)
[ 7.955909] ---[ end trace 0024a5986e6ff323 ]---
[ 7.960529] Kernel panic - not syncing: Attempted to kill init! exitcode=0x0000000b
Here struct mem_zone_bm_rtree's start_pfn has been returned instead of
struct rtree_node's addr as the node/zone pointers are corrupt after
we walked off the end of the lists during mark_unsafe_pages().
This behaviour was exposed by commit 6dbecfd345a6 ("PM / hibernate:
Simplify mark_unsafe_pages()"), which caused mark_unsafe_pages() to call
duplicate_memory_bitmap(), which uses memory_bm_find_bit() after walking
off the end of the memory bitmap.
Fixes: 3a20cb177961 (PM / Hibernate: Implement position keeping in radix tree)
Signed-off-by: James Morse <james.morse@arm.com>
[ rjw: Subject ]
Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
---
kernel/power/snapshot.c | 10 +++++-----
1 file changed, 5 insertions(+), 5 deletions(-)
--- a/kernel/power/snapshot.c
+++ b/kernel/power/snapshot.c
@@ -765,9 +765,9 @@ static bool memory_bm_pfn_present(struct
*/
static bool rtree_next_node(struct memory_bitmap *bm)
{
- bm->cur.node = list_entry(bm->cur.node->list.next,
- struct rtree_node, list);
- if (&bm->cur.node->list != &bm->cur.zone->leaves) {
+ if (!list_is_last(&bm->cur.node->list, &bm->cur.zone->leaves)) {
+ bm->cur.node = list_entry(bm->cur.node->list.next,
+ struct rtree_node, list);
bm->cur.node_pfn += BM_BITS_PER_BLOCK;
bm->cur.node_bit = 0;
touch_softlockup_watchdog();
@@ -775,9 +775,9 @@ static bool rtree_next_node(struct memor
}
/* No more nodes, goto next zone */
- bm->cur.zone = list_entry(bm->cur.zone->list.next,
+ if (!list_is_last(&bm->cur.zone->list, &bm->zones)) {
+ bm->cur.zone = list_entry(bm->cur.zone->list.next,
struct mem_zone_bm_rtree, list);
- if (&bm->cur.zone->list != &bm->zones) {
bm->cur.node = list_entry(bm->cur.zone->leaves.next,
struct rtree_node, list);
bm->cur.node_pfn = 0;
[toc] | [prev] | [next] | [standalone]
| From | Greg Kroah-Hartman <gregkh@linuxfoundation.org> |
|---|---|
| Date | 2016-09-28 11:20 +0200 |
| Subject | [PATCH 4.7 51/69] x86/mm/pat: Prevent hang during boot when mapping pages |
| Message-ID | <smjbY-4Pw-39@gated-at.bofh.it> |
| In reply to | #1492362 |
4.7-stable review patch. If anyone has any objections, please let me know.
------------------
From: Matt Fleming <matt@codeblueprint.co.uk>
commit e535ec0899d1fe52ec3a84c9bc03457ac67ad6f7 upstream.
There's a mixture of signed 32-bit and unsigned 32-bit and 64-bit data
types used for keeping track of how many pages have been mapped.
This leads to hangs during boot when mapping large numbers of pages
(multiple terabytes, as reported by Waiman) because those values are
interpreted as being negative.
commit 742563777e8d ("x86/mm/pat: Avoid truncation when converting
cpa->numpages to address") fixed one of those bugs, but there is
another lurking in __change_page_attr_set_clr().
Additionally, the return value type for the populate_*() functions can
return negative values when a large number of pages have been mapped,
triggering the error paths even though no error occurred.
Consistently use 64-bit types on 64-bit platforms when counting pages.
Even in the signed case this gives us room for regions 8PiB
(pebibytes) in size whilst still allowing the usual negative value
error checking idiom.
Reported-by: Waiman Long <waiman.long@hpe.com>
Cc: Ard Biesheuvel <ard.biesheuvel@linaro.org>
Cc: Borislav Petkov <bp@alien8.de>
Cc: Linus Torvalds <torvalds@linux-foundation.org>
CC: Theodore Ts'o <tytso@mit.edu>
Cc: Arnd Bergmann <arnd@arndb.de>
Cc: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Cc: Scott J Norton <scott.norton@hpe.com>
Cc: Douglas Hatch <doug.hatch@hpe.com>
Signed-off-by: Matt Fleming <matt@codeblueprint.co.uk>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
---
arch/x86/mm/pageattr.c | 21 +++++++++++----------
1 file changed, 11 insertions(+), 10 deletions(-)
--- a/arch/x86/mm/pageattr.c
+++ b/arch/x86/mm/pageattr.c
@@ -932,11 +932,11 @@ static void populate_pte(struct cpa_data
}
}
-static int populate_pmd(struct cpa_data *cpa,
- unsigned long start, unsigned long end,
- unsigned num_pages, pud_t *pud, pgprot_t pgprot)
+static long populate_pmd(struct cpa_data *cpa,
+ unsigned long start, unsigned long end,
+ unsigned num_pages, pud_t *pud, pgprot_t pgprot)
{
- unsigned int cur_pages = 0;
+ long cur_pages = 0;
pmd_t *pmd;
pgprot_t pmd_pgprot;
@@ -1006,12 +1006,12 @@ static int populate_pmd(struct cpa_data
return num_pages;
}
-static int populate_pud(struct cpa_data *cpa, unsigned long start, pgd_t *pgd,
- pgprot_t pgprot)
+static long populate_pud(struct cpa_data *cpa, unsigned long start, pgd_t *pgd,
+ pgprot_t pgprot)
{
pud_t *pud;
unsigned long end;
- int cur_pages = 0;
+ long cur_pages = 0;
pgprot_t pud_pgprot;
end = start + (cpa->numpages << PAGE_SHIFT);
@@ -1067,7 +1067,7 @@ static int populate_pud(struct cpa_data
/* Map trailing leftover */
if (start < end) {
- int tmp;
+ long tmp;
pud = pud_offset(pgd, start);
if (pud_none(*pud))
@@ -1093,7 +1093,7 @@ static int populate_pgd(struct cpa_data
pgprot_t pgprot = __pgprot(_KERNPG_TABLE);
pud_t *pud = NULL; /* shut up gcc */
pgd_t *pgd_entry;
- int ret;
+ long ret;
pgd_entry = cpa->pgd + pgd_index(addr);
@@ -1336,7 +1336,8 @@ static int cpa_process_alias(struct cpa_
static int __change_page_attr_set_clr(struct cpa_data *cpa, int checkalias)
{
- int ret, numpages = cpa->numpages;
+ unsigned long numpages = cpa->numpages;
+ int ret;
while (numpages) {
/*
[toc] | [prev] | [next] | [standalone]
| From | Greg Kroah-Hartman <gregkh@linuxfoundation.org> |
|---|---|
| Date | 2016-09-28 11:20 +0200 |
| Subject | [PATCH 4.7 68/69] iw_cxgb4: stop MPA_REPLY timer when disconnecting |
| Message-ID | <smjbY-4Pw-23@gated-at.bofh.it> |
| In reply to | #1492362 |
4.7-stable review patch. If anyone has any objections, please let me know.
------------------
From: Steve Wise <swise@opengridcomputing.com>
commit 12eb5137edecfd8fb6d23dacec2a3630e729736f upstream.
There exists a race where the application can setup a connection
and then disconnect it before iw_cxgb4 processes the fw4_ack
message. For passive side connections, the fw4_ack message is
used to know when to stop the ep timer for MPA_REPLY messages.
If the application disconnects before the fw4_ack is handled then
c4iw_ep_disconnect() needs to clean up the timer state and stop the
timer before restarting it for the disconnect timer. Failure to do this
results in a "timer already started" message and a premature stopping
of the disconnect timer.
Fixes: e4b76a2 ("RDMA/iw_cxgb4: stop_ep_timer() after MPA negotiation")
Signed-off-by: Steve Wise <swise@opengridcomputing.com>
Signed-off-by: Doug Ledford <dledford@redhat.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
---
drivers/infiniband/hw/cxgb4/cm.c | 12 +++++++++++-
1 file changed, 11 insertions(+), 1 deletion(-)
--- a/drivers/infiniband/hw/cxgb4/cm.c
+++ b/drivers/infiniband/hw/cxgb4/cm.c
@@ -3011,9 +3011,9 @@ static int fw4_ack(struct c4iw_dev *dev,
PDBG("%s last streaming msg ack ep %p tid %u state %u "
"initiator %u freeing skb\n", __func__, ep, ep->hwtid,
state_read(&ep->com), ep->mpa_attr.initiator ? 1 : 0);
+ mutex_lock(&ep->com.mutex);
kfree_skb(ep->mpa_skb);
ep->mpa_skb = NULL;
- mutex_lock(&ep->com.mutex);
if (test_bit(STOP_MPA_TIMER, &ep->com.flags))
stop_ep_timer(ep);
mutex_unlock(&ep->com.mutex);
@@ -3582,6 +3582,16 @@ int c4iw_ep_disconnect(struct c4iw_ep *e
ep->com.state = ABORTING;
else {
ep->com.state = CLOSING;
+
+ /*
+ * if we close before we see the fw4_ack() then we fix
+ * up the timer state since we're reusing it.
+ */
+ if (ep->mpa_skb &&
+ test_bit(STOP_MPA_TIMER, &ep->com.flags)) {
+ clear_bit(STOP_MPA_TIMER, &ep->com.flags);
+ stop_ep_timer(ep);
+ }
start_ep_timer(ep);
}
set_bit(CLOSE_SENT, &ep->com.flags);
[toc] | [prev] | [next] | [standalone]
| From | Greg Kroah-Hartman <gregkh@linuxfoundation.org> |
|---|---|
| Date | 2016-09-28 11:20 +0200 |
| Subject | [PATCH 4.7 32/69] tracing: Move mutex to protect against resetting of seq data |
| Message-ID | <smjbY-4Pw-25@gated-at.bofh.it> |
| In reply to | #1492362 |
4.7-stable review patch. If anyone has any objections, please let me know.
------------------
From: Steven Rostedt (Red Hat) <rostedt@goodmis.org>
commit 1245800c0f96eb6ebb368593e251d66c01e61022 upstream.
The iter->seq can be reset outside the protection of the mutex. So can
reading of user data. Move the mutex up to the beginning of the function.
Fixes: d7350c3f45694 ("tracing/core: make the read callbacks reentrants")
Reported-by: Al Viro <viro@ZenIV.linux.org.uk>
Signed-off-by: Steven Rostedt <rostedt@goodmis.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
---
kernel/trace/trace.c | 15 ++++++++-------
1 file changed, 8 insertions(+), 7 deletions(-)
--- a/kernel/trace/trace.c
+++ b/kernel/trace/trace.c
@@ -4890,19 +4890,20 @@ tracing_read_pipe(struct file *filp, cha
struct trace_iterator *iter = filp->private_data;
ssize_t sret;
- /* return any leftover data */
- sret = trace_seq_to_user(&iter->seq, ubuf, cnt);
- if (sret != -EBUSY)
- return sret;
-
- trace_seq_init(&iter->seq);
-
/*
* Avoid more than one consumer on a single file descriptor
* This is just a matter of traces coherency, the ring buffer itself
* is protected.
*/
mutex_lock(&iter->mutex);
+
+ /* return any leftover data */
+ sret = trace_seq_to_user(&iter->seq, ubuf, cnt);
+ if (sret != -EBUSY)
+ goto out;
+
+ trace_seq_init(&iter->seq);
+
if (iter->trace->read) {
sret = iter->trace->read(iter, filp, ubuf, cnt, ppos);
if (sret)
[toc] | [prev] | [next] | [standalone]
| From | Greg Kroah-Hartman <gregkh@linuxfoundation.org> |
|---|---|
| Date | 2016-09-28 11:20 +0200 |
| Subject | [PATCH 4.7 13/69] xfs: prevent dropping ioend completions during buftarg wait |
| Message-ID | <smjbY-4Pw-27@gated-at.bofh.it> |
| In reply to | #1492362 |
4.7-stable review patch. If anyone has any objections, please let me know.
------------------
From: Brian Foster <bfoster@redhat.com>
commit 800b2694f890cc35a1bda63501fc71c94389d517 upstream.
xfs_wait_buftarg() waits for all pending I/O, drains the ioend
completion workqueue and walks the LRU until all buffers in the cache
have been released. This is traditionally an unmount operation` but the
mechanism is also reused during filesystem freeze.
xfs_wait_buftarg() invokes drain_workqueue() as part of the quiesce,
which is intended more for a shutdown sequence in that it indicates to
the queue that new operations are not expected once the drain has begun.
New work jobs after this point result in a WARN_ON_ONCE() and are
otherwise dropped.
With filesystem freeze, however, read operations are allowed and can
proceed during or after the workqueue drain. If such a read occurs
during the drain sequence, the workqueue infrastructure complains about
the queued ioend completion work item and drops it on the floor. As a
result, the buffer remains on the LRU and the freeze never completes.
Despite the fact that the overall buffer cache cleanup is not necessary
during freeze, fix up this operation such that it is safe to invoke
during non-unmount quiesce operations. Replace the drain_workqueue()
call with flush_workqueue(), which runs a similar serialization on
pending workqueue jobs without causing new jobs to be dropped. This is
safe for unmount as unmount independently locks out new operations by
the time xfs_wait_buftarg() is invoked.
cc: <stable@vger.kernel.org>
Signed-off-by: Brian Foster <bfoster@redhat.com>
Reviewed-by: Christoph Hellwig <hch@lst.de>
Signed-off-by: Dave Chinner <david@fromorbit.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
---
fs/xfs/xfs_buf.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
--- a/fs/xfs/xfs_buf.c
+++ b/fs/xfs/xfs_buf.c
@@ -1531,7 +1531,7 @@ xfs_wait_buftarg(
* ensure here that all reference counts have been dropped before we
* start walking the LRU list.
*/
- drain_workqueue(btp->bt_mount->m_buf_workqueue);
+ flush_workqueue(btp->bt_mount->m_buf_workqueue);
/* loop until there is nothing left on the lru list. */
while (list_lru_count(&btp->bt_lru)) {
[toc] | [prev] | [next] | [standalone]
| From | Greg Kroah-Hartman <gregkh@linuxfoundation.org> |
|---|---|
| Date | 2016-09-28 11:20 +0200 |
| Subject | [PATCH 4.7 64/69] qxl: check for kmap failures |
| Message-ID | <smjbY-4Pw-29@gated-at.bofh.it> |
| In reply to | #1492362 |
4.7-stable review patch. If anyone has any objections, please let me know.
------------------
From: Dan Carpenter <dan.carpenter@oracle.com>
commit f4cceb2affcd1285d4ce498089e8a79f4cd2fa66 upstream.
If kmap fails, it leads to memory corruption.
Fixes: f64122c1f6ad ('drm: add new QXL driver. (v1.4)')
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/20160711084633.GA31411@mwanda
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
---
drivers/gpu/drm/qxl/qxl_draw.c | 2 ++
1 file changed, 2 insertions(+)
--- a/drivers/gpu/drm/qxl/qxl_draw.c
+++ b/drivers/gpu/drm/qxl/qxl_draw.c
@@ -136,6 +136,8 @@ static int qxl_palette_create_1bit(struc
* correctly globaly, since that would require
* tracking all of our palettes. */
ret = qxl_bo_kmap(palette_bo, (void **)&pal);
+ if (ret)
+ return ret;
pal->num_ents = 2;
pal->unique = unique++;
if (visual == FB_VISUAL_TRUECOLOR || visual == FB_VISUAL_DIRECTCOLOR) {
[toc] | [prev] | [next] | [standalone]
| From | Greg Kroah-Hartman <gregkh@linuxfoundation.org> |
|---|---|
| Date | 2016-09-28 11:20 +0200 |
| Subject | [PATCH 4.7 43/69] i2c: qup: skip qup_i2c_suspend if the device is already runtime suspended |
| Message-ID | <smjbY-4Pw-35@gated-at.bofh.it> |
| In reply to | #1492362 |
4.7-stable review patch. If anyone has any objections, please let me know.
------------------
From: Sudeep Holla <Sudeep.Holla@arm.com>
commit 331dcf421c34d227784d07943eb01e4023a42b0a upstream.
If the i2c device is already runtime suspended, if qup_i2c_suspend is
executed during suspend-to-idle or suspend-to-ram it will result in the
following splat:
WARNING: CPU: 3 PID: 1593 at drivers/clk/clk.c:476 clk_core_unprepare+0x80/0x90
Modules linked in:
CPU: 3 PID: 1593 Comm: bash Tainted: G W 4.8.0-rc3 #14
Hardware name: Qualcomm Technologies, Inc. APQ 8016 SBC (DT)
PC is at clk_core_unprepare+0x80/0x90
LR is at clk_unprepare+0x28/0x40
pc : [<ffff0000086eecf0>] lr : [<ffff0000086f0c58>] pstate: 60000145
Call trace:
clk_core_unprepare+0x80/0x90
qup_i2c_disable_clocks+0x2c/0x68
qup_i2c_suspend+0x10/0x20
platform_pm_suspend+0x24/0x68
...
This patch fixes the issue by executing qup_i2c_pm_suspend_runtime
conditionally in qup_i2c_suspend.
Signed-off-by: Sudeep Holla <sudeep.holla@arm.com>
Reviewed-by: Andy Gross <andy.gross@linaro.org>
Signed-off-by: Wolfram Sang <wsa@the-dreams.de>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
---
drivers/i2c/busses/i2c-qup.c | 3 ++-
1 file changed, 2 insertions(+), 1 deletion(-)
--- a/drivers/i2c/busses/i2c-qup.c
+++ b/drivers/i2c/busses/i2c-qup.c
@@ -1610,7 +1610,8 @@ static int qup_i2c_pm_resume_runtime(str
#ifdef CONFIG_PM_SLEEP
static int qup_i2c_suspend(struct device *device)
{
- qup_i2c_pm_suspend_runtime(device);
+ if (!pm_runtime_suspended(device))
+ return qup_i2c_pm_suspend_runtime(device);
return 0;
}
[toc] | [prev] | [next] | [standalone]
| From | Greg Kroah-Hartman <gregkh@linuxfoundation.org> |
|---|---|
| Date | 2016-09-28 11:20 +0200 |
| Subject | [PATCH 4.7 27/69] reset: Return -ENOTSUPP when not configured |
| Message-ID | <smjbY-4Pw-31@gated-at.bofh.it> |
| In reply to | #1492362 |
4.7-stable review patch. If anyone has any objections, please let me know.
------------------
From: John Youn <johnyoun@synopsys.com>
commit 168d7c4e8bb25c076ed8be67fcca84f5dcd0b2c6 upstream.
Prior to commit 6c96f05c8bb8 ("reset: Make [of_]reset_control_get[_foo]
functions wrappers"), the "optional" functions returned -ENOTSUPP when
CONFIG_RESET_CONTROLLER was not set.
Revert back to the old behavior by changing the new
__devm_reset_control_get() and __of_reset_control_get() functions to
return ERR_PTR(-ENOTSUPP) when compiled without CONFIG_RESET_CONTROLLER.
Otherwise they will return -EINVAL causing users to think that an error
occurred when CONFIG_RESET_CONTROLLER is not set.
Fixes: 6c96f05c8bb8 ("reset: Make [of_]reset_control_get[_foo] functions wrappers")
Signed-off-by: John Youn <johnyoun@synopsys.com>
Signed-off-by: Philipp Zabel <p.zabel@pengutronix.de>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
---
include/linux/reset.h | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
--- a/include/linux/reset.h
+++ b/include/linux/reset.h
@@ -71,14 +71,14 @@ static inline struct reset_control *__of
struct device_node *node,
const char *id, int index, int shared)
{
- return ERR_PTR(-EINVAL);
+ return ERR_PTR(-ENOTSUPP);
}
static inline struct reset_control *__devm_reset_control_get(
struct device *dev,
const char *id, int index, int shared)
{
- return ERR_PTR(-EINVAL);
+ return ERR_PTR(-ENOTSUPP);
}
#endif /* CONFIG_RESET_CONTROLLER */
[toc] | [prev] | [next] | [standalone]
| From | Greg Kroah-Hartman <gregkh@linuxfoundation.org> |
|---|---|
| Date | 2016-09-28 11:20 +0200 |
| Subject | [PATCH 4.7 45/69] MIPS: SMP: Fix possibility of deadlock when bringing CPUs online |
| Message-ID | <smjbY-4Pw-37@gated-at.bofh.it> |
| In reply to | #1492362 |
4.7-stable review patch. If anyone has any objections, please let me know. ------------------ From: Matt Redfearn <matt.redfearn@imgtec.com> commit 8f46cca1e6c06a058374816887059bcc017b382f upstream. This patch fixes the possibility of a deadlock when bringing up secondary CPUs. The deadlock occurs because the set_cpu_online() is called before synchronise_count_slave(). This can cause a deadlock if the boot CPU, having scheduled another thread, attempts to send an IPI to the secondary CPU, which it sees has been marked online. The secondary is blocked in synchronise_count_slave() waiting for the boot CPU to enter synchronise_count_master(), but the boot cpu is blocked in smp_call_function_many() waiting for the secondary to respond to it's IPI request. Fix this by marking the CPU online in cpu_callin_map and synchronising counters before declaring the CPU online and calculating the maps for IPIs. Signed-off-by: Matt Redfearn <matt.redfearn@imgtec.com> Reported-by: Justin Chen <justinpopo6@gmail.com> Tested-by: Justin Chen <justinpopo6@gmail.com> Cc: Florian Fainelli <f.fainelli@gmail.com> Cc: linux-mips@linux-mips.org Patchwork: https://patchwork.linux-mips.org/patch/14302/ Signed-off-by: Ralf Baechle <ralf@linux-mips.org> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> --- arch/mips/kernel/smp.c | 7 +++---- 1 file changed, 3 insertions(+), 4 deletions(-) --- a/arch/mips/kernel/smp.c +++ b/arch/mips/kernel/smp.c @@ -320,6 +320,9 @@ asmlinkage void start_secondary(void) cpumask_set_cpu(cpu, &cpu_coherent_mask); notify_cpu_starting(cpu); + cpumask_set_cpu(cpu, &cpu_callin_map); + synchronise_count_slave(cpu); + set_cpu_online(cpu, true); set_cpu_sibling_map(cpu); @@ -327,10 +330,6 @@ asmlinkage void start_secondary(void) calculate_cpu_foreign_map(); - cpumask_set_cpu(cpu, &cpu_callin_map); - - synchronise_count_slave(cpu); - /* * irq will be enabled in ->smp_finish(), enabling it too early * is dangerous.
[toc] | [prev] | [next] | [standalone]
| From | Greg Kroah-Hartman <gregkh@linuxfoundation.org> |
|---|---|
| Date | 2016-09-28 11:20 +0200 |
| Subject | [PATCH 4.7 09/69] autofs: use dentry flags to block walks during expire |
| Message-ID | <smjbY-4Pw-41@gated-at.bofh.it> |
| In reply to | #1492362 |
4.7-stable review patch. If anyone has any objections, please let me know.
------------------
From: Ian Kent <raven@themaw.net>
commit 7cbdb4a286a60c5d519cb9223fe2134d26870d39 upstream.
Somewhere along the way the autofs expire operation has changed to hold
a spin lock over expired dentry selection. The autofs indirect mount
expired dentry selection is complicated and quite lengthy so it isn't
appropriate to hold a spin lock over the operation.
Commit 47be61845c77 ("fs/dcache.c: avoid soft-lockup in dput()") added a
might_sleep() to dput() causing a WARN_ONCE() about this usage to be
issued.
But the spin lock doesn't need to be held over this check, the autofs
dentry info. flags are enough to block walks into dentrys during the
expire.
I've left the direct mount expire as it is (for now) because it is much
simpler and quicker than the indirect mount expire and adding spin lock
release and re-aquires would do nothing more than add overhead.
Fixes: 47be61845c77 ("fs/dcache.c: avoid soft-lockup in dput()")
Link: http://lkml.kernel.org/r/20160912014017.1773.73060.stgit@pluto.themaw.net
Signed-off-by: Ian Kent <raven@themaw.net>
Reported-by: Takashi Iwai <tiwai@suse.de>
Tested-by: Takashi Iwai <tiwai@suse.de>
Cc: Takashi Iwai <tiwai@suse.de>
Cc: NeilBrown <neilb@suse.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>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
---
fs/autofs4/expire.c | 55 +++++++++++++++++++++++++++++++++++++++-------------
1 file changed, 42 insertions(+), 13 deletions(-)
--- a/fs/autofs4/expire.c
+++ b/fs/autofs4/expire.c
@@ -417,6 +417,7 @@ static struct dentry *should_expire(stru
}
return NULL;
}
+
/*
* Find an eligible tree to time-out
* A tree is eligible if :-
@@ -432,6 +433,7 @@ struct dentry *autofs4_expire_indirect(s
struct dentry *root = sb->s_root;
struct dentry *dentry;
struct dentry *expired;
+ struct dentry *found;
struct autofs_info *ino;
if (!root)
@@ -442,31 +444,46 @@ struct dentry *autofs4_expire_indirect(s
dentry = NULL;
while ((dentry = get_next_positive_subdir(dentry, root))) {
+ int flags = how;
+
spin_lock(&sbi->fs_lock);
ino = autofs4_dentry_ino(dentry);
- if (ino->flags & AUTOFS_INF_WANT_EXPIRE)
- expired = NULL;
- else
- expired = should_expire(dentry, mnt, timeout, how);
- if (!expired) {
+ if (ino->flags & AUTOFS_INF_WANT_EXPIRE) {
spin_unlock(&sbi->fs_lock);
continue;
}
+ spin_unlock(&sbi->fs_lock);
+
+ expired = should_expire(dentry, mnt, timeout, flags);
+ if (!expired)
+ continue;
+
+ spin_lock(&sbi->fs_lock);
ino = autofs4_dentry_ino(expired);
ino->flags |= AUTOFS_INF_WANT_EXPIRE;
spin_unlock(&sbi->fs_lock);
synchronize_rcu();
- spin_lock(&sbi->fs_lock);
- if (should_expire(expired, mnt, timeout, how)) {
- if (expired != dentry)
- dput(dentry);
- goto found;
- }
+ /* Make sure a reference is not taken on found if
+ * things have changed.
+ */
+ flags &= ~AUTOFS_EXP_LEAVES;
+ found = should_expire(expired, mnt, timeout, how);
+ if (!found || found != expired)
+ /* Something has changed, continue */
+ goto next;
+
+ if (expired != dentry)
+ dput(dentry);
+
+ spin_lock(&sbi->fs_lock);
+ goto found;
+next:
+ spin_lock(&sbi->fs_lock);
ino->flags &= ~AUTOFS_INF_WANT_EXPIRE;
+ spin_unlock(&sbi->fs_lock);
if (expired != dentry)
dput(expired);
- spin_unlock(&sbi->fs_lock);
}
return NULL;
@@ -483,6 +500,7 @@ int autofs4_expire_wait(struct dentry *d
struct autofs_sb_info *sbi = autofs4_sbi(dentry->d_sb);
struct autofs_info *ino = autofs4_dentry_ino(dentry);
int status;
+ int state;
/* Block on any pending expire */
if (!(ino->flags & AUTOFS_INF_WANT_EXPIRE))
@@ -490,8 +508,19 @@ int autofs4_expire_wait(struct dentry *d
if (rcu_walk)
return -ECHILD;
+retry:
spin_lock(&sbi->fs_lock);
- if (ino->flags & AUTOFS_INF_EXPIRING) {
+ state = ino->flags & (AUTOFS_INF_WANT_EXPIRE | AUTOFS_INF_EXPIRING);
+ if (state == AUTOFS_INF_WANT_EXPIRE) {
+ spin_unlock(&sbi->fs_lock);
+ /*
+ * Possibly being selected for expire, wait until
+ * it's selected or not.
+ */
+ schedule_timeout_uninterruptible(HZ/10);
+ goto retry;
+ }
+ if (state & AUTOFS_INF_EXPIRING) {
spin_unlock(&sbi->fs_lock);
pr_debug("waiting for expire %p name=%pd\n", dentry, dentry);
[toc] | [prev] | [next] | [standalone]
| From | Greg Kroah-Hartman <gregkh@linuxfoundation.org> |
|---|---|
| Date | 2016-09-28 11:20 +0200 |
| Subject | [PATCH 4.7 49/69] MIPS: Add a missing ".set pop" in an early commit |
| Message-ID | <smjbY-4Pw-49@gated-at.bofh.it> |
| In reply to | #1492362 |
4.7-stable review patch. If anyone has any objections, please let me know.
------------------
From: Huacai Chen <chenhc@lemote.com>
commit 3cbc6fc9c99f1709203711f125bc3b79487aba06 upstream.
Commit 842dfc11ea9a21 ("MIPS: Fix build with binutils 2.24.51+") missing
a ".set pop" in macro fpu_restore_16even, so add it.
Signed-off-by: Huacai Chen <chenhc@lemote.com>
Acked-by: Manuel Lauss <manuel.lauss@gmail.com>
Cc: Steven J . Hill <Steven.Hill@caviumnetworks.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/14210/
Signed-off-by: Ralf Baechle <ralf@linux-mips.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
---
arch/mips/include/asm/asmmacro.h | 1 +
1 file changed, 1 insertion(+)
--- a/arch/mips/include/asm/asmmacro.h
+++ b/arch/mips/include/asm/asmmacro.h
@@ -157,6 +157,7 @@
ldc1 $f28, THREAD_FPR28(\thread)
ldc1 $f30, THREAD_FPR30(\thread)
ctc1 \tmp, fcr31
+ .set pop
.endm
.macro fpu_restore_16odd thread
[toc] | [prev] | [next] | [standalone]
| From | Greg Kroah-Hartman <gregkh@linuxfoundation.org> |
|---|---|
| Date | 2016-09-28 11:20 +0200 |
| Subject | [PATCH 4.7 34/69] can: flexcan: fix resume function |
| Message-ID | <smjbZ-4Pw-53@gated-at.bofh.it> |
| In reply to | #1492362 |
4.7-stable review patch. If anyone has any objections, please let me know.
------------------
From: Fabio Estevam <fabio.estevam@nxp.com>
commit 4de349e786a3a2d51bd02d56f3de151bbc3c3df9 upstream.
On a imx6ul-pico board the following error is seen during system suspend:
dpm_run_callback(): platform_pm_resume+0x0/0x54 returns -110
PM: Device 2090000.flexcan failed to resume: error -110
The reason for this suspend error is because when the CAN interface is not
active the clocks are disabled and then flexcan_chip_enable() will
always fail due to a timeout error.
In order to fix this issue, only call flexcan_chip_enable/disable()
when the CAN interface is active.
Based on a patch from Dong Aisheng in the NXP kernel.
Signed-off-by: Fabio Estevam <fabio.estevam@nxp.com>
Signed-off-by: Marc Kleine-Budde <mkl@pengutronix.de>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
---
drivers/net/can/flexcan.c | 13 ++++++++-----
1 file changed, 8 insertions(+), 5 deletions(-)
--- a/drivers/net/can/flexcan.c
+++ b/drivers/net/can/flexcan.c
@@ -1268,11 +1268,10 @@ static int __maybe_unused flexcan_suspen
struct flexcan_priv *priv = netdev_priv(dev);
int err;
- err = flexcan_chip_disable(priv);
- if (err)
- return err;
-
if (netif_running(dev)) {
+ err = flexcan_chip_disable(priv);
+ if (err)
+ return err;
netif_stop_queue(dev);
netif_device_detach(dev);
}
@@ -1285,13 +1284,17 @@ static int __maybe_unused flexcan_resume
{
struct net_device *dev = dev_get_drvdata(device);
struct flexcan_priv *priv = netdev_priv(dev);
+ int err;
priv->can.state = CAN_STATE_ERROR_ACTIVE;
if (netif_running(dev)) {
netif_device_attach(dev);
netif_start_queue(dev);
+ err = flexcan_chip_enable(priv);
+ if (err)
+ return err;
}
- return flexcan_chip_enable(priv);
+ return 0;
}
static SIMPLE_DEV_PM_OPS(flexcan_pm_ops, flexcan_suspend, flexcan_resume);
[toc] | [prev] | [next] | [standalone]
Page 1 of 4 [1] 2 3 4 Next page →
Back to top | Article view | linux.kernel
csiph-web