File tree Expand file tree Collapse file tree 6 files changed +23
-13
lines changed
testcases/kernel/controllers/memcg Expand file tree Collapse file tree 6 files changed +23
-13
lines changed Original file line number Diff line number Diff line change 11// SPDX-License-Identifier: GPL-2.0-only
2+ /*
3+ * Copyright (c) 2021-2022 Richard Palethorpe <rpalethorpe@suse.com>
4+ */
5+
26/*\
7+ * Conversion of the first kself test in :kselftest:`cgroup/test_memcontrol.c`.
38 *
4- * Conversion of the first kself test in cgroup/test_memcontrol.c.
59 * This test creates two nested cgroups with and without enabling the
610 * memory controller.
711 *
812 * The LTP API automatically adds controllers to subtree_control when
913 * a child cgroup is added. So unlike the kselftest we remove the
1014 * controller after it being added automatically.
1115 */
12- #define _GNU_SOURCE
1316
17+ #define _GNU_SOURCE
1418#include <stdio.h>
15-
1619#include "tst_test.h"
1720
1821static struct tst_cg_group * parent , * child ;
Original file line number Diff line number Diff line change 11// SPDX-License-Identifier: GPL-2.0-only
2+ /*
3+ * Copyright (c) 2021-2022 Richard Palethorpe <rpalethorpe@suse.com>
4+ */
5+
26/*\
3- *
4- * Conversion of second kself test in cgroup/test_memcontrol.c.
7+ * Conversion of second kself test in :kselftest:`cgroup/test_memcontrol.c`.
58 *
69 * Original description:
710 *
2023 * - On EXFAT and extN we change the margin of error between all and file
2124 * memory to 50%. Because these allocate non-page-cache memory during writes.
2225 */
23- #define _GNU_SOURCE
2426
27+ #define _GNU_SOURCE
2528#include "memcontrol_common.h"
2629
2730static size_t page_size ;
Original file line number Diff line number Diff line change 11// SPDX-License-Identifier: GPL-2.0-only
22/*\
33 *
4- * Conversion of the third kself test in cgroup/test_memcontrol.c.
4+ * Conversion of the third kself test in :kselftest:` cgroup/test_memcontrol.c` .
55 *
66 * Original description:
77 * "First, this test creates the following hierarchy:
Original file line number Diff line number Diff line change 11// SPDX-License-Identifier: GPL-2.0-only
22/*\
33 *
4- * Conversion of the forth kself test in cgroup/test_memcontrol.c.
4+ * Conversion of the forth kself test in :kselftest:` cgroup/test_memcontrol.c` .
55 *
66 * Original description:
77 * "First, this test creates the following hierarchy:
Original file line number Diff line number Diff line change 11// SPDX-License-Identifier: GPL-2.0-only
2+ /*
3+ * Copyright (c) 2021-2022 Richard Palethorpe <rpalethorpe@suse.com>
4+ */
25
36#ifndef MEMCONTROL_COMMON_H__
47#define MEMCONTROL_COMMON_H__
Original file line number Diff line number Diff line change 11// SPDX-License-Identifier: GPL-2.0-or-later
22/*
33 * Copyright (c) 2017 FUJITSU LIMITED. All rights reserved.
4+ * Copyright (c) Linux Test Project, 2017-2026
45 * Author: Guangwen Feng <fenggw-fnst@cn.fujitsu.com>
56 */
67
7- /*
8- * This is a regression test for a crash caused by memcg function
9- * reentrant on buggy kernel. When doing rmdir(), a pending signal can
10- * interrupt the execution and lead to cgroup_clear_css_refs()
11- * being entered repeatedly, this results in a BUG_ON().
8+ /*\
9+ * Regression test for a crash caused by memcg function reentrant on buggy
10+ * kernel. When doing rmdir(), a pending signal can interrupt the execution and
11+ * lead to cgroup_clear_css_refs() being entered repeatedly, this results in a
12+ * BUG_ON().
1213 */
1314
1415#include <errno.h>
You can’t perform that action at this time.
0 commit comments