* remotes/origin/tmp-a51b40c:
Linux 4.14.51
tcp: do not overshoot window_clamp in tcp_rcv_space_adjust()
Btrfs: make raid6 rebuild retry more
Btrfs: fix scrub to repair raid6 corruption
Revert "Btrfs: fix scrub to repair raid6 corruption"
ARM: kexec: fix kdump register saving on panic()
ARM: 8758/1: decompressor: restore r1 and r2 just before jumping to the kernel
ARM: 8753/1: decompressor: add a missing parameter to the addruart macro
efi/libstub/arm64: Handle randomized TEXT_OFFSET
parisc: Move setup_profiling_timer() out of init section
sched/deadline: Make the grub_reclaim() function static
sched/debug: Move the print_rt_rq() and print_dl_rq() declarations to kernel/sched/sched.h
drm/dumb-buffers: Integer overflow in drm_mode_create_ioctl()
locking/percpu-rwsem: Annotate rwsem ownership transfer by setting RWSEM_OWNER_UNKNOWN
locking/rwsem: Add a new RWSEM_ANONYMOUSLY_OWNED flag
clk: imx6ull: use OSC clock during AXI rate change
ARM: davinci: board-dm646x-evm: set VPIF capture card name
ARM: davinci: board-dm646x-evm: pass correct I2C adapter id for VPIF
ARM: davinci: dm646x: fix timer interrupt generation
i2c: viperboard: return message count on master_xfer success
i2c: pmcmsp: fix error return from master_xfer
i2c: pmcmsp: return message count on master_xfer success
ARM: keystone: fix platform_domain_notifier array overrun
usb: musb: fix remote wakeup racing with suspend
afs: Fix the non-encryption of calls
mtd: Fix comparison in map_word_andequal()
x86/pkeys/selftests: Add a test for pkey 0
x86/pkeys/selftests: Save off 'prot' for allocations
x86/pkeys/selftests: Fix pointer math
x86/pkeys/selftests: Fix pkey exhaustion test off-by-one
x86/pkeys/selftests: Add PROT_EXEC test
x86/pkeys/selftests: Factor out "instruction page"
x86/pkeys/selftests: Allow faults on unknown keys
x86/pkeys/selftests: Remove dead debugging code, fix dprint_in_signal
x86/pkeys/selftests: Stop using assert()
x86/pkeys/selftests: Give better unexpected fault error messages
x86/selftests: Add mov_to_ss test
x86/mpx/selftests: Adjust the self-test to fresh distros that export the MPX ABI
x86/pkeys/selftests: Adjust the self-test to fresh distros that export the pkeys ABI
objtool, kprobes/x86: Sync the latest <asm/insn.h> header with tools/objtool/arch/x86/include/asm/insn.h
uprobes/x86: Prohibit probing on MOV SS instruction
kprobes/x86: Prohibit probing on exception masking instructions
ocfs2: take inode cluster lock before moving reflinked inode from orphan dir
proc/kcore: don't bounds check against address 0
init: fix false positives in W+X checking
net sched actions: fix invalid pointer dereferencing if skbedit flags missing
ixgbe: return error on unsupported SFP module when resetting
x86: Delay skip of emulated hypercall instruction
KVM: Extend MAX_IRQ_ROUTES to 4096 for all archs
rxrpc: Fix the min security level for kernel calls
rxrpc: Fix error reception on AF_INET6 sockets
qede: Fix gfp flags sent to rdma event node allocation
qed: Fix l2 initializations over iWARP personality
tipc: eliminate KMSAN uninit-value in strcmp complaint
agp: uninorth: make two functions static
cifs: smb2ops: Fix listxattr() when there are no EAs
arm64: Add MIDR encoding for NVIDIA CPUs
can: dev: increase bus-off message severity
net: aquantia: driver should correctly declare vlan_features bits
x86/xen: Reset VCPU0 info pointer after shared_info remap
mac80211: use timeout from the AddBA response instead of the request
ARM: dts: cygnus: fix irq type for arm global timer
driver core: add __printf verification to __ata_ehi_pushv_desc
drm/omap: handle alloc failures in omap_connector
drm/omap: check return value from soc_device_match
drm/omap: fix possible NULL ref issue in tiler_reserve_2d
drm/omap: fix uninitialized ret variable
drm/omap: silence unititialized variable warning
mac80211: Adjust SAE authentication timeout
tee: check shm references are consistent in offset/size
sh: fix build failure for J2 cpu with SMP disabled
sched/core: Introduce set_special_state()
spi: bcm2835aux: ensure interrupts are enabled for shared handler
RDMA/cma: Do not query GID during QP state transition to RTR
IB/hfi1: Fix memory leak in exception path in get_irq_affinity()
IB/hfi1 Use correct type for num_user_context
smc: fix sendpage() call
ARM: OMAP1: ams-delta: fix deferred_fiq handler
nvme: Set integrity flag for user passthrough commands
nvme: fix potential memory leak in option parsing
iommu/vt-d: fix shift-out-of-bounds in bug checking
arm64: tegra: Make BCM89610 PHY interrupt as active low
kthread, sched/wait: Fix kthread_parkme() wait-loop
stop_machine, sched: Fix migrate_swap() vs. active_balance() deadlock
parisc: drivers.c: Fix section mismatches
bpf, x64: fix memleak when not converging after image
scsi: vmw-pvscsi: return DID_BUS_BUSY for adapter-initated aborts
hexagon: export csum_partial_copy_nocheck
hexagon: add memset_io() helper
Input: atmel_mxt_ts - fix the firmware update
ARM: dts: logicpd-som-lv: Fix Audio Mute
ARM: dts: logicpd-som-lv: Fix WL127x Startup Issues
ARM: OMAP2+: powerdomain: use raw_smp_processor_id() for trace
dt-bindings: panel: lvds: Fix path to display timing bindings
ARM: davinci: board-dm355-evm: fix broken networking
ARM: davinci: board-omapl138-hawk: fix GPIO numbers for MMC/SD lookup
ARM: davinci: board-da850-evm: fix GPIO lookup for MMC/SD
ARM: davinci: board-da830-evm: fix GPIO lookup for MMC/SD
IB/core: Make ib_mad_client_id atomic
<linux/stringhash.h>: fix end_name_hash() for 64bit long
IB/rxe: avoid double kfree_skb
IB/rxe: add RXE_START_MASK for rxe_opcode IB_OPCODE_RC_SEND_ONLY_INV
RDMA/iwpm: fix memory leak on map_info
RDMA/cma: Fix use after destroy access to net namespace for IPoIB
IB/uverbs: Fix validating mandatory attributes
IB: make INFINIBAND_ADDR_TRANS configurable
ib_srp: depend on INFINIBAND_ADDR_TRANS
ib_srpt: depend on INFINIBAND_ADDR_TRANS
nvmet-rdma: depend on INFINIBAND_ADDR_TRANS
nvme: depend on INFINIBAND_ADDR_TRANS
tipc: fix bug in function tipc_nl_node_dump_monitor
i2c: sprd: Fix the i2c count issue
i2c: sprd: Prevent i2c accesses after suspend is called
bpf: fix uninitialized variable in bpf tools
x86/cpu/intel: Add missing TLB cpuid values
ata: ahci: mvebu: override ahci_stop_engine for mvebu AHCI
libahci: Allow drivers to override stop_engine
KVM: arm/arm64: vgic: fix possible spectre-v1 in vgic_mmio_read_apr()
arm64: fix possible spectre-v1 in ptrace_hbp_get_event()
blk-mq: fix sysfs inflight counter
HID: intel-ish-hid: use put_device() instead of kfree()
rpmsg: added MODULE_ALIAS for rpmsg_char
remoteproc: qcom: Fix potential device node leaks
perf/x86/intel: Don't enable freeze-on-smi for PerfMon V1
rds: ib: Fix missing call to rds_ib_dev_put in rds_ib_setup_qp
selftests: ftrace: Add a testcase for multiple actions on trigger
HID: wacom: Release device resource data obtained by devres_alloc()
HID: lenovo: Add support for IBM/Lenovo Scrollpoint mice
arm64: ptrace: remove addr_limit manipulation
net: ethtool: Add missing kernel doc for FEC parameters
thermal: int3403_thermal: Fix NULL pointer deref on module load / probe
drm/amdkfd: fix clock counter retrieval for node without GPU
ACPI / watchdog: Prefer iTCO_wdt on Lenovo Z50-70
ARM: dts: da850: fix W=1 warnings with pinmux node
net: phy: marvell: clear wol event before setting it
powerpc/powernv/memtrace: Let the arch hotunplug code flush cache
dt-bindings: meson-uart: DT fix s/clocks-names/clock-names/
ACPI / PM: Blacklist Low Power S0 Idle _DSM for ThinkPad X1 Tablet(2016)
usb: typec: ucsi: fix tracepoint related build error
mm: memcg: add __GFP_NOWARN in __memcg_schedule_kmem_cache_create()
kexec_file: do not add extra alignment to efi memmap
proc: revalidate kernel thread inodes to root:root
mm, pagemap: fix swap offset value for PMD migration entry
scsi: isci: Fix infinite loop in while loop
scsi: storvsc: Set up correct queue depth values for IDE devices
parisc: time: Convert read_persistent_clock() to read_persistent_clock64()
vfs: Undo an overly zealous MS_RDONLY -> SB_RDONLY conversion
net: hns: Avoid action name truncation
blkcg: init root blkcg_gq under lock
drm/msm: don't deref error pointer in the msm_fbdev_create error path
drm/msm/dsi: use correct enum in dsi_get_cmd_fmt
drm/msm: Fix possible null dereference on failure of get_pages()
ASoC: msm8916-wcd-analog: use threaded context for mbhc events
netfilter: nf_tables: fix out-of-bounds in nft_chain_commit_update
netfilter: nf_tables: NAT chain and extensions require NF_TABLES
scsi: target: fix crash with iscsi target and dvd
scsi: megaraid_sas: Do not log an error if FW successfully initializes.
scsi: iscsi: respond to netlink with unicast when appropriate
tipc: fix infinite loop when dumping link monitor summary
blkcg: don't hold blkcg lock when deactivating policy
spi: cadence: Add usleep_range() for cdns_spi_fill_tx_fifo()
ASoC: topology: Check widget kcontrols before deref.
xen: xenbus_dev_frontend: Really return response string
ASoC: topology: Fix bugs of freeing soc topology
PCI: kirin: Fix reset gpio name
soc: bcm2835: Make !RASPBERRYPI_FIRMWARE dummies return failure
soc: bcm: raspberrypi-power: Fix use of __packed
eCryptfs: don't pass up plaintext names when using filename encryption
ASoC: rt5514: Add the missing register in the readable table
clk: honor CLK_MUX_ROUND_CLOSEST in generic clk mux
dt-bindings: dmaengine: rcar-dmac: document R8A77965 support
dt-bindings: serial: sh-sci: Add support for r8a77965 (H)SCIF
dt-bindings: pinctrl: sunxi: Fix reference to driver
doc: Add vendor prefix for Kieback & Peter GmbH
spi: sh-msiof: Fix bit field overflow writes to TSCR/RSCR
MIPS: dts: Boston: Fix PCI bus dtc warnings:
isofs: fix potential memory leak in mount option parsing
s390/smsgiucv: disable SMSG on module unload
MIPS: io: Add barrier after register read in readX()
fsnotify: fix ignore mask logic in send_to_group()
perf report: Fix switching to another perf.data file
nfp: ignore signals when communicating with management FW
MIPS: io: Prevent compiler reordering writeX()
x86: Add check for APIC access address for vmentry of L2 guests
KVM: X86: fix incorrect reference of trace_kvm_pi_irte_update
Input: synaptics-rmi4 - fix an unchecked out of memory error path
clocksource/drivers/imx-tpm: Correct some registers operation flow
stop_machine: Disable preemption when waking two stopper threads
When cpu_stop_queue_two_works() begins to wake the stopper
threads, it does so without preemption disabled, which leads
to the following race condition:
The source CPU calls cpu_stop_queue_two_works(), with cpu1
as the source CPU, and cpu2 as the destination CPU. When
adding the stopper threads to the wake queue used in this
function, the source CPU stopper thread is added first,
and the destination CPU stopper thread is added last.
When wake_up_q() is invoked to wake the stopper threads, the
threads are woken up in the order that they are queued in,
so the source CPU's stopper thread is woken up first, and
it preempts the thread running on the source CPU.
The stopper thread will then execute on the source CPU,
disable preemption, and begin executing multi_cpu_stop()
and wait for an ack from the destination CPU's stopper thread,
with preemption still disabled. Since the worker thread that
woke up the stopper thread on the source CPU is affine to the
source CPU, and preemption is disabled on the source CPU, that
thread will never run to dequeue the destination CPU's stopper
thread from the wake queue, and thus, the destination CPU's
stopper thread will never run, causing the source CPU's stopper
thread to wait forever, and stall.
Disable preemption when waking the stopper threads in
cpu_stop_queue_two_works() to ensure that the worker thread
that is waking up the stopper threads isn't preempted
by the source CPU's stopper thread, and permanently
scheduled out, leaving the remaining stopper thread asleep
in the wake queue.
Conflicts:
drivers/gpu/drm/msm/msm_gem.c
include/linux/sched.h
kernel/kthread.c
Change-Id: I177cb8516cdfe50d61cb948ed342d330e61376a1
Signed-off-by: Prasad Sodagudi <psodagud@codeaurora.org>
Signed-off-by: Isaac J. Manjarres <isaacm@codeaurora.org>