Skip to content

GitLab

  • Menu
Projects Groups Snippets
  • Help
    • Help
    • Support
    • Community forum
    • Submit feedback
    • Contribute to GitLab
  • Sign in / Register
  • X xcap-capability-linux
  • Project information
    • Project information
    • Activity
    • Labels
    • Members
  • Repository
    • Repository
    • Files
    • Commits
    • Branches
    • Tags
    • Contributors
    • Graph
    • Compare
  • Issues 0
    • Issues 0
    • List
    • Boards
    • Service Desk
    • Milestones
  • Merge requests 0
    • Merge requests 0
  • Deployments
    • Deployments
    • Releases
  • Monitor
    • Monitor
    • Incidents
  • Analytics
    • Analytics
    • Value stream
    • Repository
  • Wiki
    • Wiki
  • Activity
  • Graph
  • Create a new issue
  • Commits
  • Issue Boards
Collapse sidebar
  • xcap
  • xcap-capability-linux
  • Repository
Switch branch/tag
  • xcap-capability-linux
  • arch
  • x86
  • mm
  • pat.c
Find file BlameHistoryPermalink
  • Dave Hansen's avatar
    x86: Do not try to sync identity map for non-mapped pages · 60f583d5
    Dave Hansen authored Mar 07, 2013
    kernel_map_sync_memtype() is called from a variety of contexts.  The
    pat.c code that calls it seems to ensure that it is not called for
    non-ram areas by checking via pat_pagerange_is_ram().  It is important
    that it only be called on the actual identity map because there *IS*
    no map to sync for highmem pages, or for memory holes.
    
    The ioremap.c uses are not as careful as those from pat.c, and call
    kernel_map_sync_memtype() on PCI space which is in the middle of the
    kernel identity map _range_, but is not actually mapped.
    
    This patch adds a check to kernel_map_sync_memtype() which probably
    duplicates some of the checks already in pat.c.  But, it is necessary
    for the ioremap.c uses and shouldn't hurt other callers.
    
    I have reproduced this bug and this patch fixes it for me and the
    original bug reporter:
    
    	https://lkml.org/lkml/2013/2/5/396
    
    Signed-off-by: default avatarDave Hansen <dave@linux.vnet.ibm.com>
    Link: http://lkml.kernel.org/r/20130307163151.D9B58C4E@kernel.stglabs.ibm.com
    
    Signed-off-by: default avatarDave Hansen <dave@sr71.net>
    Tested-by: default avatarTetsuo Handa <penguin-kernel@i-love.sakura.ne.jp>
    Signed-off-by: default avatarH. Peter Anvin <hpa@zytor.com>
    60f583d5

Replace pat.c

Attach a file by drag & drop or click to upload


Cancel
GitLab will create a branch in your fork and start a merge request.