arch/riscv: Add include/arch/barrier.h
mb() is used in src/arch/riscv/ and src/mainboard/emulation/*-riscv/. It is currently provided by atomic.h, but I think it fits better into barrier.h. The "fence" instruction represents a full memory fence, as opposed to variants such as "fence r, rw" which represent a partial fence. An operating system might want to use precisely the right fence, but coreboot doesn't need this level of performance at the cost of simplicity. Change-Id: I8d33ef32ad31e8fda38f6a5183210e7bd6c65815 Signed-off-by: Jonathan Neuschäfer <j.neuschaefer@gmx.net> Reviewed-on: https://review.coreboot.org/15830 Tested-by: build bot (Jenkins) Reviewed-by: Ronald G. Minnich <rminnich@gmail.com>
This commit is contained in:
committed by
Martin Roth
parent
aded214e74
commit
cc5be8b72b
@@ -14,11 +14,12 @@
|
||||
* GNU General Public License for more details.
|
||||
*/
|
||||
|
||||
#include <vm.h>
|
||||
#include <arch/barrier.h>
|
||||
#include <arch/encoding.h>
|
||||
#include <atomic.h>
|
||||
#include <stdint.h>
|
||||
#include <console/console.h>
|
||||
#include <stdint.h>
|
||||
#include <vm.h>
|
||||
|
||||
pte_t* root_page_table;
|
||||
|
||||
|
Reference in New Issue
Block a user