diff options
author | Markus Elfring <elfring@users.sourceforge.net> | 2017-01-21 22:44:07 +0100 |
---|---|---|
committer | Jens Axboe <axboe@fb.com> | 2017-01-23 16:32:18 +0100 |
commit | 1cf417530375b475d4a8a9f18dc0867f91e52d78 (patch) | |
tree | a2527f6374c48879d79dcd5b374c8159717aebce /block/cfq-iosched.c | |
parent | blk-throttle: Adjust two function calls together with a variable assignment (diff) | |
download | linux-1cf417530375b475d4a8a9f18dc0867f91e52d78.tar.xz linux-1cf417530375b475d4a8a9f18dc0867f91e52d78.zip |
cfq-iosched: Adjust one function call together with a variable assignment
The script "checkpatch.pl" pointed information out like the following.
ERROR: do not use assignment in if condition
Thus fix the affected source code place.
Signed-off-by: Markus Elfring <elfring@users.sourceforge.net>
Signed-off-by: Jens Axboe <axboe@fb.com>
Diffstat (limited to '')
-rw-r--r-- | block/cfq-iosched.c | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/block/cfq-iosched.c b/block/cfq-iosched.c index c472886c727f..f0f29ee731e1 100644 --- a/block/cfq-iosched.c +++ b/block/cfq-iosched.c @@ -2749,9 +2749,11 @@ static struct cfq_queue *cfq_get_next_queue_forced(struct cfq_data *cfqd) if (!cfqg) return NULL; - for_each_cfqg_st(cfqg, i, j, st) - if ((cfqq = cfq_rb_first(st)) != NULL) + for_each_cfqg_st(cfqg, i, j, st) { + cfqq = cfq_rb_first(st); + if (cfqq) return cfqq; + } return NULL; } |