Skip to content

Instantly share code, notes, and snippets.

@topikachu
Created November 24, 2013 07:24
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save topikachu/7624365 to your computer and use it in GitHub Desktop.
Save topikachu/7624365 to your computer and use it in GitHub Desktop.
lejos ev3 kernel patch to work with new udev
diff --git a/kernel/setup.sh b/kernel/setup.sh
index bbb0e84..a43d757 100755
--- a/kernel/setup.sh
+++ b/kernel/setup.sh
@@ -8,6 +8,7 @@
tar xfa linux*.tgz
cd linux*
patch -p1 < ../lx.patch
+patch -p1 <../sys_accept4.patch
cd ..
# do the same for the backported network modules
diff --git a/kernel/sys_accept4.patch b/kernel/sys_accept4.patch
new file mode 100644
index 0000000..5b58914
--- /dev/null
+++ b/kernel/sys_accept4.patch
@@ -0,0 +1,22 @@
+diff -rupN linux-03.20.00.13.orig/arch/arm/include/asm/unistd.h linux-03.20.00.13.new/arch/arm/include/asm/unistd.h
+--- linux-03.20.00.13.orig/arch/arm/include/asm/unistd.h 2013-11-21 21:18:45.808800821 +0800
++++ linux-03.20.00.13.new/arch/arm/include/asm/unistd.h 2013-11-21 21:20:31.828290800 +0800
+@@ -392,6 +392,7 @@
+ #define __NR_rt_tgsigqueueinfo (__NR_SYSCALL_BASE+363)
+ #define __NR_perf_event_open (__NR_SYSCALL_BASE+364)
+ #define __NR_recvmmsg (__NR_SYSCALL_BASE+365)
++#define __NR_accept4 (__NR_SYSCALL_BASE+366)
+
+ /*
+ * The following SWIs are ARM private.
+diff -rupN linux-03.20.00.13.orig/arch/arm/kernel/calls.S linux-03.20.00.13.new/arch/arm/kernel/calls.S
+--- linux-03.20.00.13.orig/arch/arm/kernel/calls.S 2013-11-21 21:18:45.828790927 +0800
++++ linux-03.20.00.13.new/arch/arm/kernel/calls.S 2013-11-21 21:21:32.666158639 +0800
+@@ -375,6 +375,7 @@
+ CALL(sys_rt_tgsigqueueinfo)
+ CALL(sys_perf_event_open)
+ /* 365 */ CALL(sys_recvmmsg)
++/* 366 */ CALL(sys_accept4)
+ #ifndef syscalls_counted
+ .equ syscalls_padding, ((NR_syscalls + 3) & ~3) - NR_syscalls
+ #define syscalls_counted
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment