]> git.baikalelectronics.ru Git - kernel.git/commit
nvme initialize core quirks before calling nvme_init_subsystem
authorPankaj Raghav <p.raghav@samsung.com>
Thu, 1 Dec 2022 12:52:34 +0000 (13:52 +0100)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Wed, 14 Dec 2022 10:30:46 +0000 (11:30 +0100)
commita6c5b3d7e06f9913a8bb028edefb04276debead1
treeaf78841cc8a92cf905021917abb9add478a6b7b5
parent936375ea19ddf48d4535dd9678762484e634853e
nvme initialize core quirks before calling nvme_init_subsystem

[ Upstream commit 6f2d71524bcfdeb1fcbd22a4a92a5b7b161ab224 ]

A device might have a core quirk for NVME_QUIRK_IGNORE_DEV_SUBNQN
(such as Samsung X5) but it would still give a:

    "missing or invalid SUBNQN field"

warning as core quirks are filled after calling nvme_init_subnqn.  Fill
ctrl->quirks from struct core_quirks before calling nvme_init_subsystem
to fix this.

Tested on a Samsung X5.

Fixes: 5d6ab0cab767 ("nvme: track subsystems")
Signed-off-by: Pankaj Raghav <p.raghav@samsung.com>
Signed-off-by: Christoph Hellwig <hch@lst.de>
Signed-off-by: Sasha Levin <sashal@kernel.org>
drivers/nvme/host/core.c