Skip to content

Commit 7527c03

Browse files
committed
selftests/timens: remove ARRAY_SIZE define from individual tests
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 timens tests and pickup the one defined in kselftest.h. Signed-off-by: Shuah Khan <[email protected]>
1 parent 08ca351 commit 7527c03

File tree

2 files changed

+0
-4
lines changed

2 files changed

+0
-4
lines changed

tools/testing/selftests/timens/procfs.c

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -24,8 +24,6 @@
2424
#define DAY_IN_SEC (60*60*24)
2525
#define TEN_DAYS_IN_SEC (10*DAY_IN_SEC)
2626

27-
#define ARRAY_SIZE(arr) (sizeof(arr) / sizeof((arr)[0]))
28-
2927
static int child_ns, parent_ns;
3028

3129
static int switch_ns(int fd)

tools/testing/selftests/timens/timens.c

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -22,8 +22,6 @@
2222
#define DAY_IN_SEC (60*60*24)
2323
#define TEN_DAYS_IN_SEC (10*DAY_IN_SEC)
2424

25-
#define ARRAY_SIZE(arr) (sizeof(arr) / sizeof((arr)[0]))
26-
2725
struct test_clock {
2826
clockid_t id;
2927
char *name;

0 commit comments

Comments
 (0)