mirror of
https://github.com/AuxXxilium/linux_dsm_epyc7002.git
synced 2025-02-17 00:17:41 +07:00
sd: retry discard commands
Currently cmd->allowed is initialized from rq->retries for discard commands, but retries is always 0 for non-BLOCK_PC requests. Set it to the standard number of retries instead. Signed-off-by: Christoph Hellwig <hch@lst.de> Reviewed-by: Martin K. Petersen <martin.petersen@oracle.com> Reviewed-by: Hannes Reinecke <hare@suse.de>
This commit is contained in:
parent
a25ee54851
commit
e4200f8ee3
@ -758,7 +758,7 @@ static int sd_setup_discard_cmnd(struct scsi_cmnd *cmd)
|
||||
rq->timeout = SD_TIMEOUT;
|
||||
|
||||
cmd->transfersize = len;
|
||||
cmd->allowed = rq->retries;
|
||||
cmd->allowed = SD_MAX_RETRIES;
|
||||
|
||||
/*
|
||||
* Initially __data_len is set to the amount of data that needs to be
|
||||
|
Loading…
Reference in New Issue
Block a user