kernel-fxtec-pro1x/drivers
Yufen Yu 30673786f9 nvme-loop: init nvmet_ctrl fatal_err_work when allocate
[ Upstream commit d11de63f2b519f0a162b834013b6d3a46dbf3886 ]

After commit 4d43d395fe (workqueue: Try to catch flush_work() without
INIT_WORK()), it can cause warning when delete nvme-loop device, trace
like:

[   76.601272] Call Trace:
[   76.601646]  ? del_timer+0x72/0xa0
[   76.602156]  __cancel_work_timer+0x1ae/0x270
[   76.602791]  cancel_work_sync+0x14/0x20
[   76.603407]  nvmet_ctrl_free+0x1b7/0x2f0 [nvmet]
[   76.604091]  ? free_percpu+0x168/0x300
[   76.604652]  nvmet_sq_destroy+0x106/0x240 [nvmet]
[   76.605346]  nvme_loop_destroy_admin_queue+0x30/0x60 [nvme_loop]
[   76.606220]  nvme_loop_shutdown_ctrl+0xc3/0xf0 [nvme_loop]
[   76.607026]  nvme_loop_delete_ctrl_host+0x19/0x30 [nvme_loop]
[   76.607871]  nvme_do_delete_ctrl+0x75/0xb0
[   76.608477]  nvme_sysfs_delete+0x7d/0xc0
[   76.609057]  dev_attr_store+0x24/0x40
[   76.609603]  sysfs_kf_write+0x4c/0x60
[   76.610144]  kernfs_fop_write+0x19a/0x260
[   76.610742]  __vfs_write+0x1c/0x60
[   76.611246]  vfs_write+0xfa/0x280
[   76.611739]  ksys_write+0x6e/0x120
[   76.612238]  __x64_sys_write+0x1e/0x30
[   76.612787]  do_syscall_64+0xbf/0x3a0
[   76.613329]  entry_SYSCALL_64_after_hwframe+0x44/0xa9

We fix it by moving fatal_err_work init to nvmet_alloc_ctrl(), which may
more reasonable.

Signed-off-by: Yufen Yu <yuyufen@huawei.com>
Reviewed-by: Sagi Grimberg <sagi@grimberg.me>
Reviewed-by: Bart Van Assche <bvanassche@acm.org>
Signed-off-by: Christoph Hellwig <hch@lst.de>
Signed-off-by: Jens Axboe <axboe@kernel.dk>
Signed-off-by: Sasha Levin <sashal@kernel.org>
2019-05-08 07:21:44 +02:00
..
accessibility
acpi Revert "ACPICA: Clear status of GPEs before enabling them" 2019-05-04 09:20:10 +02:00
amba
android binder: fix handling of misaligned binder object 2019-05-02 09:58:56 +02:00
ata libata: fix using DMA buffers on stack 2019-05-04 09:20:21 +02:00
atm atm: he: fix sign-extension overflow on large shift 2019-02-27 10:08:57 +01:00
auxdisplay auxdisplay: hd44780: Fix memory leak on ->remove() 2019-04-20 09:15:55 +02:00
base mm: hide incomplete nr_indirectly_reclaimable in sysfs 2019-04-20 09:16:05 +02:00
bcma
block zram: pass down the bvec we need to read into in the work struct 2019-05-02 09:58:53 +02:00
bluetooth Bluetooth: hci_ldisc: Postpone HCI_UART_PROTO_READY bit set in hci_uart_set_proto() 2019-03-27 14:14:42 +09:00
bus Merge branch 'perm-fix' into omap-for-v4.19/fixes-v2 2018-08-28 09:58:03 -07:00
cdrom cdrom: Fix race condition in cdrom_sysctl_register 2019-04-05 22:33:10 +02:00
char tpm: Fix the type of the return value in calc_tpm2_event_size() 2019-04-27 09:36:40 +02:00
clk Revert "clk: meson: clean-up clock registration" 2019-04-17 08:38:46 +02:00
clocksource clocksource/drivers/arch_timer: Workaround for Allwinner A64 timer instability 2019-03-23 20:09:58 +01:00
connector connector: fix unsafe usage of ->real_parent 2019-03-19 13:12:38 +01:00
cpufreq cpufreq: acpi-cpufreq: Report if CPU doesn't support boost technologies 2019-04-05 22:33:03 +02:00
cpuidle cpuidle: big.LITTLE: fix refcount leak 2019-02-12 19:47:08 +01:00
crypto crypto: axis - fix for recursive locking from bottom half 2019-04-20 09:16:04 +02:00
dax mm, devm_memremap_pages: fix shutdown handling 2019-01-13 09:51:04 +01:00
dca
devfreq
dio
dma dmaengine: sh: rcar-dmac: Fix glitch in dmaengine_tx_status 2019-05-02 09:58:55 +02:00
dma-buf
edac EDAC, skx_edac: Fix logical channel intermediate decoding 2018-11-13 11:08:44 -08:00
eisa
extcon
firewire
firmware efi/arm/arm64: Allow SetVirtualAddressMap() to be omitted 2019-04-05 22:33:12 +02:00
fmc
fpga fpga: altera-cvp: fix 'bad IO access' on x86_64 2019-02-12 19:46:59 +01:00
fsi fsi: master-ast-cf: select GENERIC_ALLOCATOR 2018-12-17 09:24:35 +01:00
gnss gnss: sirf: fix premature wakeup interrupt enable 2019-03-10 07:17:21 +01:00
gpio gpio: of: Fix of_gpiochip_add() error path 2019-05-04 09:20:21 +02:00
gpu drm/meson: Uninstall IRQ handler 2019-05-04 09:20:20 +02:00
hid i2c-hid: properly terminate i2c_hid_dmi_desc_override_table[] array 2019-04-27 09:36:41 +02:00
hsi
hv Drivers: hv: vmbus: Check for ring when getting debug info 2019-01-31 08:14:36 +01:00
hwmon hwmon: (w83773g) Select REGMAP_I2C to fix build error 2019-04-17 08:38:47 +02:00
hwspinlock
hwtracing intel_th: gth: Fix an off-by-one in output unassigning 2019-05-02 09:58:56 +02:00
i2c i2c: Prevent runtime suspend of adapter when Host Notify is required 2019-05-08 07:21:43 +02:00
ide ide: fix a typo in the settings proc file name 2019-01-31 08:14:42 +01:00
idle
iio io: accel: kxcjk1013: restore the range after resume. 2019-04-27 09:36:35 +02:00
infiniband RDMA/mlx5: Do not allow the user to write to the clock page 2019-05-02 09:58:54 +02:00
input Input: synaptics-rmi4 - write config register values to the right offset 2019-05-02 09:58:55 +02:00
iommu iommu/amd: Reserve exclusion range in iova-domain 2019-05-04 09:20:22 +02:00
ipack
irqchip irqchip/mbigen: Don't clear eventid when freeing an MSI 2019-04-20 09:15:59 +02:00
isdn mISDN: hfcpci: Test both vendor & device ID for Digium HFC4S 2019-04-03 06:26:16 +02:00
leds leds: trigger: netdev: use memcpy in device_name_store 2019-05-04 09:20:22 +02:00
lightnvm lightnvm: pblk: add lock protection to list operations 2019-02-12 19:47:08 +01:00
macintosh
mailbox mailbox: bcm-flexrm-mailbox: Fix FlexRM ring flush timeout issue 2019-03-23 20:09:49 +01:00
mcb
md dm integrity: fix deadlock with overlapping I/O 2019-04-17 08:38:54 +02:00
media media: au0828: cannot kfree dev before usb disconnect 2019-04-20 09:16:01 +02:00
memory memory: ti-aemif: fix a potential NULL-pointer dereference 2018-09-06 10:04:07 -07:00
memstick memstick: Prevent memstick host from getting runtime suspended during card detection 2019-02-12 19:47:10 +01:00
message
mfd mfd: sm501: Fix potential NULL pointer dereference 2019-03-23 20:10:09 +01:00
misc lkdtm: Add tests for NULL pointer dereference 2019-04-20 09:16:04 +02:00
mmc mmc: sdhci: Handle auto-command errors 2019-04-27 09:36:39 +02:00
mtd mtd: rawnand: gpmi: fix MX28 bus master lockup problem 2019-02-15 08:10:10 +01:00
mux mux: adgs1408: use the correct MODULE_LICENSE 2018-10-12 17:36:39 +02:00
net mwifiex: Make resume actually do something useful again on SDIO cards 2019-05-08 07:21:42 +02:00
nfc NFC: nfcmrvl_uart: fix OF child-node lookup 2018-11-13 11:08:48 -08:00
ntb
nubus
nvdimm libnvdimm: Fix altmap reservation size calculation 2019-03-23 20:09:53 +01:00
nvme nvme-loop: init nvmet_ctrl fatal_err_work when allocate 2019-05-08 07:21:44 +02:00
nvmem nvmem: check the return value of nvmem_add_cells() 2018-11-13 11:08:35 -08:00
of of: overlay: do not duplicate properties from overlay for new nodes 2019-02-06 17:30:16 +01:00
opp OPP: Use opp_table->regulators to verify no regulator case 2019-02-12 19:47:08 +01:00
oprofile
parisc
parport parport_pc: fix find_superio io compare code, should use equal test. 2019-03-23 20:10:05 +01:00
pci PCI: Blacklist power management of Gigabyte X299 DESIGNARE EX PCIe ports 2019-04-20 09:16:04 +02:00
pcmcia pcmcia: Implement CLKRUN protocol disabling for Ricoh bridges 2018-11-13 11:08:17 -08:00
perf perf/aux: Make perf_event accessible to setup_aux() 2019-04-05 22:33:11 +02:00
phy phy: sun4i-usb: Support set_mode to USB_HOST for non-OTG PHYs 2019-04-03 06:26:27 +02:00
pinctrl pinctrl: core: make sure strcmp() doesn't get a null parameter 2019-04-20 09:16:01 +02:00
platform platform/x86: Add Intel AtomISP2 dummy / power-management driver 2019-04-20 09:16:02 +02:00
pnp
power power: supply: charger-manager: Fix incorrect return value 2019-03-27 14:14:43 +09:00
powercap
pps
ps3
ptp ptp: Fix pass zero to ERR_PTR() in ptp_clock_register 2019-02-12 19:47:01 +01:00
pwm
rapidio
ras
regulator regulator: act8865: Fix act8600_sudcdc_voltage_ranges setting 2019-04-05 22:33:15 +02:00
remoteproc remoteproc: qcom: q6v5: Propagate EPROBE_DEFER 2018-11-13 11:08:52 -08:00
reset
rpmsg rpmsg: smd: fix memory leak on channel create 2018-11-13 11:08:55 -08:00
rtc rtc: m41t80: Correct alarm month range with RTC reads 2019-01-09 17:38:48 +01:00
s390 scsi: zfcp: reduce flood of fcrscn1 trace records on multi-element RSCN 2019-05-04 09:20:21 +02:00
sbus drivers/sbus/char: add of_node_put() 2018-12-21 14:15:17 +01:00
scsi scsi: qla4xxx: fix a potential NULL pointer dereference 2019-05-04 09:20:20 +02:00
sfi
sh
siox
slimbus slimbus: ngd: mark PM functions as __maybe_unused 2018-12-19 19:19:49 +01:00
sn
soc soc/tegra: pmc: Drop locking from tegra_powergate_is_powered() 2019-04-20 09:16:03 +02:00
soundwire soundwire: Fix acquiring bus lock twice during master release 2018-08-27 09:49:48 +05:30
spi spi: pxa2xx: Setup maximum supported DMA transfer length 2019-03-23 20:09:57 +01:00
spmi
ssb
staging staging: rtlwifi: Fix potential NULL pointer dereference of kzalloc 2019-05-04 09:20:17 +02:00
target scsi: target/iscsi: Avoid iscsit_release_commands_from_conn() deadlock 2019-03-23 20:09:59 +01:00
tc TC: Set DMA masks for devices 2018-11-13 11:08:51 -08:00
tee tee: optee: avoid possible double list_del() 2019-02-12 19:47:08 +01:00
thermal thermal/intel_powerclamp: fix truncated kthread name 2019-04-20 09:15:56 +02:00
thunderbolt thunderbolt: Prevent root port runtime suspend during NVM upgrade 2018-12-17 09:24:36 +01:00
tty serial: ar933x_uart: Fix build failure with disabled console 2019-05-04 09:20:13 +02:00
uio uio: Fix an Oops on load 2018-11-27 16:13:09 +01:00
usb USB: core: Fix bug caused by duplicate interface PM usage counter 2019-05-08 07:21:44 +02:00
uwb
vfio vfio/type1: Limit DMA mappings per container 2019-05-02 09:58:55 +02:00
vhost vhost: reject zero size iova range 2019-04-27 09:36:31 +02:00
video backlight: pwm_bl: Use gpiod_get_value_cansleep() to get initial state 2019-04-05 22:33:13 +02:00
virt vbox: fix link error with 'gcc -Og' 2019-02-12 19:46:59 +01:00
virtio virtio: Honour 'may_reduce_num' in vring_create_virtqueue 2019-04-17 08:38:52 +02:00
visorbus
vlynq
vme
w1 USB: w1 ds2490: Fix bug caused by improper use of altsetting array 2019-05-08 07:21:43 +02:00
watchdog watchdog: mt7621_wdt/rt2880_wdt: Fix compilation problem 2019-02-27 10:08:52 +01:00
xen xen/gntdev: Do not destroy context while dma-bufs are in use 2019-04-05 22:33:06 +02:00
zorro
Kconfig
Makefile