hc
2024-02-20 102a0743326a03cd1a1202ceda21e175b7d3575c
kernel/samples/Kconfig
....@@ -1,10 +1,14 @@
1
+# SPDX-License-Identifier: GPL-2.0-only
12 menuconfig SAMPLES
23 bool "Sample kernel code"
3
- depends on !UML
44 help
55 You can build and test sample kernel code here.
66
77 if SAMPLES
8
+
9
+config SAMPLE_AUXDISPLAY
10
+ bool "auxdisplay sample"
11
+ depends on CC_CAN_LINK
812
913 config SAMPLE_TRACE_EVENTS
1014 tristate "Build trace_events examples -- loadable modules only"
....@@ -19,9 +23,23 @@
1923 This builds a module that calls trace_printk() and can be used to
2024 test various trace_printk() calls from a module.
2125
26
+config SAMPLE_FTRACE_DIRECT
27
+ tristate "Build register_ftrace_direct() example"
28
+ depends on DYNAMIC_FTRACE_WITH_DIRECT_CALLS && m
29
+ depends on X86_64 # has x86_64 inlined asm
30
+ help
31
+ This builds an ftrace direct function example
32
+ that hooks to wake_up_process and prints the parameters.
33
+
34
+config SAMPLE_TRACE_ARRAY
35
+ tristate "Build sample module for kernel access to Ftrace instancess"
36
+ depends on EVENT_TRACING && m
37
+ help
38
+ This builds a module that demonstrates the use of various APIs to
39
+ access Ftrace instances from within the kernel.
40
+
2241 config SAMPLE_KOBJECT
23
- tristate "Build kobject examples -- loadable modules only"
24
- depends on m
42
+ tristate "Build kobject examples"
2543 help
2644 This config option will allow you to build a number of
2745 different kobject sample modules showing how to use kobjects,
....@@ -95,19 +113,37 @@
95113
96114 config SAMPLE_CONNECTOR
97115 tristate "Build connector sample -- loadable modules only"
98
- depends on CONNECTOR && m
116
+ depends on CONNECTOR && HEADERS_INSTALL && m
99117 help
100118 When enabled, this builds both a sample kernel module for
101119 the connector interface and a user space tool to communicate
102120 with it.
103
- See also Documentation/connector/connector.txt
121
+ See also Documentation/driver-api/connector.rst
122
+
123
+config SAMPLE_HIDRAW
124
+ bool "hidraw sample"
125
+ depends on CC_CAN_LINK && HEADERS_INSTALL
126
+
127
+config SAMPLE_PIDFD
128
+ bool "pidfd sample"
129
+ depends on CC_CAN_LINK && HEADERS_INSTALL
104130
105131 config SAMPLE_SECCOMP
106
- tristate "Build seccomp sample code -- loadable modules only"
107
- depends on SECCOMP_FILTER && m
132
+ bool "Build seccomp sample code"
133
+ depends on SECCOMP_FILTER && CC_CAN_LINK && HEADERS_INSTALL
108134 help
109135 Build samples of seccomp filters using various methods of
110136 BPF filter construction.
137
+
138
+config SAMPLE_TIMER
139
+ bool "Timer sample"
140
+ depends on CC_CAN_LINK && HEADERS_INSTALL
141
+
142
+config SAMPLE_UHID
143
+ bool "UHID sample"
144
+ depends on CC_CAN_LINK && HEADERS_INSTALL
145
+ help
146
+ Build UHID sample program.
111147
112148 config SAMPLE_VFIO_MDEV_MTTY
113149 tristate "Build VFIO mtty example mediated device sample code -- loadable modules only"
....@@ -147,10 +183,37 @@
147183 Specifically it does *not* include any legacy vga stuff.
148184 Device looks a lot like "qemu -device secondary-vga".
149185
150
-config SAMPLE_STATX
151
- bool "Build example extended-stat using code"
152
- depends on BROKEN
186
+config SAMPLE_ANDROID_BINDERFS
187
+ bool "Build Android binderfs example"
188
+ depends on CC_CAN_LINK && HEADERS_INSTALL
153189 help
154
- Build example userspace program to use the new extended-stat syscall.
190
+ Builds a sample program to illustrate the use of the Android binderfs
191
+ filesystem.
192
+
193
+config SAMPLE_VFS
194
+ bool "Build example programs that use new VFS system calls"
195
+ depends on CC_CAN_LINK && HEADERS_INSTALL
196
+ help
197
+ Build example userspace programs that use new VFS system calls such
198
+ as mount API and statx(). Note that this is restricted to the x86
199
+ arch whilst it accesses system calls that aren't yet in all arches.
200
+
201
+config SAMPLE_INTEL_MEI
202
+ bool "Build example program working with intel mei driver"
203
+ depends on INTEL_MEI
204
+ depends on CC_CAN_LINK && HEADERS_INSTALL
205
+ help
206
+ Build a sample program to work with mei device.
207
+
208
+config SAMPLE_WATCHDOG
209
+ bool "watchdog sample"
210
+ depends on CC_CAN_LINK
211
+
212
+config SAMPLE_WATCH_QUEUE
213
+ bool "Build example watch_queue notification API consumer"
214
+ depends on CC_CAN_LINK && HEADERS_INSTALL
215
+ help
216
+ Build example userspace program to use the new mount_notify(),
217
+ sb_notify() syscalls and the KEYCTL_WATCH_KEY keyctl() function.
155218
156219 endif # SAMPLES