[PATCH 1/3] nvmet-auth: don't try to cancel a non-initialized work_struct
Hannes Reinecke
hare at suse.de
Tue Sep 20 23:15:08 PDT 2022
On 9/20/22 19:19, Christoph Hellwig wrote:
> Currently blktests nvme/002 trips up debugobjects if CONFIG_NVME_AUTH is
> enabled, but authentication is not on a queue. This is because
> nvmet_auth_sq_free cancels sq->auth_expired_work unconditionaly, while
> auth_expired_work is only ever initialized if authentication is enabled
> for a given controller.
>
> Fix this by calling most of what is nvmet_init_auth unconditionally
> when initializing the SQ, and just do the setting of the result
> field in the connect command handler.
>
> Fixes: db1312dd9548 ("nvmet: implement basic In-Band Authentication")
> Signed-off-by: Christoph Hellwig <hch at lst.de>
> ---
> drivers/nvme/target/core.c | 1 +
> drivers/nvme/target/fabrics-cmd-auth.c | 13 ++++---------
> drivers/nvme/target/fabrics-cmd.c | 6 ++++--
> drivers/nvme/target/nvmet.h | 7 ++++---
> 4 files changed, 13 insertions(+), 14 deletions(-)
>
Reviewed-by: Hannes Reinecke <hare at suse.de>
Cheers,
Hannes
--
Dr. Hannes Reinecke Kernel Storage Architect
hare at suse.de +49 911 74053 688
SUSE Software Solutions Germany GmbH, Maxfeldstr. 5, 90409 Nürnberg
HRB 36809 (AG Nürnberg), GF: Felix Imendörffer
More information about the Linux-nvme
mailing list