aboutsummaryrefslogtreecommitdiffstats
path: root/sys/linux/dev_rfkill.txt
diff options
context:
space:
mode:
authorAlexander Popov <alex.popov@linux.com>2019-03-17 17:15:58 +0300
committerDmitry Vyukov <dvyukov@google.com>2019-03-18 08:51:27 +0100
commit0d081107beadbdcb65578a5f52d1bac0103cc963 (patch)
treedd7df7ed56be77cef0ad56e014972cd1dbdf0373 /sys/linux/dev_rfkill.txt
parent2ef67421494606a406dc91cc24e4b733de1f3abf (diff)
sys/linux: Add rfkill description for Linux
Diffstat (limited to 'sys/linux/dev_rfkill.txt')
-rw-r--r--sys/linux/dev_rfkill.txt21
1 files changed, 21 insertions, 0 deletions
diff --git a/sys/linux/dev_rfkill.txt b/sys/linux/dev_rfkill.txt
new file mode 100644
index 000000000..dab3df781
--- /dev/null
+++ b/sys/linux/dev_rfkill.txt
@@ -0,0 +1,21 @@
+# Copyright 2019 syzkaller project authors. All rights reserved.
+# Use of this source code is governed by Apache 2 LICENSE that can be found in the LICENSE file.
+
+include <uapi/linux/ioctl.h>
+include <uapi/linux/rfkill.h>
+
+resource fd_rfkill[fd]
+
+openat$rfkill(fd const[AT_FDCWD], file ptr[in, string["/dev/rfkill"]], flags flags[open_flags], mode const[0]) fd_rfkill
+
+write$rfkill(fd fd_rfkill, data ptr[in, rfkill_event], len bytesize[data])
+read$rfkill(fd fd_rfkill, data ptr[out, rfkill_event], len bytesize[data])
+ioctl$RFKILL_IOCTL_NOINPUT(fd fd_rfkill, cmd const[RFKILL_IOCTL_NOINPUT])
+
+rfkill_event {
+ idx int32
+ type int8[0:NUM_RFKILL_TYPES]
+ op int8[0:RFKILL_OP_CHANGE_ALL]
+ soft int8[0:1]
+ hard int8[0:1]
+} [packed]