From 17ea26c2d80a695b4d3af9ae2eaa438095029773 Mon Sep 17 00:00:00 2001 From: Hannes Reinecke Date: Mon, 16 Nov 2020 19:40:36 +0100 Subject: scsi: drop 'result' argument from command_complete callback The command complete callback has a SCSIRequest as the first argument, and the status field of that structure is identical to the 'status' argument. So drop the argument from the callback. Signed-off-by: Hannes Reinecke Message-Id: <20201116184041.60465-3-hare@suse.de> Signed-off-by: Paolo Bonzini --- hw/scsi/megasas.c | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) (limited to 'hw/scsi/megasas.c') diff --git a/hw/scsi/megasas.c b/hw/scsi/megasas.c index 5bfc92f..8f2389d 100644 --- a/hw/scsi/megasas.c +++ b/hw/scsi/megasas.c @@ -1852,13 +1852,12 @@ static void megasas_xfer_complete(SCSIRequest *req, uint32_t len) } } -static void megasas_command_complete(SCSIRequest *req, uint32_t status, - size_t resid) +static void megasas_command_complete(SCSIRequest *req, size_t resid) { MegasasCmd *cmd = req->hba_private; uint8_t cmd_status = MFI_STAT_OK; - trace_megasas_command_complete(cmd->index, status, resid); + trace_megasas_command_complete(cmd->index, req->status, resid); if (req->io_canceled) { return; @@ -1873,7 +1872,6 @@ static void megasas_command_complete(SCSIRequest *req, uint32_t status, return; } } else { - req->status = status; trace_megasas_scsi_complete(cmd->index, req->status, cmd->iov_size, req->cmd.xfer); if (req->status != GOOD) { -- cgit v1.1