From 542b443def2fecfd19f88f4f85f0473eb445236d Mon Sep 17 00:00:00 2001 From: André Fabian Silva Delgado Date: Wed, 16 Mar 2016 18:15:33 -0300 Subject: linux-libre-grsec{,-knock}: fix implicit declaration of function 'atomic_inc_return_unchecked' -> https://forums.grsecurity.net/viewtopic.php?f=3&t=4410 --- ...n-of-function-atomic_inc_return_unchecked.patch | 26 ++++++++++++++++++++++ libre/linux-libre-grsec/PKGBUILD | 6 +++++ 2 files changed, 32 insertions(+) create mode 100644 libre/linux-libre-grsec/0001-ARM-fix-implicit-declaration-of-function-atomic_inc_return_unchecked.patch (limited to 'libre') diff --git a/libre/linux-libre-grsec/0001-ARM-fix-implicit-declaration-of-function-atomic_inc_return_unchecked.patch b/libre/linux-libre-grsec/0001-ARM-fix-implicit-declaration-of-function-atomic_inc_return_unchecked.patch new file mode 100644 index 000000000..0f311bdc2 --- /dev/null +++ b/libre/linux-libre-grsec/0001-ARM-fix-implicit-declaration-of-function-atomic_inc_return_unchecked.patch @@ -0,0 +1,26 @@ +diff --git a/include/linux/atomic.h b/include/linux/atomic.h +index a8efdc4..b65a2b9 100644 +--- a/include/linux/atomic.h ++++ b/include/linux/atomic.h +@@ -103,6 +103,11 @@ + #define atomic_inc_return(...) \ + __atomic_op_fence(atomic_inc_return, __VA_ARGS__) + #endif ++ ++#ifndef atomic_inc_return_unchecked ++#define atomic_inc_return_unchecked(...) \ ++ __atomic_op_fence(atomic_inc_return_unchecked, __VA_ARGS__) ++#endif + #endif /* atomic_inc_return_relaxed */ + + /* atomic_sub_return_relaxed */ +@@ -255,6 +260,11 @@ + #define atomic64_inc_return(...) \ + __atomic_op_fence(atomic64_inc_return, __VA_ARGS__) + #endif ++ ++#ifndef atomic64_inc_return_unchecked ++#define atomic64_inc_return_unchecked(...) \ ++ __atomic_op_fence(atomic64_inc_return_unchecked, __VA_ARGS__) ++#endif + #endif /* atomic64_inc_return_relaxed */ diff --git a/libre/linux-libre-grsec/PKGBUILD b/libre/linux-libre-grsec/PKGBUILD index 2068f5e95..c8cece190 100644 --- a/libre/linux-libre-grsec/PKGBUILD +++ b/libre/linux-libre-grsec/PKGBUILD @@ -53,6 +53,7 @@ source=("http://linux-libre.fsfla.org/pub/linux-libre/releases/${_pkgbasever}/li # armv7h patches "https://repo.parabola.nu/other/rcn-libre-grsec/patches/${_pkgver%-*}/rcn-libre-grsec-${_pkgver%-*}-${rcnrel}.patch" "https://repo.parabola.nu/other/rcn-libre-grsec/patches/${_pkgver%-*}/rcn-libre-grsec-${_pkgver%-*}-${rcnrel}.patch.sig" + '0001-ARM-fix-implicit-declaration-of-function-atomic_inc_return_unchecked.patch' '0001-ARM-atags-add-support-for-Marvell-s-u-boot.patch' '0002-ARM-atags-fdt-retrieve-MAC-addresses-from-Marvell-bo.patch' '0003-SMILE-Plug-device-tree-file.patch' @@ -83,6 +84,7 @@ sha256sums=('f53e99866c751f21412737d1f06b0721e207f495c8c64f97dffb681795ee69a0' '3d3266bd082321dccf429cc2200d1a4d870d2031546f9f591b6dfbb698294808' '5a8d8fe270a5423fb5f712aebf55d367906a8f44f1ca343341ab67619479a319' 'SKIP' + 'faa25001a32551b5201c4e803a913100ef875a750e01596d202b5c61a3f4be82' 'a851312b26800a7e189b34547d5d4b2b62a18874f07335ac6f426c32b47c3817' '486976f36e1919eac5ee984cb9a8d23a972f23f22f8344eda47b487ea91047f4' '6dadc17ea56d93ec0f1d0c3c98c25a7863e9ba3c4af50dc411d630a1bcc98f08' @@ -124,6 +126,10 @@ prepare() { # RCN patch (CM3 firmware deblobbed) git apply -v "${srcdir}/rcn-libre-grsec-${_pkgver%-*}-${rcnrel}.patch" + # fix implicit declaration of function 'atomic_inc_return_unchecked' + # https://forums.grsecurity.net/viewtopic.php?f=3&t=4410 + patch -p1 -i "${srcdir}/0001-ARM-fix-implicit-declaration-of-function-atomic_inc_return_unchecked.patch" + # ALARM patches patch -p1 -i "${srcdir}/0001-ARM-atags-add-support-for-Marvell-s-u-boot.patch" patch -p1 -i "${srcdir}/0002-ARM-atags-fdt-retrieve-MAC-addresses-from-Marvell-bo.patch" -- cgit v1.2.3-54-g00ecf