Re: [PATCH -next] mm/filemap: fix that first page is not mark accessed in filemap_read()

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Thu, Jun 02, 2022 at 04:21:29PM +0800, Yu Kuai wrote:
> In filemap_read(), 'ra->prev_pos' is set to 'iocb->ki_pos + copied',
> while it should be 'iocb->ki_ops'.

Can you walk me through your reasoning which leads you to believe that
it should be ki_pos instead of ki_pos + copied?  As I understand it,
prev_pos is the end of the previous read, not the beginning of the
previous read.

For consequence,
> folio_mark_accessed() will not be called for 'fbatch.folios[0]' since
> 'iocb->ki_pos' is always equal to 'ra->prev_pos'.

I don't follow this, but maybe I'm just being slow.




[Index of Archives]     [Linux ARM Kernel]     [Linux ARM]     [Linux Omap]     [Fedora ARM]     [IETF Annouce]     [Bugtraq]     [Linux OMAP]     [Linux MIPS]     [eCos]     [Asterisk Internet PBX]     [Linux API]

  Powered by Linux