summaryrefslogtreecommitdiff
path: root/block
diff options
context:
space:
mode:
authorBart Van Assche <bart.vanassche@sandisk.com>2017-04-26 13:47:54 -0700
committerJens Axboe <axboe@fb.com>2017-04-26 15:09:04 -0600
commitfd07dc81850e8bf26046bf7ccd7430211c9c5910 (patch)
tree2dbb39aa7dd17b3ab9be4a743969ead78d8d4571 /block
parent65ca1ca32ca359e9d75a6fd293128d188dfc0d8a (diff)
blk-mq: Make blk_flags_show() callers append a newline character
This patch does not change any functionality but makes it possible to produce a single line of output with multiple flag-to-name translations. Signed-off-by: Bart Van Assche <bart.vanassche@sandisk.com> Reviewed-by: Omar Sandoval <osandov@fb.com> Reviewed-by: Hannes Reinecke <hare@suse.com> Signed-off-by: Jens Axboe <axboe@fb.com>
Diffstat (limited to 'block')
-rw-r--r--block/blk-mq-debugfs.c4
1 files changed, 3 insertions, 1 deletions
diff --git a/block/blk-mq-debugfs.c b/block/blk-mq-debugfs.c
index 1132be4e9c1c..ccc7b0f71230 100644
--- a/block/blk-mq-debugfs.c
+++ b/block/blk-mq-debugfs.c
@@ -60,7 +60,6 @@ static int blk_flags_show(struct seq_file *m, const unsigned long flags,
else
seq_printf(m, "%d", i);
}
- seq_puts(m, "\n");
return 0;
}
@@ -102,6 +101,7 @@ static int blk_queue_flags_show(struct seq_file *m, void *v)
blk_flags_show(m, q->queue_flags, blk_queue_flag_name,
ARRAY_SIZE(blk_queue_flag_name));
+ seq_puts(m, "\n");
return 0;
}
@@ -193,6 +193,7 @@ static int hctx_state_show(struct seq_file *m, void *v)
blk_flags_show(m, hctx->state, hctx_state_name,
ARRAY_SIZE(hctx_state_name));
+ seq_puts(m, "\n");
return 0;
}
@@ -236,6 +237,7 @@ static int hctx_flags_show(struct seq_file *m, void *v)
blk_flags_show(m,
hctx->flags ^ BLK_ALLOC_POLICY_TO_MQ_FLAG(alloc_policy),
hctx_flag_name, ARRAY_SIZE(hctx_flag_name));
+ seq_puts(m, "\n");
return 0;
}