]> git.baikalelectronics.ru Git - kernel.git/commit
mtip32xx: fix up the checking for internal command failure
authorJens Axboe <axboe@kernel.dk>
Fri, 23 Jun 2017 15:18:54 +0000 (09:18 -0600)
committerJens Axboe <axboe@kernel.dk>
Fri, 23 Jun 2017 15:18:54 +0000 (09:18 -0600)
commit1bcf60f423b214f06b76179267818b360ff117d2
tree0778d025344fed439505041f203c94a0813be86b
parent9f527d0147e37efe50b7a0e5eee5197a73582268
mtip32xx: fix up the checking for internal command failure

This fixes up two commits that have touched this driver. The
command status field is now a blk_status_t, so we can't check
for < 0 and we definitely can't assume it's holding -Exxxx error
values. All we care about here is whether ->status is zero or not.
Check for that, and remove the various attempts at smart error
reporting. Just log to dmesg what command failed, and the
blk_status_t value.

Reported-by: Dan Carpenter <dan.carpenter@oracle.com>
Fixes: dca3287b2d12 ("block: introduce new block status code type")
Fixes: 5f9582d0f4ce ("mtip32xx: convert internal command issue to block IO path")
Signed-off-by: Jens Axboe <axboe@kernel.dk>
drivers/block/mtip32xx/mtip32xx.c