linux_dsm_epyc7002/drivers/nvme/host
Niklas Cassel 108a58585b nvme: do not call del_gendisk() on a disk that was never added
device_add_disk() is negated by del_gendisk().
alloc_disk_node() is negated by put_disk().

In nvme_alloc_ns(), device_add_disk() is one of the last things being
called in the success case, and only void functions are being called
after this. Therefore this call should not be negated in the error path.

The superfluous call to del_gendisk() leads to the following prints:
[    7.839975] kobject: '(null)' (000000001ff73734): is not initialized, yet kobject_put() is being called.
[    7.840865] WARNING: CPU: 2 PID: 361 at lib/kobject.c:736 kobject_put+0x70/0x120

Fixes: 33cfdc2aa6 ("nvme: enforce extended LBA format for fabrics metadata")
Signed-off-by: Niklas Cassel <niklas.cassel@wdc.com>
Reviewed-by: Sagi Grimberg <sagi@grimberg.me>
Reviewed-by: Max Gurtovoy <maxg@mellanox.com>
Signed-off-by: Christoph Hellwig <hch@lst.de>
Signed-off-by: Jens Axboe <axboe@kernel.dk>
2020-06-11 09:10:05 -06:00
..
core.c nvme: do not call del_gendisk() on a disk that was never added 2020-06-11 09:10:05 -06:00
fabrics.c nvme-fabrics: Use scnprintf() for avoiding potential buffer overflow 2020-03-26 04:51:55 +09:00
fabrics.h nvme: Remove ADMIN_ONLY state 2019-10-14 23:21:44 +09:00
fault_inject.c
fc.c nvme: replace zero-length array with flexible-array 2020-05-27 07:12:37 +02:00
fc.h nvme-fc: Update header and host for common definitions for LS handling 2020-05-09 16:18:33 -06:00
hwmon.c nvme: hwmon: switch to use <linux/units.h> helpers 2020-01-31 10:30:40 -08:00
Kconfig nvme: Don't deter users from enabling hwmon support 2020-03-26 04:45:25 +09:00
lightnvm.c nvme: introduce namespace features flag 2020-05-27 07:12:38 +02:00
Makefile nvme: Add hardware monitoring support 2019-11-12 01:57:35 +09:00
multipath.c nvme: define constants for identification values 2020-05-09 16:18:36 -06:00
nvme.h block: remove the error argument to the block_bio_complete tracepoint 2020-06-04 21:16:11 -06:00
pci.c for-5.8/drivers-2020-06-01 2020-06-02 15:37:03 -07:00
rdma.c nvme-rdma: add metadata/T10-PI support 2020-05-27 07:12:39 +02:00
tcp.c nvme-tcp: set MSG_SENDPAGE_NOTLAST with MSG_MORE when we have more to send 2020-05-27 07:12:36 +02:00
trace.c
trace.h