Skip to content

Commit

Permalink
blk-iolatency: fix blkg leak in timer_fn
Browse files Browse the repository at this point in the history
At this point we have a ref on the blkg, we need to drop it if we don't
have a iolat.

Signed-off-by: Josef Bacik <[email protected]>
Signed-off-by: Jens Axboe <[email protected]>
  • Loading branch information
josefbacik authored and axboe committed Aug 1, 2018
1 parent 4725549 commit 52a1199
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion block/blk-iolatency.c
Original file line number Diff line number Diff line change
Expand Up @@ -627,7 +627,7 @@ static void blkiolatency_timer_fn(struct timer_list *t)

iolat = blkg_to_lat(blkg);
if (!iolat)
continue;
goto next;

lat_info = &iolat->child_lat;
cookie = atomic_read(&lat_info->scale_cookie);
Expand Down

0 comments on commit 52a1199

Please sign in to comment.