Skip to content

Commit 672dbf9

Browse files
brooniewilldeacon
authored andcommitted
kselftest/arm64: Use the tools/include compiler.h rather than our own
The BTI test program started life as standalone programs outside the kselftest suite so provided it's own compiler.h. Now that we have updated the tools/include compiler.h to have all the definitions that we are using and the arm64 selftsets pull in tools/includes let's drop our custom version. __unreachable() is named unreachable() there requiring an update in the code. Signed-off-by: Mark Brown <[email protected]> Link: https://lore.kernel.org/r/[email protected] Signed-off-by: Will Deacon <[email protected]>
1 parent db7a89f commit 672dbf9

File tree

4 files changed

+3
-27
lines changed

4 files changed

+3
-27
lines changed

tools/testing/selftests/arm64/bti/compiler.h

Lines changed: 0 additions & 21 deletions
This file was deleted.

tools/testing/selftests/arm64/bti/system.c

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -8,12 +8,10 @@
88

99
#include <asm/unistd.h>
1010

11-
#include "compiler.h"
12-
1311
void __noreturn exit(int n)
1412
{
1513
syscall(__NR_exit, n);
16-
__unreachable();
14+
unreachable();
1715
}
1816

1917
ssize_t write(int fd, const void *buf, size_t size)

tools/testing/selftests/arm64/bti/system.h

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -14,12 +14,12 @@ typedef __kernel_size_t size_t;
1414
typedef __kernel_ssize_t ssize_t;
1515

1616
#include <linux/errno.h>
17+
#include <linux/compiler.h>
18+
1719
#include <asm/hwcap.h>
1820
#include <asm/ptrace.h>
1921
#include <asm/unistd.h>
2022

21-
#include "compiler.h"
22-
2323
long syscall(int nr, ...);
2424

2525
void __noreturn exit(int n);

tools/testing/selftests/arm64/bti/test.c

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,6 @@
1717
typedef struct ucontext ucontext_t;
1818

1919
#include "btitest.h"
20-
#include "compiler.h"
2120
#include "signal.h"
2221

2322
#define EXPECTED_TESTS 18

0 commit comments

Comments
 (0)