kernel: refact (#113)
* refact
* sort inlude
* update
* unregister execve kprobe
* update log
* don't unregister if not in kprobe
* opt for no kprobe
* opt for no kprobe
* stop debug
* don't forget to call ksu_uid_observer_exit
* rename core to core_hook
* direct call do_persistent_allow_list
* add prefix
* use getter, add warn
* add wrapper
* run clang-format
clang-format --style="{BasedOnStyle: InheritParentConfig, SortIncludes: true}" -i kernel/**/*.[ch]
* try fix wsa x64 build
This commit is contained in:
@@ -1,20 +1,20 @@
|
||||
#include <linux/kallsyms.h>
|
||||
#include <linux/kprobes.h>
|
||||
#include "linux/kallsyms.h"
|
||||
|
||||
#define RE_EXPORT_SYMBOL1(ret, func, t1, v1) \
|
||||
ret ksu_##func(t1 v1) { \
|
||||
return func(v1); \
|
||||
} \
|
||||
EXPORT_SYMBOL(ksu_##func); \
|
||||
#define RE_EXPORT_SYMBOL1(ret, func, t1, v1) \
|
||||
ret ksu_##func(t1 v1) \
|
||||
{ \
|
||||
return func(v1); \
|
||||
} \
|
||||
EXPORT_SYMBOL(ksu_##func);
|
||||
|
||||
#define RE_EXPORT_SYMBOL2(ret, func, t1, v1, t2, v2) \
|
||||
ret ksu_##func(t1 v1, t2 v2) { \
|
||||
return func(v1, v2); \
|
||||
} \
|
||||
EXPORT_SYMBOL(ksu_##func); \
|
||||
#define RE_EXPORT_SYMBOL2(ret, func, t1, v1, t2, v2) \
|
||||
ret ksu_##func(t1 v1, t2 v2) \
|
||||
{ \
|
||||
return func(v1, v2); \
|
||||
} \
|
||||
EXPORT_SYMBOL(ksu_##func);
|
||||
|
||||
|
||||
RE_EXPORT_SYMBOL1(unsigned long, kallsyms_lookup_name, const char*, name)
|
||||
RE_EXPORT_SYMBOL1(unsigned long, kallsyms_lookup_name, const char *, name)
|
||||
|
||||
// RE_EXPORT_SYMBOL2(int, register_kprobe, struct kprobe *, p)
|
||||
// RE_EXPORT_SYMBOL2(void, unregister_kprobe, struct kprobe *, p)
|
||||
|
||||
Reference in New Issue
Block a user