diff options
| author | 2018-10-09 13:11:33 +0200 | |
|---|---|---|
| committer | 2018-10-09 08:25:06 -0600 | |
| commit | 4b5d56edb8fc565c5db029aecaea598eadfba7f6 (patch) | |
| tree | a9dc2c04dc72290f55e01a55c1946a73195dabc5 /drivers/lightnvm/pblk-write.c | |
| parent | lightnvm: combine 1.2 and 2.0 command flags (diff) | |
| download | wireguard-linux-4b5d56edb8fc565c5db029aecaea598eadfba7f6.tar.xz wireguard-linux-4b5d56edb8fc565c5db029aecaea598eadfba7f6.zip | |
lightnvm: pblk: fix rqd.error return value in pblk_blk_erase_sync
rqd.error is masked by the return value of pblk_submit_io_sync.
The rqd structure is then passed on to the end_io function, which
assumes that any error should lead to a chunk being marked
offline/bad. Since the pblk_submit_io_sync can fail before the
command is issued to the device, the error value maybe not correspond
to a media failure, leading to chunks being immaturely retired.
Also, the pblk_blk_erase_sync function prints an error message in case
the erase fails. Since the caller prints an error message by itself,
remove the error message in this function.
Signed-off-by: Matias Bjørling <mb@lightnvm.io>
Reviewed-by: Javier González <javier@cnexlabs.com>
Reviewed-by: Hans Holmberg <hans.holmberg@cnexlabs.com>
Signed-off-by: Jens Axboe <axboe@kernel.dk>
Diffstat (limited to 'drivers/lightnvm/pblk-write.c')
0 files changed, 0 insertions, 0 deletions
