From af579d68c35b7746b8aaa37455a35074f3bd0d02 Mon Sep 17 00:00:00 2001 From: Bart Van Assche Date: Mon, 22 Nov 2021 03:48:38 +0000 Subject: [PATCH] scst_local: Port to Linux kernel v5.16 git-svn-id: http://svn.code.sf.net/p/scst/svn/trunk@9599 d57e44dd-8a1f-0410-8b47-8ef2f437770f --- scst_local/scst_local.c | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/scst_local/scst_local.c b/scst_local/scst_local.c index 2715d61aa..081150be8 100644 --- a/scst_local/scst_local.c +++ b/scst_local/scst_local.c @@ -925,7 +925,7 @@ static int scst_local_queuecommand_lck(struct scsi_cmnd *scmd, if (sess->unregistering) { scmd->result = DID_BAD_TARGET << 16; - scmd->scsi_done(scmd); + scsi_done(scmd); return 0; } @@ -1420,7 +1420,11 @@ static int scst_local_targ_xmit_response(struct scst_cmd *scst_cmd) done = tgt_specific->done; #else scmd = scst_cmd_get_tgt_priv(scst_cmd); +#if LINUX_VERSION_CODE < KERNEL_VERSION(5, 16, 0) done = scmd->scsi_done; +#else + done = scsi_done; +#endif #endif /*