Commit b3db8a21 authored by Guoqing Jiang's avatar Guoqing Jiang Committed by Song Liu

md: print errno in super_written

It is better to print errno instead of bi_status.
Signed-off-by: default avatarGuoqing Jiang <guoqing.jiang@cloud.ionos.com>
Signed-off-by: default avatarSong Liu <songliubraving@fb.com>
parent e3914d59
...@@ -978,7 +978,8 @@ static void super_written(struct bio *bio) ...@@ -978,7 +978,8 @@ static void super_written(struct bio *bio)
struct mddev *mddev = rdev->mddev; struct mddev *mddev = rdev->mddev;
if (bio->bi_status) { if (bio->bi_status) {
pr_err("md: super_written gets error=%d\n", bio->bi_status); pr_err("md: %s gets error=%d\n", __func__,
blk_status_to_errno(bio->bi_status));
md_error(mddev, rdev); md_error(mddev, rdev);
if (!test_bit(Faulty, &rdev->flags) if (!test_bit(Faulty, &rdev->flags)
&& (bio->bi_opf & MD_FAILFAST)) { && (bio->bi_opf & MD_FAILFAST)) {
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment