[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <4E1B3A1D.2050400@fusionio.com>
Date: Mon, 11 Jul 2011 19:59:57 +0200
From: Jens Axboe <jaxboe@...ionio.com>
To: Muthu Kumar <muthu.lkml@...il.com>
CC: "linux-kernel@...r.kernel.org" <linux-kernel@...r.kernel.org>
Subject: Re: [PATCH]: block: try-2 (modified): Initialize bi_rw in mpage so
bio_add can make use of it.
On 2011-07-11 19:52, Muthu Kumar wrote:
>> For this particular case, doing it when the bio is allocated makes more
>> sense. That will avoid a similar error in there in the future.
>>
>
> Sounds good. Thanks. How about for other cases that alloc a new bio
> and do bio_add_page() - like blkdev_issue_zeroout() and similar.
> Should we add there too?
Good question, ideally the allocator should be passed in the rw argument
since we need it before even submitting it for the merge cases. We don't
have _that_ many callers of bio_alloc() or bio_kmalloc(), so probably
the best option is just to bite the bullet and change the prototypes to
take the 'rw' argument there. Oh, and the bioset variants, too.
bio_init() should be passed the 'rw' argument from the allcators, so we
catch any private use of that, too.
--
Jens Axboe
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/
Powered by blists - more mailing lists