Creating new Description for Kernelmodule

6 views
Skip to first unread message

Sangwoo Bae

unread,
Oct 20, 2021, 1:20:52 AM10/20/21
to syzkaller
Hi everyone,

I have been working on using Syzkaller to fuzz a linux module called DAMON <https://damonitor.github.io/doc/html/latest-damon/admin-guide/mm/damon/usage.html>.
The DAMON module has a debugfs interface to start and configure it.
But I am unfortunately not that experienced, and my description doesn't seem to cover the DAMON source code according to the coverage report.
I would really appreciate if you could give me a pointer for what I'm doing wrong..

I have pasted a smaller version of the DAMON description below:

include <uapi/linux/fcntl.h>
include <uapi/linux/mount.h>

resource fd_target_ids[fd]
resource fd_monitor_on[fd]
resource d_pid[pid]

mount$damon_debugfs(src const[0], dst ptr[in, string["/sys/kernel/debug"]], type ptr[in, string["debugfs"]], flags flags[mount_flags], data const[0])

getpid$damon() d_pid

open$target_ids(file ptr[in, string["/sys/kernel/debug/damon/target_ids"]], flags flags[open_flags], mode flags[open_mode]) fd_target_ids
open$monitor_on(file ptr[in, string["/sys/kernel/debug/damon/monitor_on"]], flags flags[open_flags], mode flags[open_mode]) fd_monitor_on

write$target_ids(fd fd_target_ids, buf ptr[in, target_id_input], count len[buf])
write$monitor_on(fd fd_monitor_on, buf ptr[in, string["on"]], count len[buf])

target_id_input {
    paddr       optional[string["paddr\n"]]
    pids        array[target_pid]
} [packed]

target_pid {
    space       string[" "]
    pid         d_pid
}


Kind regards, and thank you all in advance!
Sangwoo Bae

Reply all
Reply to author
Forward
0 new messages