linux-mm.kvack.org archive mirror
 help / color / mirror / Atom feed
From: "Sha, Ruibin" <ruibin.sha@intel.com>
To: "linux-kernel@vger.kernel.org" <linux-kernel@vger.kernel.org>
Cc: "linux-mm@kvack.org" <linux-mm@kvack.org>,
	"mel@csn.ul.ie" <mel@csn.ul.ie>,
	"a.p.zijlstra@chello.nl" <a.p.zijlstra@chello.nl>,
	"mgorman@suse.de" <mgorman@suse.de>,
	"mingo@redhat.com" <mingo@redhat.com>,
	"Zhang, Yanmin" <yanmin.zhang@intel.com>,
	"He, Bo" <bo.he@intel.com>
Subject: [PATCH]  export the function kmap_flush_unused.
Date: Fri, 8 Aug 2014 09:16:03 +0000	[thread overview]
Message-ID: <3C85A229999D6B4A89FA64D4680BA6142C7DFA@SHSMSX101.ccr.corp.intel.com> (raw)

[-- Attachment #1: Type: text/plain, Size: 1286 bytes --]

export the function kmap_flush_unused.

Scenario:  When graphic driver need high memory spece, we use alloc_pages()
         to allocate. But if the allocated page has just been
         mapped in the KMAP space(like first kmap then kunmap) and
         no flush page happened on PKMAP, the page virtual address is
         not NULL.Then when we get that page and set page attribute like
         set_memory_uc and set_memory_wc, we hit error.

fix:       For that scenario,when we get the allocated page and its virtual
           address is not NULL, we would like first flush that page.
         So need export that function kmap_flush_unused.

Signed-off-by: sha, ruibin <ruibin.sha@intel.com>

---
 mm/highmem.c |    1 +
 1 file changed, 1 insertion(+)

diff --git a/mm/highmem.c b/mm/highmem.c
index b32b70c..511299b 100644
--- a/mm/highmem.c
+++ b/mm/highmem.c
@@ -156,6 +156,7 @@ void kmap_flush_unused(void)
      flush_all_zero_pkmaps();
      unlock_kmap();
 }
+EXPORT_SYMBOL(kmap_flush_unused);

 static inline unsigned long map_new_virtual(struct page *page)
 {
--
1.7.9.5




Best Regards
---------------------------------------------------------------
Sha, Rui bin ( Robin )
+86 13817890945
Android System Integration Shanghai


[-- Attachment #2: Type: text/html, Size: 5094 bytes --]

             reply	other threads:[~2014-08-08  9:16 UTC|newest]

Thread overview: 6+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2014-08-08  9:16 Sha, Ruibin [this message]
2014-08-08 13:39 ` Chintan Pandya
2014-08-11  1:26   ` Sha, Ruibin
2014-08-11  3:32     ` Zhang, Yanmin
2014-08-11 11:54     ` Peter Zijlstra
2014-08-12  7:24       ` Zhang, Yanmin

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=3C85A229999D6B4A89FA64D4680BA6142C7DFA@SHSMSX101.ccr.corp.intel.com \
    --to=ruibin.sha@intel.com \
    --cc=a.p.zijlstra@chello.nl \
    --cc=bo.he@intel.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-mm@kvack.org \
    --cc=mel@csn.ul.ie \
    --cc=mgorman@suse.de \
    --cc=mingo@redhat.com \
    --cc=yanmin.zhang@intel.com \
    /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