kernel-hacking-2024-linux-s.../drivers/block
Keith Busch 0e53d18051 NVMe: Surprise removal handling
This adds checks to see if the nvme pci device was removed. The check
reads the status register for the value of -1, which it should never be
unless the device is no longer present.

If a user performs a surprise removal on an nvme device, the driver will
be notified either by the pci driver remove callback if the platform's
slot is capable of this event, or via reading the device BAR status
register, which will indicate controller failure and trigger a reset.

Either way, the device is not present so all outstanding commands would
timeout. This will not send queue deletion commands to a drive that
isn't present and fail after ioremap, significantly speeding up surprise
removal; previously this took over 2 minutes per IO queue pair created,
but this will complete removing the device within a few seconds.

Signed-off-by: Keith Busch <keith.busch@intel.com>
Signed-off-by: Matthew Wilcox <matthew.r.wilcox@intel.com>
2014-01-27 19:28:43 -05:00
..
aoe aoe: do not BUG if memory pressure prevented debugfs file creation 2013-09-11 15:59:28 -07:00
drbd drbd: avoid to shrink max_bio_size due to peer re-configuration 2013-11-08 09:10:29 -07:00
mtip32xx mtip32xx: dynamically allocate buffer in debugfs functions 2013-11-08 09:10:28 -07:00
paride
rsxx rsxx: Fix possible kernel panic with invalid config. 2013-11-08 09:10:29 -07:00
xen-blkback xen/blkback: fix reference counting 2013-11-08 09:10:27 -07:00
amiflop.c tree-wide: use reinit_completion instead of INIT_COMPLETION 2013-11-15 09:32:21 +09:00
ataflop.c
brd.c block: fix a probe argument to blk_register_region 2013-11-08 08:59:39 -07:00
cciss.c tree-wide: use reinit_completion instead of INIT_COMPLETION 2013-11-15 09:32:21 +09:00
cciss.h
cciss_cmd.h
cciss_scsi.c
cciss_scsi.h
cpqarray.c cpqarray: fix info leak in ida_locked_ioctl() 2013-09-24 17:00:26 -07:00
cpqarray.h
cryptoloop.c
DAC960.c
DAC960.h
floppy.c block: make rq->cmd_flags be 64-bit 2013-10-25 11:55:59 +01:00
hd.c
ida_cmd.h
ida_ioctl.h
Kconfig Merge branch 'for-3.13/post-mq-drivers' into for-linus 2013-11-14 08:29:01 -07:00
loop.c loop: fix crash when using unassigned loop device 2013-11-08 09:10:28 -07:00
loop.h
Makefile Merge branch 'for-3.13/post-mq-drivers' into for-linus 2013-11-14 08:29:01 -07:00
mg_disk.c mg_disk: remove deprecated IRQF_DISABLED 2013-11-08 09:10:27 -07:00
nbd.c
null_blk.c null_blk: multi queue aware block test driver 2013-10-25 11:56:00 +01:00
nvme-core.c NVMe: Surprise removal handling 2014-01-27 19:28:43 -05:00
nvme-scsi.c NVMe: compat SG_IO ioctl 2013-12-16 15:49:40 -05:00
osdblk.c block: replace strict_strtoul() with kstrtoul() 2013-09-11 15:56:56 -07:00
pktcdvd.c pktcdvd: debugfs functions return NULL on error 2013-11-08 09:10:31 -07:00
ps3disk.c
ps3vram.c
rbd.c Merge branch 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/sage/ceph-client 2013-09-19 12:50:37 -05:00
rbd_types.h
skd_main.c skd: reorder construct/destruct code 2013-11-08 09:10:30 -07:00
skd_s1120.h skd: fix formatting in skd_s1120.h 2013-11-08 09:10:30 -07:00
smart1,2.h
sunvdc.c
swim.c drivers/block/swim.c: remove unnecessary platform_set_drvdata() 2013-09-11 15:56:59 -07:00
swim3.c
swim_asm.S
sx8.c
umem.c
umem.h
virtio_blk.c Merge branch 'for-linus' of git://git.kernel.dk/linux-block 2013-11-15 16:33:41 -08:00
xen-blkfront.c xen-blkfront: restore the non-persistent data path 2013-11-08 09:10:30 -07:00
xsysace.c xilinx systemace: Fix sparse warnings 2013-07-10 07:47:12 +02:00
z2ram.c