From: Tejun Heo Date: Wed, 19 Oct 2011 12:31:15 +0000 (+0200) Subject: block: fix genhd refcounting in blkio_policy_parse_and_set() X-Git-Tag: v3.2-rc1~49^2~17 X-Git-Url: http://git.openpandora.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=ece84241b93c4693bfe0a8ec9a043a16d216d0cd;p=pandora-kernel.git block: fix genhd refcounting in blkio_policy_parse_and_set() blkio_policy_parse_and_set() calls blkio_check_dev_num() to check whether the given dev_t is valid. blkio_check_dev_num() uses get_gendisk() for verification but never puts the returned genhd leaking the reference. This patch collapses blkio_check_dev_num() into its caller and updates it such that the genhd is put before returning. Signed-off-by: Tejun Heo Signed-off-by: Jens Axboe --- Reading git-diff-tree failed