linux-kernelorg-stable/tools/testing/selftests/cgroup
Xiu Jianfeng 11312c86f9 selftests/cgroup: Fix compile error in test_cpu.c
When compiling the cgroup selftests with the following command:

make -C tools/testing/selftests/cgroup/

the compiler complains as below:

test_cpu.c: In function ‘test_cpucg_nice’:
test_cpu.c:284:39: error: incompatible type for argument 2 of ‘hog_cpus_timed’
  284 |                 hog_cpus_timed(cpucg, param);
      |                                       ^~~~~
      |                                       |
      |                                       struct cpu_hog_func_param
test_cpu.c:132:53: note: expected ‘void *’ but argument is of type ‘struct cpu_hog_func_param’
  132 | static int hog_cpus_timed(const char *cgroup, void *arg)
      |                                               ~~~~~~^~~

Fix it by passing the address of param to hog_cpus_timed().

Fixes: 2e82c0d456 ("cgroup/rstat: Selftests for niced CPU statistics")
Signed-off-by: Xiu Jianfeng <xiujianfeng@huawei.com>
Signed-off-by: Tejun Heo <tj@kernel.org>
2024-10-14 15:05:39 -10:00
..
.gitignore selftests: cgroup: Add basic tests for pids controller 2024-05-26 08:45:10 -10:00
Makefile selftests: cgroup: Add basic tests for pids controller 2024-05-26 08:45:10 -10:00
cgroup_util.c mm, memcg: cg2 memory{.swap,}.peak write tests 2024-09-01 20:25:53 -07:00
cgroup_util.h mm, memcg: cg2 memory{.swap,}.peak write tests 2024-09-01 20:25:53 -07:00
config mm: remove CONFIG_MEMCG_KMEM 2024-07-10 12:14:54 -07:00
memcg_protection.m
test_core.c Revert "selftests/cgroup: Drop define _GNU_SOURCE" 2024-05-20 09:00:15 -06:00
test_cpu.c selftests/cgroup: Fix compile error in test_cpu.c 2024-10-14 15:05:39 -10:00
test_cpuset.c selftests: cgroup: skip test_cgcore_lesser_ns_open when cgroup2 mounted without nsdelegate 2024-04-03 09:42:13 -10:00
test_cpuset_prs.sh selftest/cgroup: Make test_cpuset_prs.sh deal with pre-isolated CPUs 2024-08-30 09:23:39 -10:00
test_cpuset_v1_base.sh cgroup/cpuset: add sefltest for cpuset v1 2024-08-30 10:00:17 -10:00
test_cpuset_v1_hp.sh cgroup/cpuset: Add test_cpuset_v1_hp.sh 2024-04-08 07:39:38 -10:00
test_freezer.c selftests: cgroup: skip test_cgcore_lesser_ns_open when cgroup2 mounted without nsdelegate 2024-04-03 09:42:13 -10:00
test_hugetlb_memcg.c Revert "selftests/cgroup: Drop define _GNU_SOURCE" 2024-05-20 09:00:15 -06:00
test_kill.c selftests: cgroup: skip test_cgcore_lesser_ns_open when cgroup2 mounted without nsdelegate 2024-04-03 09:42:13 -10:00
test_kmem.c Revert "selftests/cgroup: Drop define _GNU_SOURCE" 2024-05-20 09:00:15 -06:00
test_memcontrol.c mm, memcg: cg2 memory{.swap,}.peak write tests 2024-09-01 20:25:53 -07:00
test_pids.c selftests: cgroup: Add basic tests for pids controller 2024-05-26 08:45:10 -10:00
test_stress.sh
test_zswap.c selftests: test_zswap: add test for hierarchical zswap.writeback 2024-09-03 21:15:47 -07:00
wait_inotify.c
with_stress.sh