mirror of
https://github.com/DragonOS-Community/DragonOS.git
synced 2025-06-18 08:06:32 +00:00
解决printk中的私有函数没有加static的问题
This commit is contained in:
@ -3,25 +3,25 @@
|
||||
#include <common/printk.h>
|
||||
#include <common/compiler.h>
|
||||
|
||||
#define assert(condition) ({ \
|
||||
int __condition = !!(condition); \
|
||||
if (unlikely(!(__condition))) \
|
||||
{ \
|
||||
#define assert(condition) ({ \
|
||||
int __condition = !!(condition); \
|
||||
if (unlikely(!(__condition))) \
|
||||
{ \
|
||||
printk("[ kTEST FAILED ] Ktest Assertion Failed, file:%s, Line:%d\n", __FILE__, __LINE__); \
|
||||
} \
|
||||
likely(__condition); \
|
||||
} \
|
||||
likely(__condition); \
|
||||
})
|
||||
|
||||
#define kTEST(...) \
|
||||
do \
|
||||
{ \
|
||||
#define kTEST(...) \
|
||||
do \
|
||||
{ \
|
||||
printk("[ kTEST ] file:%s, Line:%d\t", __FILE__, __LINE__); \
|
||||
printk(__VA_ARGS__); \
|
||||
printk("\n"); \
|
||||
printk(__VA_ARGS__); \
|
||||
printk("\n"); \
|
||||
} while (0);
|
||||
|
||||
/**
|
||||
* @brief 测试用例函数表
|
||||
*
|
||||
*
|
||||
*/
|
||||
typedef long (*ktest_case_table)(uint64_t arg0, uint64_t arg1);
|
Reference in New Issue
Block a user