lkml.org 
[lkml]   [2014]   [Nov]   [10]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectInconsistent pgprot between dma_alloc_coherent() and dma_mmap_cohernet()
Hi,

I noticed using dma_mmap_coherent() on pages allocated via
dma_alloc_coherent() results in a warning on x86:

map pfn RAM range req uncached-minus for [mem 0x21d500000-0x21d51ffff], got write-back

which comes from arch/x86/mm/pat.c.

Looking at the code, it seems that dma_mmap_coherent() blindly assumes
that the pages are with pgprot_noncached(), but on x86, it's obviously
not. Maybe some other archs have the same problem.

How should we fix this? Defining a new pgprot_xxx(), and falling back
to pgprot_noncached if undefined? Or is it just x86 and do it only
there?


thanks,

Takashi


\
 
 \ /
  Last update: 2014-11-10 15:41    [W:0.023 / U:0.344 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site