diff options
author | 2017-03-10 12:09:49 -0800 | |
---|---|---|
committer | 2017-03-13 08:27:34 -0600 | |
commit | 4a3a485b1ed0e109718cc8c9d094fa0f552de9b2 (patch) | |
tree | 7e400cfc12120881e18efc4c6da3deefd6e50c3b /tools/perf/scripts/python/call-graph-from-postgresql.py | |
parent | blk-mq: Fix tagset reinit in the presence of cpu hot-unplug (diff) | |
download | linux-dev-4a3a485b1ed0e109718cc8c9d094fa0f552de9b2.tar.xz linux-dev-4a3a485b1ed0e109718cc8c9d094fa0f552de9b2.zip |
writeback: fix memory leak in wb_queue_work()
When WB_registered flag is not set, wb_queue_work() skips queuing the
work, but does not perform the necessary clean up. In particular, if
work->auto_free is true, it should free the memory.
The leak condition can be reprouced by following these steps:
mount /dev/sdb /mnt/sdb
/* In qemu console: device_del sdb */
umount /dev/sdb
Above will result in a wb_queue_work() call on an unregistered wb and
thus leak memory.
Reported-by: John Sperbeck <jsperbeck@google.com>
Signed-off-by: Tahsin Erdogan <tahsin@google.com>
Reviewed-by: Jan Kara <jack@suse.cz>
Signed-off-by: Jens Axboe <axboe@fb.com>
Diffstat (limited to 'tools/perf/scripts/python/call-graph-from-postgresql.py')
0 files changed, 0 insertions, 0 deletions