用于EagleEye3.0 规则集漏报和误报测试的示例项目,项目收集于github和gitee
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
 
 
 
 
 
 

43 lines
999 B

/*
* Copyright (c) 2006-2024, RT-Thread Development Team
*
* SPDX-License-Identifier: Apache-2.0
*
* Change Logs:
* Date Author Notes
* 2024/01/11 flyingcys The first version
*/
#ifndef RISCV_VIRT_H_
#define RISCV_VIRT_H_
#include "riscv-reg.h"
#ifdef __ASSEMBLER__
#define CONS(NUM, TYPE)NUM
#else
#define CONS(NUM, TYPE)NUM##TYPE
#endif /* __ASSEMBLER__ */
#define PRIM_HART 0
#ifdef RISCV_QEMU
#define CLINT_ADDR CONS(0x02000000, UL)
#define CLINT_MSIP CONS(0x0000, UL)
#define CLINT_MTIMECMP CONS(0x4000, UL)
#define CLINT_MTIME CONS(0xbff8, UL)
#else
#define CLINT_ADDR CONS(0x74000000, UL)
#define CLINT_MSIP CONS(0x0000, UL)
#define CLINT_MTIMECMP CONS(0x4000, UL)
#undef CLINT_MTIME
//#define CLINT_MTIME CONS(0x4004, UL)
#endif
//#define NS16550_ADDR CONS(0x10000000, UL)
#ifndef __ASSEMBLER__
int xGetCoreID( void );
#endif /* __ASSEMBLER__ */
#endif /* RISCV_VIRT_H_ */