Skip to content

Commit

Permalink
selftests/cgroup: remove ARRAY_SIZE define from cgroup_util.h
Browse files Browse the repository at this point in the history
ARRAY_SIZE is defined in several selftests. Remove definitions from
individual test files and include header file for the define instead.
ARRAY_SIZE define is added in a separate patch to prepare for this
change.

Remove ARRAY_SIZE from cgroup_util.h and pickup the one defined in
kselftest.h.

Signed-off-by: Shuah Khan <[email protected]>
  • Loading branch information
shuahkh committed Dec 11, 2021
1 parent 2684618 commit 72a571d
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions tools/testing/selftests/cgroup/cgroup_util.h
Original file line number Diff line number Diff line change
Expand Up @@ -2,9 +2,9 @@
#include <stdbool.h>
#include <stdlib.h>

#define PAGE_SIZE 4096
#include "../kselftest.h"

#define ARRAY_SIZE(arr) (sizeof(arr) / sizeof((arr)[0]))
#define PAGE_SIZE 4096

#define MB(x) (x << 20)

Expand Down

0 comments on commit 72a571d

Please sign in to comment.