kernel: Rewrite kernle version code management

Co-authored-by: lamadaemon <i@lama.icu>
Signed-off-by: ShirkNeko <109797057+ShirkNeko@users.noreply.github.com>
This commit is contained in:
ShirkNeko
2025-06-24 20:07:56 +08:00
parent 0f3a9de958
commit f876a523f6
3 changed files with 51 additions and 17 deletions

View File

@@ -4,7 +4,7 @@
#include <linux/types.h>
#include <linux/workqueue.h>
#define KERNEL_SU_VERSION KSU_VERSION
#define KERNEL_SU_VERSION KSU_API_VERSION
#define KERNEL_SU_OPTION 0xDEADBEEF
#define CMD_GRANT_ROOT 0
@@ -23,6 +23,9 @@
#define CMD_UID_SHOULD_UMOUNT 13
#define CMD_IS_SU_ENABLED 14
#define CMD_ENABLE_SU 15
#define CMD_GET_FULL_VERSION 30
#define CMD_ENABLE_KPM 100
#define CMD_HOOK_TYPE 101
#define CMD_GET_SUSFS_FEATURE_STATUS 102
@@ -37,6 +40,12 @@
#define KSU_MAX_GROUPS 32
#define KSU_SELINUX_DOMAIN 64
#define KSU_MAX_VERSION_NAME 255
#ifndef KSU_VERSION
#define KSU_VERSION "v0-unknown-00000000@unkown"
#endif
// SUSFS Functional State Structures
struct susfs_feature_status {
bool status_sus_path;