On Thu, Apr 18 2013, Wanlong Gao wrote: > > A bio is always fully initialized, regardless of which internal > > allocator it came from. If people are doing private kmallocs, then they > > better be using bio_init() as well. > > > > Wanlong, would it be possible to get a full dmesg on boot see I can see > > what drivers and file systems are in use? Anything special about your > > setup. > > Sure, attached. Does the below help? diff --git a/kernel/trace/blktrace.c b/kernel/trace/blktrace.c index 9e5b8c2..f9a51a6 100644 --- a/kernel/trace/blktrace.c +++ b/kernel/trace/blktrace.c @@ -780,15 +780,23 @@ static void blk_add_trace_bio_bounce(void *ignore, blk_add_trace_bio(q, bio, BLK_TA_BOUNCE, 0); } +static struct request_queue *blk_trace_get_queue(struct block_device *bdev) +{ + if (bdev->bd_disk == NULL) + return NULL; + + return bdev_get_queue(bdev); +} + static void blk_add_trace_bio_complete(void *ignore, struct bio *bio, int error) { struct request_queue *q; struct blk_trace *bt; - if (!bio->bi_bdev) + q = blk_trace_get_queue(bio->bi_bdev); + if (!q) return; - q = bdev_get_queue(bio->bi_bdev); bt = q->blk_trace; /* @@ -1641,14 +1649,6 @@ static ssize_t blk_trace_mask2str(char *buf, int mask) return p - buf; } -static struct request_queue *blk_trace_get_queue(struct block_device *bdev) -{ - if (bdev->bd_disk == NULL) - return NULL; - - return bdev_get_queue(bdev); -} - static ssize_t sysfs_blk_trace_attr_show(struct device *dev, struct device_attribute *attr, char *buf) -- Jens Axboe -- dm-devel mailing list dm-devel@xxxxxxxxxx https://www.redhat.com/mailman/listinfo/dm-devel