mirror of
https://github.com/archlinuxarm/PKGBUILDs.git
synced 2024-10-29 22:43:48 +00:00
57 lines
1.9 KiB
Diff
57 lines
1.9 KiB
Diff
|
From d17493a9d19e5924cf5a00eb10f4a29c87084800 Mon Sep 17 00:00:00 2001
|
||
|
From: Russell King <rmk+kernel@arm.linux.org.uk>
|
||
|
Date: Fri, 8 Aug 2014 10:56:34 +0100
|
||
|
Subject: [PATCH 4/5] ARM: wire up getrandom syscall
|
||
|
|
||
|
Add the new getrandom syscall for ARM.
|
||
|
|
||
|
Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
|
||
|
---
|
||
|
arch/arm/include/asm/unistd.h | 2 +-
|
||
|
arch/arm/include/uapi/asm/unistd.h | 1 +
|
||
|
arch/arm/kernel/calls.S | 3 +++
|
||
|
3 files changed, 5 insertions(+), 1 deletion(-)
|
||
|
|
||
|
diff --git a/arch/arm/include/asm/unistd.h b/arch/arm/include/asm/unistd.h
|
||
|
index 21ca0cebcab0..32640c431a08 100644
|
||
|
--- a/arch/arm/include/asm/unistd.h
|
||
|
+++ b/arch/arm/include/asm/unistd.h
|
||
|
@@ -19,7 +19,7 @@
|
||
|
* This may need to be greater than __NR_last_syscall+1 in order to
|
||
|
* account for the padding in the syscall table
|
||
|
*/
|
||
|
-#define __NR_syscalls (384)
|
||
|
+#define __NR_syscalls (388)
|
||
|
|
||
|
/*
|
||
|
* *NOTE*: This is a ghost syscall private to the kernel. Only the
|
||
|
diff --git a/arch/arm/include/uapi/asm/unistd.h b/arch/arm/include/uapi/asm/unistd.h
|
||
|
index c3776331f407..79d451df99a3 100644
|
||
|
--- a/arch/arm/include/uapi/asm/unistd.h
|
||
|
+++ b/arch/arm/include/uapi/asm/unistd.h
|
||
|
@@ -408,6 +408,7 @@
|
||
|
#define __NR_finit_module (__NR_SYSCALL_BASE+379)
|
||
|
#define __NR_sched_setattr (__NR_SYSCALL_BASE+380)
|
||
|
#define __NR_sched_getattr (__NR_SYSCALL_BASE+381)
|
||
|
+#define __NR_getrandom (__NR_SYSCALL_BASE+384)
|
||
|
|
||
|
/*
|
||
|
* The following SWIs are ARM private.
|
||
|
diff --git a/arch/arm/kernel/calls.S b/arch/arm/kernel/calls.S
|
||
|
index 166e945de832..7df289c3507b 100644
|
||
|
--- a/arch/arm/kernel/calls.S
|
||
|
+++ b/arch/arm/kernel/calls.S
|
||
|
@@ -391,6 +391,9 @@
|
||
|
CALL(sys_finit_module)
|
||
|
/* 380 */ CALL(sys_sched_setattr)
|
||
|
CALL(sys_sched_getattr)
|
||
|
+ CALL(sys_ni_syscall)
|
||
|
+ CALL(sys_ni_syscall)
|
||
|
+ CALL(sys_getrandom)
|
||
|
#ifndef syscalls_counted
|
||
|
.equ syscalls_padding, ((NR_syscalls + 3) & ~3) - NR_syscalls
|
||
|
#define syscalls_counted
|
||
|
--
|
||
|
2.12.2
|
||
|
|