Subject: [alpine-devel] [PATCH] testing/linux-virt-grsec

From: <[email-masked]>
Date: Thu, 2 Aug 2012 2:02:30 +0000

Attached is a git patch (I hope I did it right - still not used to
working with git) for linux-virt-grsec which updates the kernel
to 3.4.7 and the grsecurity patch to the 201208011850 version.

Either the kernel upgrade or grsecurity patch appears to fix the
CONFIG_TRANSPARENT_HUGEPAGES vs. Xen bug, so it's turned back on
in the config file.  A recent PAX update included in grsecurity
adds a new CONFIG_PAX_LATENT_ENTROPY option which is left off.

-dean takemori

diff --git a/testing/linux-virt-grsec/APKBUILD b/testing/linux-virt-grsec/APKBUILD
index 792c11c..2089ace 100644
--- a/testing/linux-virt-grsec/APKBUILD
+++ b/testing/linux-virt-grsec/APKBUILD
@@ -2,9 +2,9 @@
 
 _flavor=grsec
 pkgname=linux-virt-${_flavor}
-pkgver=3.4.5
+pkgver=3.4.7
 _kernver=3.4
-pkgrel=2
+pkgrel=1
 pkgdesc="Linux kernel with grsecurity"
 url=http://grsecurity.net
 depends="mkinitfs linux-firmware"
@@ -14,7 +14,7 @@ _config=${config:-kernelconfig.${CARCH}}
 install=
 source="http://ftp.kernel.org/pub/linux/kernel/v3.x/linux-$_kernver.tar.xz
 	http://ftp.kernel.org/pub/linux/kernel/v3.x/patch-$pkgver.xz
-	grsecurity-2.9.1-3.4.5-201207171624.patch
+	grsecurity-2.9.1-3.4.7-201208011850.patch
 	xen-xsave.patch
 
 	kernelconfig.x86
@@ -136,7 +136,7 @@ dev() {
 }
 
 md5sums="967f72983655e2479f951195953e8480  linux-3.4.tar.xz
-e60f1d8032069d091f3692c1d7a89b8b  patch-3.4.5.xz
-2d4274ea6a7ebb913b989952155a14e1  grsecurity-2.9.1-3.4.5-201207171624.patch
+5258bea05aa6d0a52fcaea28b1b74c29  patch-3.4.7.xz
+8540c249996c6758641b5ed27e85013a  grsecurity-2.9.1-3.4.7-201208011850.patch
 0d095dbf194d5609ad260ecd3f0ab15d  xen-xsave.patch
-aec563c335f60a6bdc18196ca0e45934  kernelconfig.x86"
+12431a8d015873251c34710b288cf43f  kernelconfig.x86"
diff --git a/testing/linux-virt-grsec/kernelconfig.x86 b/testing/linux-virt-grsec/kernelconfig.x86
index 5b03086..95ae919 100644
--- a/testing/linux-virt-grsec/kernelconfig.x86
+++ b/testing/linux-virt-grsec/kernelconfig.x86
@@ -1,6 +1,6 @@
 #
 # Automatically generated file; DO NOT EDIT.
-# Linux/i386 3.4.5 Kernel Configuration
+# Linux/i386 3.4.7 Kernel Configuration
 #
 # CONFIG_64BIT is not set
 CONFIG_X86_32=y
@@ -428,7 +428,9 @@ CONFIG_VIRT_TO_BUS=y
 CONFIG_MMU_NOTIFIER=y
 CONFIG_KSM=y
 CONFIG_DEFAULT_MMAP_MIN_ADDR=65536
-# CONFIG_TRANSPARENT_HUGEPAGE is not set
+CONFIG_TRANSPARENT_HUGEPAGE=y
+CONFIG_TRANSPARENT_HUGEPAGE_ALWAYS=y
+# CONFIG_TRANSPARENT_HUGEPAGE_MADVISE is not set
 CONFIG_CLEANCACHE=y
 # CONFIG_HIGHPTE is not set
 # CONFIG_X86_CHECK_BIOS_CORRUPTION is not set
@@ -3281,6 +3283,7 @@ CONFIG_PAX_RANDMMAP=y
 CONFIG_PAX_REFCOUNT=y
 # CONFIG_PAX_USERCOPY is not set
 # CONFIG_PAX_SIZE_OVERFLOW is not set
+# CONFIG_PAX_LATENT_ENTROPY is not set
 
 #
 # Memory Protections