[update] os
This commit is contained in:
@@ -1,8 +1,16 @@
|
||||
|
||||
|
||||
#include "asm.h"
|
||||
#include "defs.h"
|
||||
#include "latype.h"
|
||||
#include "macro.h"
|
||||
|
||||
#ifndef __loongarch32r
|
||||
#define __loongarch32r
|
||||
#endif
|
||||
|
||||
#include "larchintrin.h"
|
||||
|
||||
#ifndef LA32R_H__
|
||||
#define LA32R_H__
|
||||
|
||||
@@ -56,18 +64,10 @@ static inline uint r_ra() {
|
||||
// mem misc
|
||||
//
|
||||
|
||||
static inline void dbar() {
|
||||
asm volatile("dbar 0");
|
||||
}
|
||||
|
||||
static inline void ibar() {
|
||||
asm volatile("ibar 0");
|
||||
}
|
||||
|
||||
// need to be tested
|
||||
static inline void synchronize() {
|
||||
dbar();
|
||||
ibar();
|
||||
__dbar(0);
|
||||
__ibar(0);
|
||||
}
|
||||
|
||||
|
||||
@@ -101,4 +101,6 @@ static inline uint scw(uint wdata, intptr_t addr) {
|
||||
return recv;
|
||||
}
|
||||
|
||||
|
||||
|
||||
#endif
|
||||
Reference in New Issue
Block a user