Commit e5b521ee authored by Yufen Yu's avatar Yufen Yu Committed by Jens Axboe

md: fix spelling typo and add necessary space

This patch fix a spelling typo and add necessary space for code.
In addition, the patch get rid of the unnecessary 'if'.
Signed-off-by: default avatarYufen Yu <yuyufen@huawei.com>
Signed-off-by: default avatarSong Liu <songliubraving@fb.com>
Signed-off-by: default avatarJens Axboe <axboe@kernel.dk>
parent 168b305b
...@@ -5639,8 +5639,7 @@ int md_run(struct mddev *mddev) ...@@ -5639,8 +5639,7 @@ int md_run(struct mddev *mddev)
spin_unlock(&mddev->lock); spin_unlock(&mddev->lock);
rdev_for_each(rdev, mddev) rdev_for_each(rdev, mddev)
if (rdev->raid_disk >= 0) if (rdev->raid_disk >= 0)
if (sysfs_link_rdev(mddev, rdev)) sysfs_link_rdev(mddev, rdev); /* failure here is OK */
/* failure here is OK */;
if (mddev->degraded && !mddev->ro) if (mddev->degraded && !mddev->ro)
/* This ensures that recovering status is reported immediately /* This ensures that recovering status is reported immediately
...@@ -8190,8 +8189,7 @@ void md_do_sync(struct md_thread *thread) ...@@ -8190,8 +8189,7 @@ void md_do_sync(struct md_thread *thread)
{ {
struct mddev *mddev = thread->mddev; struct mddev *mddev = thread->mddev;
struct mddev *mddev2; struct mddev *mddev2;
unsigned int currspeed = 0, unsigned int currspeed = 0, window;
window;
sector_t max_sectors,j, io_sectors, recovery_done; sector_t max_sectors,j, io_sectors, recovery_done;
unsigned long mark[SYNC_MARKS]; unsigned long mark[SYNC_MARKS];
unsigned long update_time; unsigned long update_time;
...@@ -8248,7 +8246,7 @@ void md_do_sync(struct md_thread *thread) ...@@ -8248,7 +8246,7 @@ void md_do_sync(struct md_thread *thread)
* 0 == not engaged in resync at all * 0 == not engaged in resync at all
* 2 == checking that there is no conflict with another sync * 2 == checking that there is no conflict with another sync
* 1 == like 2, but have yielded to allow conflicting resync to * 1 == like 2, but have yielded to allow conflicting resync to
* commense * commence
* other == active in resync - this many blocks * other == active in resync - this many blocks
* *
* Before starting a resync we must have set curr_resync to * Before starting a resync we must have set curr_resync to
...@@ -8379,7 +8377,7 @@ void md_do_sync(struct md_thread *thread) ...@@ -8379,7 +8377,7 @@ void md_do_sync(struct md_thread *thread)
/* /*
* Tune reconstruction: * Tune reconstruction:
*/ */
window = 32*(PAGE_SIZE/512); window = 32 * (PAGE_SIZE / 512);
pr_debug("md: using %dk window, over a total of %lluk.\n", pr_debug("md: using %dk window, over a total of %lluk.\n",
window/2, (unsigned long long)max_sectors/2); window/2, (unsigned long long)max_sectors/2);
...@@ -9192,7 +9190,6 @@ static void check_sb_changes(struct mddev *mddev, struct md_rdev *rdev) ...@@ -9192,7 +9190,6 @@ static void check_sb_changes(struct mddev *mddev, struct md_rdev *rdev)
* perform resync with the new activated disk */ * perform resync with the new activated disk */
set_bit(MD_RECOVERY_NEEDED, &mddev->recovery); set_bit(MD_RECOVERY_NEEDED, &mddev->recovery);
md_wakeup_thread(mddev->thread); md_wakeup_thread(mddev->thread);
} }
/* device faulty /* device faulty
* We just want to do the minimum to mark the disk * We just want to do the minimum to mark the disk
......
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