On Mon, May 3, 2010 at 4:40 PM, Dezhong Diao (dediao) <dediao@xxxxxxxxx> wrote: > + addr = (unsigned long)kmap_high_get(page); > + if (addr) { > + addr += offset; > + __dma_sync_virtual(addr, size, direction); > + kunmap_high(page); > + } When addr == 0, no flush is performed and that results in serious coherency problems on my system. The latest ARM code has a special "VIPT" handler for this case; I suspect that MIPS needs something similar: http://lists.infradead.org/pipermail/linux-arm-kernel/2010-March/012169.html My cache is VIPT with no aliases.