Re: user_to_phys() without mmap?



Assuming you are using /dev/mem, could it be possible that you are
accessing cached memory?

It turns out that the memory was indeed being cached. I was already using ioremap_nocache(), so I didn't realize that I had to specify anything additional when using remap_page_range().

In any case, once I added the following, my speeds and latencies from user and kernel spaces evened out:

pgprot_val(vma->vm_page_prot) |= _PAGE_NO_CACHE|_PAGE_GUARDED;

Thanks for the comments Rainer, and each of the rest of you as well. It's nice to have this problem squared away.
.