Skip to content

Commit a97853f

Browse files
committed
Revert "selftests/cgroup: Drop define _GNU_SOURCE"
This reverts commit c1457d9. The framework change to add D_GNU_SOURCE to KHDR_INCLUDES to Makefile, lib.mk, and kselftest_harness.h is reverted as it is causing build failures and warnings. Revert this change as this change depends on the framework change. Reported-by: Mark Brown <broonie@kernel.org> Signed-off-by: Shuah Khan <skhan@linuxfoundation.org>
1 parent 3da1640 commit a97853f

File tree

7 files changed

+15
-0
lines changed

7 files changed

+15
-0
lines changed

tools/testing/selftests/cgroup/cgroup_util.c

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,7 @@
11
/* SPDX-License-Identifier: GPL-2.0 */
2+
3+
#define _GNU_SOURCE
4+
25
#include <errno.h>
36
#include <fcntl.h>
47
#include <linux/limits.h>

tools/testing/selftests/cgroup/test_core.c

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,6 @@
11
/* SPDX-License-Identifier: GPL-2.0 */
2+
3+
#define _GNU_SOURCE
24
#include <linux/limits.h>
35
#include <linux/sched.h>
46
#include <sys/types.h>

tools/testing/selftests/cgroup/test_cpu.c

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,6 @@
11
// SPDX-License-Identifier: GPL-2.0
2+
3+
#define _GNU_SOURCE
24
#include <linux/limits.h>
35
#include <sys/sysinfo.h>
46
#include <sys/wait.h>

tools/testing/selftests/cgroup/test_hugetlb_memcg.c

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,6 @@
11
// SPDX-License-Identifier: GPL-2.0
2+
#define _GNU_SOURCE
3+
24
#include <linux/limits.h>
35
#include <sys/mman.h>
46
#include <stdio.h>

tools/testing/selftests/cgroup/test_kmem.c

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,6 @@
11
// SPDX-License-Identifier: GPL-2.0
2+
#define _GNU_SOURCE
3+
24
#include <linux/limits.h>
35
#include <fcntl.h>
46
#include <stdio.h>

tools/testing/selftests/cgroup/test_memcontrol.c

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,6 @@
11
/* SPDX-License-Identifier: GPL-2.0 */
2+
#define _GNU_SOURCE
3+
24
#include <linux/limits.h>
35
#include <linux/oom.h>
46
#include <fcntl.h>

tools/testing/selftests/cgroup/test_zswap.c

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,6 @@
11
// SPDX-License-Identifier: GPL-2.0
2+
#define _GNU_SOURCE
3+
24
#include <linux/limits.h>
35
#include <unistd.h>
46
#include <stdio.h>

0 commit comments

Comments
 (0)