mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: Johannes Weiner <hannes@saeurebad.de>
To: Andrew Morton <akpm@linux-foundation.org>
Cc: linux-kernel@vger.kernel.org
Subject: [PATCH -mmotm] Remove ->nopfn check from use_zero_page
Date: Fri, 27 Jun 2008 13:06:11 +0200	[thread overview]
Message-ID: <878wwryw64.fsf@skyscraper.fehenstaub.lan> (raw)

Hi Andrew,

The get_user_pages fix from Linus came to -mm through -next as it seems,
but -mm has Nick's nopfn removal patches already and so use_zero_page
checks for a non-existant vm_op.

This patch is needed to at least compile.

Signed-off-by: Johannes Weiner <hannes@saeurebad.de>
---

diff --git a/mm/memory.c b/mm/memory.c
index 08cd653..5d7e705 100644
--- a/mm/memory.c
+++ b/mm/memory.c
@@ -1082,11 +1082,10 @@ static inline int use_zero_page(struct vm_area_struct *vma)
 	if (vma->vm_flags & (VM_LOCKED | VM_SHARED))
 		return 0;
 	/*
-	 * And if we have a fault or a nopfn routine, it's not an
-	 * anonymous region.
+	 * And if we have a fault routine, it's not an anonymous
+	 * region.
 	 */
-	return !vma->vm_ops ||
-		(!vma->vm_ops->fault && !vma->vm_ops->nopfn);
+	return !vma->vm_ops || !vma->vm_ops->fault;
 }
 
 int get_user_pages(struct task_struct *tsk, struct mm_struct *mm,

             reply	other threads:[~2008-06-27 11:06 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2008-06-27 11:06 Johannes Weiner [this message]
2008-06-27 11:55 ` Hugh Dickins

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=878wwryw64.fsf@skyscraper.fehenstaub.lan \
    --to=hannes@saeurebad.de \
    --cc=akpm@linux-foundation.org \
    --cc=linux-kernel@vger.kernel.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox

all inboxes | Powered by JetHome®