/* * Copyright (C) 2011 Tobias Klauser <tklauser@distanz.ch> * Copyright (C) 2009 Wind River Systems Inc * Implemented by fredrik.markstrom@gmail.com and ivarholmqvist@gmail.com * * Based on DMA code from MIPS. * * This file is subject to the terms and conditions of the GNU General Public * License. See the file "COPYING" in the main directory of this archive * for more details.
*/
switch (dir) { case DMA_FROM_DEVICE:
invalidate_dcache_range((unsignedlong)vaddr,
(unsignedlong)(vaddr + size)); break; case DMA_TO_DEVICE: /* * We just need to flush the caches here , but Nios2 flush * instruction will do both writeback and invalidate.
*/ case DMA_BIDIRECTIONAL: /* flush and invalidate */
flush_dcache_range((unsignedlong)vaddr,
(unsignedlong)(vaddr + size)); break; default:
BUG();
}
}
Die Informationen auf dieser Webseite wurden
nach bestem Wissen sorgfältig zusammengestellt. Es wird jedoch weder Vollständigkeit, noch Richtigkeit,
noch Qualität der bereit gestellten Informationen zugesichert.
Bemerkung:
Die farbliche Syntaxdarstellung und die Messung sind noch experimentell.