• Home
  • Raw
  • Download

Lines Matching refs:ctrl_name

132 	const char *const ctrl_name;  member
269 #define CGROUP_CTRL_MEMBER(x, y)[y] = { .ctrl_name = #x, .files = \
311 for ((ctrl) = controllers; (ctrl)->ctrl_name; (ctrl)++)
430 ctrl->ctrl_name, in tst_cg_print_config()
441 static struct cgroup_ctrl *cgroup_find_ctrl(const char *const ctrl_name, in cgroup_find_ctrl() argument
446 char c = ctrl_name[l]; in cgroup_find_ctrl()
449 c = ctrl_name[++l]; in cgroup_find_ctrl()
458 tst_brk(TBROK, "Unexpected char in %s: %c", ctrl_name, c); in cgroup_find_ctrl()
462 if (!strncmp(ctrl_name, ctrl->ctrl_name, l)) in cgroup_find_ctrl()
483 char ctrl_name[CTRL_NAME_MAX + 1], mnt_path[PATH_MAX_STRLEN + 1], test_dir_name[NAME_MAX + 1]; in cgroup_parse_config_line() local
489 ctrl_name, &ver, &we_require_it, mnt_path, &we_mounted_it, in cgroup_parse_config_line()
495 ctrl = cgroup_find_ctrl(ctrl_name, 1); in cgroup_parse_config_line()
746 tmpdir, cgroup_mount_ltp_prefix, ctrl->ctrl_name); in cgroup_mount_v1()
767 if (mount(ctrl->ctrl_name, mnt_path, "cgroup", 0, ctrl->ctrl_name)) { in cgroup_mount_v1()
776 tst_res(TINFO, "Mounted V1 %s CGroup on %s", ctrl->ctrl_name, mnt_path); in cgroup_mount_v1()
833 void tst_cg_require(const char *const ctrl_name, in tst_cg_require() argument
837 struct cgroup_ctrl *const ctrl = cgroup_find_ctrl(ctrl_name, 1); in tst_cg_require()
839 int base = !strcmp(ctrl->ctrl_name, "base"); in tst_cg_require()
845 tst_brk(TBROK, "'%s' controller is unknown to LTP", ctrl_name); in tst_cg_require()
851 tst_res(TWARN, "Duplicate %s(%s, )", __func__, ctrl->ctrl_name); in tst_cg_require()
878 ctrl->ctrl_name); in tst_cg_require()
893 ctrl->ctrl_name); in tst_cg_require()
898 ctrl->ctrl_name); in tst_cg_require()
904 cgsc, "+%s", ctrl->ctrl_name); in tst_cg_require()
907 cgsc, "+%s", ctrl->ctrl_name); in tst_cg_require()
919 cgsc, "+%s", ctrl->ctrl_name); in tst_cg_require()
1052 || !strcmp(ctrl->ctrl_name, "base")) in tst_cg_cleanup()
1057 "-%s", ctrl->ctrl_name); in tst_cg_cleanup()
1105 if (strcmp(ctrl->ctrl_name, "base")) { in cgroup_group_add_dir()
1107 "+%s", ctrl->ctrl_name); in cgroup_group_add_dir()
1182 char ctrl_name[CTRL_NAME_MAX + 1]; in cgroup_file_find() local
1194 memcpy(ctrl_name, file_name, len); in cgroup_file_find()
1195 ctrl_name[len] = '\0'; in cgroup_file_find()
1197 ctrl = cgroup_find_ctrl(ctrl_name, 1); in cgroup_file_find()
1201 "Did not find controller '%s'\n", ctrl_name); in cgroup_file_find()
1213 file_name, ctrl->ctrl_name); in cgroup_file_find()
1222 const char *const ctrl_name) in tst_cg_ver() argument
1224 const struct cgroup_ctrl *const ctrl = cgroup_find_ctrl(ctrl_name, 1); in tst_cg_ver()
1227 if (!strcmp(ctrl_name, "cgroup")) { in tst_cg_ver()
1236 TBROK, "Unknown controller '%s'", ctrl_name); in tst_cg_ver()
1245 ctrl_name, cg->group_name); in tst_cg_ver()