diff options
author | Jes Sorensen <jsorensen@fb.com> | 2017-05-16 19:59:43 +0200 |
---|---|---|
committer | Jes Sorensen <jsorensen@fb.com> | 2017-05-16 19:59:43 +0200 |
commit | d7be7d87366a7f9b190bc4e41ea06f7c9984028e (patch) | |
tree | 48d43094e34376fa3dc7eab21546a10bc1119722 /Grow.c | |
parent | mdadm: Fixup a large number of bad formatting of logical operators (diff) | |
download | mdadm-d7be7d87366a7f9b190bc4e41ea06f7c9984028e.tar.xz mdadm-d7be7d87366a7f9b190bc4e41ea06f7c9984028e.zip |
mdadm: Fixup more broken logical operator formatting
Signed-off-by: Jes Sorensen <jsorensen@fb.com>
Diffstat (limited to 'Grow.c')
-rw-r--r-- | Grow.c | 16 |
1 files changed, 9 insertions, 7 deletions
@@ -3995,8 +3995,8 @@ int progress_reshape(struct mdinfo *info, struct reshape *reshape, * a backup. */ if (advancing) { - if ((need_backup > info->reshape_progress - || info->array.major_version < 0) && + if ((need_backup > info->reshape_progress || + info->array.major_version < 0) && *suspend_point < info->reshape_progress + target) { if (need_backup < *suspend_point + 2 * target) *suspend_point = need_backup; @@ -4149,8 +4149,9 @@ check_progress: * it was just a device failure that leaves us degraded but * functioning. */ - if (sysfs_get_str(info, NULL, "reshape_position", buf, sizeof(buf)) < 0 - || strncmp(buf, "none", 4) != 0) { + if (sysfs_get_str(info, NULL, "reshape_position", buf, + sizeof(buf)) < 0 || + strncmp(buf, "none", 4) != 0) { /* The abort might only be temporary. Wait up to 10 * seconds for fd to contain a valid number again. */ @@ -4182,9 +4183,10 @@ check_progress: /* Maybe racing with array shutdown - check state */ if (fd >= 0) close(fd); - if (sysfs_get_str(info, NULL, "array_state", buf, sizeof(buf)) < 0 - || strncmp(buf, "inactive", 8) == 0 - || strncmp(buf, "clear",5) == 0) + if (sysfs_get_str(info, NULL, "array_state", buf, + sizeof(buf)) < 0 || + strncmp(buf, "inactive", 8) == 0 || + strncmp(buf, "clear",5) == 0) return -2; /* abort */ return -1; /* complete */ } |