ANDROID: scsi: Introduce scsi_done()

Before backporting upstream patches that use scsi_done(), introduce that
function. See also upstream commit a710eacb9d ("scsi: core: Rename
scsi_mq_done() into scsi_done() and export it").

Bug: 204438323
Change-Id: Ic6624fe7b9958febea28ef37b3fe5f37a573c7ee
Signed-off-by: Bart Van Assche <bvanassche@google.com>
This commit is contained in:
Bart Van Assche
2021-11-29 15:28:12 -08:00
parent 63dc7ea182
commit 495d7f2c47

View File

@@ -173,6 +173,12 @@ static inline struct scsi_driver *scsi_cmd_to_driver(struct scsi_cmnd *cmd)
return *(struct scsi_driver **)rq->rq_disk->private_data;
}
/* A helper function to make it easier to backport upstream SCSI patches. */
static inline void scsi_done(struct scsi_cmnd *cmd)
{
cmd->scsi_done(cmd);
}
extern void scsi_finish_command(struct scsi_cmnd *cmd);
extern void *scsi_kmap_atomic_sg(struct scatterlist *sg, int sg_count,