kernel: fix -Wstrict-prototypes warnings/errors

* On newer kernel for some reason -Wno-strict-prototypes still does not fix the errors or warnings.
* To fix it, we just need to add void type.

Signed-off-by: rsuntk <rsuntk@yukiprjkt.my.id>
This commit is contained in:
rsuntk
2025-08-28 15:46:22 +07:00
committed by ShirkNeko
parent a670b82bb6
commit 1294bbe853
13 changed files with 41 additions and 41 deletions

View File

@@ -52,9 +52,9 @@ static const char KERNEL_SU_RC[] =
"\n";
static void stop_vfs_read_hook();
static void stop_execve_hook();
static void stop_input_hook();
static void stop_vfs_read_hook(void);
static void stop_execve_hook(void);
static void stop_input_hook(void);
#ifdef CONFIG_KSU_KPROBES_HOOK
static struct work_struct stop_vfs_read_work;
@@ -620,7 +620,7 @@ int __maybe_unused ksu_handle_compat_execve_ksud(
#endif
static void stop_vfs_read_hook()
static void stop_vfs_read_hook(void)
{
#ifdef CONFIG_KSU_KPROBES_HOOK
bool ret = schedule_work(&stop_vfs_read_work);
@@ -631,7 +631,7 @@ static void stop_vfs_read_hook()
#endif
}
static void stop_execve_hook()
static void stop_execve_hook(void)
{
#ifdef CONFIG_KSU_KPROBES_HOOK
bool ret = schedule_work(&stop_execve_hook_work);
@@ -642,7 +642,7 @@ static void stop_execve_hook()
#endif
}
static void stop_input_hook()
static void stop_input_hook(void)
{
#ifdef CONFIG_KSU_KPROBES_HOOK
static bool input_hook_stopped = false;
@@ -662,7 +662,7 @@ static void stop_input_hook()
}
// ksud: module support
void ksu_ksud_init()
void ksu_ksud_init(void)
{
#ifdef CONFIG_KSU_KPROBES_HOOK
int ret;
@@ -682,7 +682,7 @@ void ksu_ksud_init()
#endif
}
void ksu_ksud_exit()
void ksu_ksud_exit(void)
{
#ifdef CONFIG_KSU_KPROBES_HOOK
unregister_kprobe(&execve_kp);