Skip to content

Commit

Permalink
Revert "selftests/cgroup: Drop define _GNU_SOURCE"
Browse files Browse the repository at this point in the history
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 <[email protected]>
Signed-off-by: Shuah Khan <[email protected]>
  • Loading branch information
shuahkh committed May 20, 2024
1 parent 3da1640 commit a97853f
Show file tree
Hide file tree
Showing 7 changed files with 15 additions and 0 deletions.
3 changes: 3 additions & 0 deletions tools/testing/selftests/cgroup/cgroup_util.c
Original file line number Diff line number Diff line change
@@ -1,4 +1,7 @@
/* SPDX-License-Identifier: GPL-2.0 */

#define _GNU_SOURCE

#include <errno.h>
#include <fcntl.h>
#include <linux/limits.h>
Expand Down
2 changes: 2 additions & 0 deletions tools/testing/selftests/cgroup/test_core.c
Original file line number Diff line number Diff line change
@@ -1,4 +1,6 @@
/* SPDX-License-Identifier: GPL-2.0 */

#define _GNU_SOURCE
#include <linux/limits.h>
#include <linux/sched.h>
#include <sys/types.h>
Expand Down
2 changes: 2 additions & 0 deletions tools/testing/selftests/cgroup/test_cpu.c
Original file line number Diff line number Diff line change
@@ -1,4 +1,6 @@
// SPDX-License-Identifier: GPL-2.0

#define _GNU_SOURCE
#include <linux/limits.h>
#include <sys/sysinfo.h>
#include <sys/wait.h>
Expand Down
2 changes: 2 additions & 0 deletions tools/testing/selftests/cgroup/test_hugetlb_memcg.c
Original file line number Diff line number Diff line change
@@ -1,4 +1,6 @@
// SPDX-License-Identifier: GPL-2.0
#define _GNU_SOURCE

#include <linux/limits.h>
#include <sys/mman.h>
#include <stdio.h>
Expand Down
2 changes: 2 additions & 0 deletions tools/testing/selftests/cgroup/test_kmem.c
Original file line number Diff line number Diff line change
@@ -1,4 +1,6 @@
// SPDX-License-Identifier: GPL-2.0
#define _GNU_SOURCE

#include <linux/limits.h>
#include <fcntl.h>
#include <stdio.h>
Expand Down
2 changes: 2 additions & 0 deletions tools/testing/selftests/cgroup/test_memcontrol.c
Original file line number Diff line number Diff line change
@@ -1,4 +1,6 @@
/* SPDX-License-Identifier: GPL-2.0 */
#define _GNU_SOURCE

#include <linux/limits.h>
#include <linux/oom.h>
#include <fcntl.h>
Expand Down
2 changes: 2 additions & 0 deletions tools/testing/selftests/cgroup/test_zswap.c
Original file line number Diff line number Diff line change
@@ -1,4 +1,6 @@
// SPDX-License-Identifier: GPL-2.0
#define _GNU_SOURCE

#include <linux/limits.h>
#include <unistd.h>
#include <stdio.h>
Expand Down

0 comments on commit a97853f

Please sign in to comment.