aboutsummaryrefslogtreecommitdiffstats
path: root/block
diff options
context:
space:
mode:
authorTejun Heo <tj@kernel.org>2008-08-25 06:56:12 -0400
committerJens Axboe <jens.axboe@oracle.com>2008-10-09 02:56:08 -0400
commit0762b8bde9729f10f8e6249809660ff2ec3ad735 (patch)
tree12aa94ef16b840f713f833c712d335646c816dc1 /block
parent4c46501d1659475dc6c89554af6ce7fe6ecf615c (diff)
block: always set bdev->bd_part
Till now, bdev->bd_part is set only if the bdev was for parts other than part0. This patch makes bdev->bd_part always set so that code paths don't have to differenciate common handling. Signed-off-by: Tejun Heo <tj@kernel.org> Signed-off-by: Jens Axboe <jens.axboe@oracle.com>
Diffstat (limited to 'block')
-rw-r--r--block/blk-core.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/block/blk-core.c b/block/blk-core.c
index e0a5ee36849c..a4a7c08d2f20 100644
--- a/block/blk-core.c
+++ b/block/blk-core.c
@@ -1274,7 +1274,7 @@ __setup("fail_make_request=", setup_fail_make_request);
1274static int should_fail_request(struct bio *bio) 1274static int should_fail_request(struct bio *bio)
1275{ 1275{
1276 if ((bio->bi_bdev->bd_disk->flags & GENHD_FL_FAIL) || 1276 if ((bio->bi_bdev->bd_disk->flags & GENHD_FL_FAIL) ||
1277 (bio->bi_bdev->bd_part && bio->bi_bdev->bd_part->make_it_fail)) 1277 bio->bi_bdev->bd_part->make_it_fail)
1278 return should_fail(&fail_make_request, bio->bi_size); 1278 return should_fail(&fail_make_request, bio->bi_size);
1279 1279
1280 return 0; 1280 return 0;