kernel_optimize_test/drivers
Moni Shoua 33814e5d12 net/mlx5: Take lock with IRQs disabled to avoid deadlock
The lock in qp_table might be taken from process context or from
interrupt context. This may lead to a deadlock unless it is taken with
IRQs disabled.

Discovered by lockdep

================================
WARNING: inconsistent lock state
4.20.0-rc6
--------------------------------
inconsistent {HARDIRQ-ON-W} -> {IN-HARDIRQ-W}

python/12572 [HC1[1]:SC0[0]:HE0:SE1] takes:
00000000052a4df4 (&(&table->lock)->rlock#2){?.+.}, /0x50 [mlx5_core]
{HARDIRQ-ON-W} state was registered at:
  _raw_spin_lock+0x33/0x70
  mlx5_get_rsc+0x1a/0x50 [mlx5_core]
  mlx5_ib_eqe_pf_action+0x493/0x1be0 [mlx5_ib]
  process_one_work+0x90c/0x1820
  worker_thread+0x87/0xbb0
  kthread+0x320/0x3e0
  ret_from_fork+0x24/0x30
irq event stamp: 103928
hardirqs last  enabled at (103927): [] nk+0x1a/0x1c
hardirqs last disabled at (103928): [] unk+0x1a/0x1c
softirqs last  enabled at (103924): [] tcp_sendmsg+0x31/0x40
softirqs last disabled at (103922): [] 80

other info that might help us debug this:
 Possible unsafe locking scenario:

       CPU0
       ----
  lock(&(&table->lock)->rlock#2);

    lock(&(&table->lock)->rlock#2);

 *** DEADLOCK ***

Fixes: 032080ab43 ("IB/mlx5: Lock QP during page fault handling")
Signed-off-by: Moni Shoua <monis@mellanox.com>
Reviewed-by: Leon Romanovsky <leonro@mellanox.com>
Signed-off-by: Saeed Mahameed <saeedm@mellanox.com>
2019-01-25 12:00:28 -08:00
..
accessibility
acpi libnvdimm v5.0-rc3 2019-01-20 10:24:30 +12:00
amba
android
ata ata: pata_acpi: Make PCI dependency explicit 2019-01-15 23:16:34 +01:00
atm atm: he: fix sign-extension overflow on large shift 2019-01-17 11:27:00 -08:00
auxdisplay
base regmap: Fixes for v5.0 2019-01-19 07:17:19 +12:00
bcma
block for-linus-20190118 2019-01-20 09:12:50 +12:00
bluetooth
bus
cdrom
char Remove 'type' argument from access_ok() function 2019-01-03 18:57:57 -08:00
clk
clocksource arch/csky patches for 4.21-rc1 2019-01-05 09:50:07 -08:00
connector
cpufreq Merge branches 'pm-cpuidle', 'pm-cpufreq' and 'pm-sleep' 2019-01-11 10:09:51 +01:00
cpuidle
crypto Merge branch 'linus' of git://git.kernel.org/pub/scm/linux/kernel/git/herbert/crypto-2.6 2019-01-19 05:48:43 +12:00
dax
dca
devfreq
dio
dma cross-tree: phase out dma_zalloc_coherent() 2019-01-08 07:58:37 -05:00
dma-buf drivers/dma-buf/udmabuf.c: convert to use vm_fault_t 2019-01-04 13:13:46 -08:00
edac
eisa
extcon
firewire FireWire (IEEE 1394) subsystem patch: 2019-01-05 18:33:21 -08:00
firmware arm64 fixes for -rc1 2019-01-05 11:28:39 -08:00
fmc
fpga Remove 'type' argument from access_ok() function 2019-01-03 18:57:57 -08:00
fsi
gnss
gpio gpio: pca953x: Make symbol 'pca953x_i2c_regmap' static 2019-01-11 09:16:40 +01:00
gpu ACPI fixes for 5.0-rc3 2019-01-19 05:46:00 +12:00
hid Merge branch 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/hid/hid 2019-01-05 17:53:40 -08:00
hsi
hv
hwmon hwmon: (tmp421) Correct the misspelling of the tmp442 compatible attribute in OF device ID table 2019-01-17 12:54:52 -08:00
hwspinlock hwspinlock: fix return value check in stm32_hwspinlock_probe() 2019-01-03 11:42:10 -08:00
hwtracing
i2c i2c: tegra: Fix Maximum transfer size 2019-01-11 00:15:04 +01:00
i3c i3c: master: dw-i3c-master: fix i3c_attach/reattach 2019-01-15 11:15:11 +01:00
ide
idle
iio - New Device Support 2019-01-15 06:24:36 +12:00
infiniband First 5.0 rc pull request 2019-01-18 17:17:20 +12:00
input cross-tree: phase out dma_zalloc_coherent() 2019-01-08 07:58:37 -05:00
iommu cross-tree: phase out dma_zalloc_coherent() 2019-01-08 07:58:37 -05:00
ipack
irqchip irqchip/csky: fixup handle_irq_perbit break irq 2019-01-09 00:18:46 +08:00
isdn isdn: avm: Fix string plus integer warning from Clang 2019-01-19 10:01:03 -08:00
leds leds: lp5523: fix a missing check of return value of lp55xx_read 2019-01-17 22:27:39 +01:00
lightnvm
macintosh Remove 'type' argument from access_ok() function 2019-01-03 18:57:57 -08:00
mailbox
mcb
md md: Make bio_alloc_mddev use bio_alloc_bioset 2019-01-14 06:31:56 -07:00
media media: vim2m: only cancel work if it is for right context 2019-01-16 11:13:25 -05:00
memory ARM: SoC: late updates 2019-01-05 11:30:37 -08:00
memstick
message
mfd - New Device Support 2019-01-15 06:24:36 +12:00
misc virtio: don't allocate vqs when names[i] = NULL 2019-01-14 20:15:19 -05:00
mmc GPIO fixes for the v5.0 series: 2019-01-15 06:26:28 +12:00
mtd mtd: rawnand: denali: get ->setup_data_interface() working again 2019-01-18 10:27:01 +01:00
mux
net net/mlx5: Take lock with IRQs disabled to avoid deadlock 2019-01-25 12:00:28 -08:00
nfc
ntb cross-tree: phase out dma_zalloc_coherent() 2019-01-08 07:58:37 -05:00
nubus
nvdimm libnvdimm/security: Fix nvdimm_security_state() state request selection 2019-01-15 13:54:33 -08:00
nvme for-linus-20190118 2019-01-20 09:12:50 +12:00
nvmem
of OF: properties: add missing of_node_put 2019-01-16 12:49:53 -06:00
opp cpufreq: scpi/scmi: Fix freeing of dynamic OPPs 2019-01-04 12:19:40 +01:00
oprofile
parisc
parport
pci pci-v5.0-fixes-2 2019-01-19 07:26:16 +12:00
pcmcia Included in this update: 2019-01-05 11:23:17 -08:00
perf drivers/perf: hisi: Fixup one DDRC PMU register offset 2019-01-04 10:13:27 +00:00
phy Merge git://git.kernel.org/pub/scm/linux/kernel/git/davem/net 2019-01-16 05:13:36 +12:00
pinctrl
platform platform/x86: apple-gmux: Make PCI dependency explicit 2019-01-15 23:17:16 +01:00
pnp Remove 'type' argument from access_ok() function 2019-01-03 18:57:57 -08:00
power
powercap
pps
ps3
ptp ptp: check that rsv field is zero in struct ptp_sys_offset_extended 2019-01-08 16:22:56 -05:00
pwm
rapidio cross-tree: phase out dma_zalloc_coherent() 2019-01-08 07:58:37 -05:00
ras
regulator
remoteproc virtio: don't allocate vqs when names[i] = NULL 2019-01-14 20:15:19 -05:00
reset reset: uniphier-glue: Add AHCI reset control support in glue layer 2019-01-07 16:38:51 +01:00
rpmsg
rtc
s390 virtio: don't allocate vqs when names[i] = NULL 2019-01-14 20:15:19 -05:00
sbus
scsi SCSI fixes on 20190118 2019-01-20 09:15:04 +12:00
sfi
sh
siox
slimbus
sn
soc Merge git://git.kernel.org/pub/scm/linux/kernel/git/davem/net 2019-01-16 05:13:36 +12:00
soundwire
spi cross-tree: phase out dma_zalloc_coherent() 2019-01-08 07:58:37 -05:00
spmi
ssb
staging Staging driver fixes for 5.0-rc2 2019-01-14 05:49:35 +12:00
target scsi: tcmu: avoid cmd/qfull timers updated whenever a new cmd comes 2019-01-11 20:58:52 -05:00
tc
tee
thermal drivers: thermal: int340x_thermal: Make PCI dependency explicit 2019-01-15 23:17:40 +01:00
thunderbolt
tty tty/serial fixes for 5.0-rc2 2019-01-14 05:47:48 +12:00
uio
usb USB fixes for 5.0-rc2 2019-01-14 05:45:28 +12:00
uwb
vfio vfio/type1: Fix unmap overflow off-by-one 2019-01-08 09:31:28 -07:00
vhost Merge git://git.kernel.org/pub/scm/linux/kernel/git/davem/net 2019-01-21 12:52:31 +13:00
video fbdev fixes for v5.0-rc3: 2019-01-19 05:43:05 +12:00
virt
virtio virtio-balloon: tweak config_changed implementation 2019-01-14 20:15:20 -05:00
visorbus
vlynq
vme
w1
watchdog watchdog: tqmx86: Fix a couple IS_ERR() vs NULL bugs 2019-01-07 10:10:35 +01:00
xen xen: fixes for 5.0-rc3 2019-01-19 05:53:41 +12:00
zorro
Kconfig
Makefile