Message ID | 20180816160837.30cb63cf@gandalf.local.home (mailing list archive) |
---|---|
State | New, archived |
Headers | show |
Series | tracing/blktrace: Fix to allow setting same value | expand |
On 8/16/18 2:08 PM, Steven Rostedt wrote: > [ > Jens, you want to take this one, or do you want me to? > ] I can queue it up - done. Thanks!
diff --git a/kernel/trace/blktrace.c b/kernel/trace/blktrace.c index b82e546083e1..614b5f0decd6 100644 --- a/kernel/trace/blktrace.c +++ b/kernel/trace/blktrace.c @@ -1829,6 +1829,10 @@ static ssize_t sysfs_blk_trace_attr_store(struct device *dev, mutex_lock(&q->blk_trace_mutex); if (attr == &dev_attr_enable) { + if (!!value == !!q->blk_trace) { + ret = 0; + goto out_unlock_bdev; + } if (value) ret = blk_trace_setup_queue(q, bdev); else