Home
last modified time | relevance | path

Searched refs:write_file (Results 1 – 25 of 32) sorted by relevance

12

/linux-6.15/tools/testing/selftests/damon/
H A D_damon_sysfs.py18 def write_file(path, string): function
59 err = write_file(
63 err = write_file(
75 err = write_file(
79 err = write_file(
227 err = write_file(
233 err = write_file(
252 err = write_file(
297 err = write_file(
303 err = write_file(
[all …]
/linux-6.15/tools/testing/selftests/ntb/
H A Dntb_test.sh109 function write_file() function
189 write_file "N" "$LOC/link_event"
196 write_file "Y" "$LOC/../link"
211 write_file "c $DB_VALID_MASK" "$REM/db"
224 write_file "s $MASK" "$LOC/peer_db"
231 write_file "c $DB_VALID_MASK" "$REM/db"
267 write_file "$VAL" "$LOC/spad$i"
301 write_file "$VAL" "$LOC/msg$i"
397 write_file 0 "$LOC/mw_trans$IDX"
450 write_file 1 $LOC/ready
[all …]
/linux-6.15/tools/testing/selftests/move_mount_set_group/
H A Dmove_mount_set_group_test.c59 static int write_file(const char *path, const void *buf, size_t count) in write_file() function
88 if (write_file("/proc/self/setgroups", "deny", sizeof("deny") - 1) && in create_and_enter_userns()
93 if (write_file("/proc/self/uid_map", map, strlen(map))) in create_and_enter_userns()
98 if (write_file("/proc/self/gid_map", map, strlen(map))) in create_and_enter_userns()
/linux-6.15/tools/testing/selftests/mount/
H A Dnosymfollow-test.c85 static void write_file(char *filename, char *fmt, ...) in write_file() function
103 write_file("/proc/self/uid_map", "0 %d 1", uid); in create_and_enter_ns()
104 write_file("/proc/self/gid_map", "0 %d 1", gid); in create_and_enter_ns()
H A Dunprivileged-remount-test.c105 static void write_file(char *filename, char *fmt, ...) in write_file() function
168 write_file("/proc/self/uid_map", "0 %d 1", uid); in create_and_enter_userns()
169 write_file("/proc/self/gid_map", "0 %d 1", gid); in create_and_enter_userns()
/linux-6.15/tools/testing/selftests/filesystems/statmount/
H A Dstatmount_test_ns.c102 static int write_file(const char *path, const char *val) in write_file() function
145 ret = write_file("/proc/self/uid_map", buf); in setup_namespace()
148 ret = write_file("/proc/self/setgroups", "deny"); in setup_namespace()
152 ret = write_file("/proc/self/gid_map", buf); in setup_namespace()
H A Dstatmount_test.c66 static void write_file(const char *path, const char *val) in write_file() function
140 write_file("/proc/self/uid_map", buf); in setup_namespace()
141 write_file("/proc/self/setgroups", "deny"); in setup_namespace()
143 write_file("/proc/self/gid_map", buf); in setup_namespace()
/linux-6.15/tools/testing/selftests/mm/
H A Dthp_settings.c67 int write_file(const char *path, const char *buf, size_t buflen) in write_file() function
107 if (!write_file(path, buf, strlen(buf) + 1)) { in write_num()
169 if (!write_file(path, val, strlen(val) + 1)) { in thp_write_string()
H A Dthp_settings.h66 int write_file(const char *path, const char *buf, size_t buflen);
H A Dsplit_huge_page_test.c58 static void write_file(const char *path, const char *buf, size_t buflen) in write_file() function
86 write_file(SPLIT_DEBUGFS, input, ret + 1); in write_debugfs()
/linux-6.15/tools/accounting/
H A Dprocacct.c273 int write_file = 0; in main() local
289 write_file = 1; in main()
318 if (write_file) { in main()
H A Dgetdelays.c310 int write_file = 0; in main() local
347 write_file = 1; in main()
409 if (write_file) { in main()
/linux-6.15/tools/testing/selftests/capabilities/
H A Dtest_execve.c72 static void write_file(char *filename, char *fmt, ...) in write_file() function
115 write_file("/proc/self/uid_map", "%d %d 1", inner_uid, outer_uid); in create_and_enter_ns()
116 write_file("/proc/self/gid_map", "0 %d 1", outer_gid); in create_and_enter_ns()
/linux-6.15/tools/testing/selftests/powerpc/
H A Dutils.c126 int write_file(const char *path, const char *buf, size_t count) in write_file() function
183 return write_file(path, buf, count); in write_debugfs_file()
348 err = write_file(path, buffer, len); in write_long()
380 err = write_file(path, buffer, len); in write_ulong()
/linux-6.15/fs/hostfs/
H A Dhostfs_user_exp.c11 EXPORT_SYMBOL_GPL(write_file);
H A Dhostfs.h84 extern int write_file(int fd, unsigned long long *offset, const char *buf,
/linux-6.15/tools/testing/selftests/safesetid/
H A Dsafesetid-test.c95 static bool write_file(char *filename, char *fmt, ...) in write_file() function
258 success = write_file(map_file_name, "0 %d 1", uid); in test_userns()
/linux-6.15/tools/testing/selftests/bpf/prog_tests/
H A Dtoken.c233 static int write_file(const char *path, const void *buf, size_t count) in write_file() function
262 if (write_file("/proc/self/setgroups", "deny", sizeof("deny") - 1) && in create_and_enter_userns()
267 if (write_file("/proc/self/uid_map", map, strlen(map))) in create_and_enter_userns()
272 if (write_file("/proc/self/gid_map", map, strlen(map))) in create_and_enter_userns()
H A Dtc_redirect.c73 static int write_file(const char *path, const char *newval) in write_file() function
476 err = write_file("/proc/sys/net/ipv4/ip_forward", enable ? "1" : "0"); in set_forwarding()
480 err = write_file("/proc/sys/net/ipv6/conf/all/forwarding", enable ? "1" : "0"); in set_forwarding()
/linux-6.15/tools/testing/selftests/powerpc/include/
H A Dutils.h54 int write_file(const char *path, const char *buf, size_t count);
/linux-6.15/scripts/
H A Drecordmcount.c329 static int write_file(const char *fname) in write_file() function
661 rc = write_file(fname); in do_file()
/linux-6.15/tools/tracing/latency/
H A Dlatency-collector.c1340 static void write_file(const char *file, const char *cur, const char *new, in write_file() function
1368 write_file(TR_MAXLAT, NULL, "0", ERR_CLEANUP); in reset_max_latency()
1404 write_file(TR_CURRENT, NULL, NOP_TRACER, ERR_EXIT); in save_and_disable_tracer()
1442 write_file(TR_THRESH, save_state.thresh, threshold, ERR_CLEANUP); in enable_tracer()
1443 write_file(TR_CURRENT, NOP_TRACER, current_tracer, ERR_CLEANUP); in enable_tracer()
/linux-6.15/tools/testing/selftests/mount_setattr/
H A Dmount_setattr_test.c192 static int write_file(const char *path, const void *buf, size_t count) in write_file() function
221 if (write_file("/proc/self/setgroups", "deny", sizeof("deny") - 1) && in create_and_enter_userns()
226 if (write_file("/proc/self/uid_map", map, strlen(map))) in create_and_enter_userns()
231 if (write_file("/proc/self/gid_map", map, strlen(map))) in create_and_enter_userns()
1184 if (write_file(procfile, map, strlen(map))) in map_ids()
1190 if (write_file(procfile, map, strlen(map))) in map_ids()
/linux-6.15/Documentation/admin-guide/LSM/
H A Dlandlock.rst127 …type=LANDLOCK_ACCESS msg=audit(1729738800.221:33): domain=1a6fdc679 blockers=fs.write_file path="/…
131 …type=LANDLOCK_ACCESS msg=audit(1729738800.221:34): domain=1a6fdc679 blockers=fs.write_file path="/…
/linux-6.15/tools/testing/selftests/powerpc/nx-gzip/
H A Dgzfht_test.c354 if (write_file(outname, outbuf, dsttotlen)) { in compress_file()

12