linux-mips
[Top] [All Lists]

Re: flush_anon_page for MIPS

To: "Ralf Baechle" <ralf@linux-mips.org>
Subject: Re: flush_anon_page for MIPS
From: "Franck Bui-Huu" <vagabon.xyz@gmail.com>
Date: Fri, 23 Mar 2007 16:01:04 +0100
Cc: "Miklos Szeredi" <miklos@szeredi.hu>, linux-mips@linux-mips.org, Ravi.Pratap@hillcrestlabs.com
Dkim-signature: a=rsa-sha1; c=relaxed/relaxed; d=gmail.com; s=beta; h=domainkey-signature:received:received:message-id:date:from:to:subject:cc:in-reply-to:mime-version:content-type:content-transfer-encoding:content-disposition:references; b=IYsDgLeOl7CARUzMrIMWPb459IiAIdI1keQNU9oEyZkYw7cseQqhEJDrQOuEpUDC2esMip8nea9PoUkelYf5DZ9tlQpD67mieAmY5zPmPFrw5cvD5q/TeDgsAtldedwp8WCJXrIhZdALIjA5mFtXsaB87t0qecLMO9BGbEkr2uk=
Domainkey-signature: a=rsa-sha1; c=nofws; d=gmail.com; s=beta; h=received:message-id:date:from:to:subject:cc:in-reply-to:mime-version:content-type:content-transfer-encoding:content-disposition:references; b=q7qjNgM6FAyG0kxOfyzTYwA6nWdNKyukgGiV9Y09i/xI+HV8Ob6oeG5D6aUeh00m/9ewUnxf7VbbLw2LwyeMZqwgcfK1GHsJJhFk0syZ76oEtInZNPkMb+tZZiwC1avGf5LIfNydnqystv6P7gbU6gDrlmB2qv/2LQeUhs0zihQ=
In-reply-to: <20070323141939.GB17311@linux-mips.org>
Original-recipient: rfc822;linux-mips@linux-mips.org
References: <E1HUVlw-00034H-00@dorka.pomaz.szeredi.hu> <20070323141939.GB17311@linux-mips.org>
Sender: linux-mips-bounce@linux-mips.org
On 3/23/07, Ralf Baechle <ralf@linux-mips.org> wrote:
+#define ARCH_HAS_FLUSH_ANON_PAGE
+static inline void flush_anon_page(struct vm_area_struct *vma,
+       struct page *page, unsigned long vmaddr)
+{
+       extern void __flush_anon_page(struct vm_area_struct *vma,
+                                     struct page *, unsigned long);
+       if (PageAnon(page))
+               __flush_anon_page(vma, page, vmaddr);
+}
+

Shouldn't you add a test against cpu_has_dc_aliases here and thus
avoid an useless call to __flush_anon_page() ?

--
              Franck

<Prev in Thread] Current Thread [Next in Thread>