Re: downgrade_write replacement in remap_file_pages

Andrea Arcangeli
2004-06-08T22:52:11Z

On Tue, Jun 08, 2004 at 12:36:21PM -0700, William Lee Irwin III wrote:
> On Tue, Jun 08, 2004 at 05:44:38PM +0200, Andrea Arcangeli wrote:
> > - if (pgoff != linear_page_index(vma, start) &&
> > - !(vma->vm_flags & VM_NONLINEAR)) {
> > + if (unlikely(pgoff != linear_pgoff && !(vma->vm_flags & VM_NONLINEAR))) {
>
> There is no linear_pgoff variable...

I tested it on a different codebase and I didn't notice this issue while
fixing the rejects, fixing it up is easy, replace linear_pgoff with
linear_page_index(vma, start).