Thanks Jonathan for your inputs.<br><br>Since I am new to Linux Kernel Development I am learning the process of patch posting and development, once I will<br>be done with that I will post the patch for review.<br><br>Regards,<br>
Piyush<br><br><div class="gmail_quote">On Thu, Jun 30, 2011 at 1:13 AM, Jonathan Neuschäfer <span dir="ltr"><<a href="mailto:j.neuschaefer@gmx.net">j.neuschaefer@gmx.net</a>></span> wrote:<br><blockquote class="gmail_quote" style="border-left: 1px solid rgb(204, 204, 204); margin: 0pt 0pt 0pt 0.8ex; padding-left: 1ex;">
<div><div></div><div class="h5">On Mon, Jun 27, 2011 at 02:23:24PM +0530, piyush moghe wrote:<br>
> Hi All,<br>
><br>
> I am new to linux kernel code and interested in filesystems and block I/O.<br>
><br>
> While going through the block read code ( in __bread function ) I found that<br>
> when we try to read the block ( __getblk ) we first check for the block<br>
> buffer page in page cache ( using __find_get_block function ) and if not we<br>
> do a slow path ( using __getblk_slow function which checks page in cache<br>
> again and if not found again then allocate a buffer page in cache ).<br>
><br>
> Now my problem is, as part of __getblk_slow we compare block size with bdev<br>
> logical block size and also check that block size should not be less than<br>
> 512 and not greater than PAGE_SIZE ( 4K, for PAGE_SHIFT set to 13 )<br>
> although these all checks can be moved to upper level function i.e __getblk<br>
> and that too before calling __find_get_block ( to find block in page cache )<br>
> so as to avoid looking for block in page cache if the size is invalid.<br>
</div></div>Sounds reasonable.<br>
<div class="im"><br>
><br>
> Please let me know your comments on this.<br>
<br>
</div>I think this is advanced enough to be discussed on the LKML, just send<br>
an RFC (request for comments) patch and someone should comment. But<br>
LKML can be a bit harsh if you're not used to it.<br>
<br>
If you want to discuss it here, you might also want to send a patch<br>
in addition to your thoughts, it's just a lot easier to get the context<br>
and the exact thing you're trying to do from a patch than from mere<br>
words.<br>
<br>
HTH,<br>
<font color="#888888"> Jonathan Neuschäfer<br>
</font></blockquote></div><br>