summaryrefslogtreecommitdiffstats
path: root/main/linux-grsec
diff options
context:
space:
mode:
authorNatanael Copa <ncopa@alpinelinux.org>2013-05-17 08:29:37 +0000
committerNatanael Copa <ncopa@alpinelinux.org>2013-05-17 08:30:49 +0000
commit38b0da640df3b549dea1106199baeddda85057cd (patch)
tree34ad80c0cc517eaac6ee15cf6aa3a81b7da886e2 /main/linux-grsec
parentffae20632af61ef067c268e9666aec7827ae0686 (diff)
downloadaports-38b0da640df3b549dea1106199baeddda85057cd.tar.bz2
aports-38b0da640df3b549dea1106199baeddda85057cd.tar.xz
main/linux-grsec: upgrade to 2.9.1-3.9.2-201305162327 and fix boot on alix
fixes #1789
Diffstat (limited to 'main/linux-grsec')
-rw-r--r--main/linux-grsec/APKBUILD14
-rw-r--r--main/linux-grsec/grsecurity-2.9.1-3.9.2-201305162327.patch (renamed from main/linux-grsec/grsecurity-2.9.1-3.9.2-201305142035.patch)243
-rw-r--r--main/linux-grsec/leds-leds-gpio-reserve-gpio-before-using-it.patch114
3 files changed, 332 insertions, 39 deletions
diff --git a/main/linux-grsec/APKBUILD b/main/linux-grsec/APKBUILD
index 5540cbef5..6eee77349 100644
--- a/main/linux-grsec/APKBUILD
+++ b/main/linux-grsec/APKBUILD
@@ -7,7 +7,7 @@ case $pkgver in
*.*.*) _kernver=${pkgver%.*};;
*.*) _kernver=${pkgver};;
esac
-pkgrel=1
+pkgrel=2
pkgdesc="Linux kernel with grsecurity"
url=http://grsecurity.net
depends="mkinitfs linux-firmware"
@@ -17,9 +17,10 @@ _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.9.2-201305142035.patch
+ grsecurity-2.9.1-3.9.2-201305162327.patch
0004-arp-flush-arp-cache-on-device-change.patch
+ leds-leds-gpio-reserve-gpio-before-using-it.patch
kernelconfig.x86
kernelconfig.x86_64
@@ -145,19 +146,22 @@ dev() {
md5sums="4348c9b6b2eb3144d601e87c19d5d909 linux-3.9.tar.xz
adeb2556568f79e827e7a0ce4c483605 patch-3.9.2.xz
-cfecbd87d5123f77b3adb8b9d83b4282 grsecurity-2.9.1-3.9.2-201305142035.patch
+089d16b7c5306ed0d42e344ce1b59615 grsecurity-2.9.1-3.9.2-201305162327.patch
776adeeb5272093574f8836c5037dd7d 0004-arp-flush-arp-cache-on-device-change.patch
+83db7136608d8101ae130728539dc376 leds-leds-gpio-reserve-gpio-before-using-it.patch
ae4d8b3e917cdea5330ec52048080de3 kernelconfig.x86
839de81fedd3a6294d42da70a3fb99e0 kernelconfig.x86_64"
sha256sums="60bc3e64ee5dc778de2cd7cd7640abf518a4c9d4f31b8ed624e16fad53f54541 linux-3.9.tar.xz
069126b2b70acbc27fada2bf67235238fd90ff103267b1bb392244a301321996 patch-3.9.2.xz
-d4e3fdf0893e671b4108ac45053a6e8d3f8832965a56aa9ecac0032f9eebdd09 grsecurity-2.9.1-3.9.2-201305142035.patch
+3de1633f26c46a4c93af8497d889a5acc37db54adaa4f3677cb5c5c027787254 grsecurity-2.9.1-3.9.2-201305162327.patch
e2d2d1503f53572c6a2e21da729a13a430dd01f510405ffb3a33b29208860bde 0004-arp-flush-arp-cache-on-device-change.patch
+13676bc5610a8d03e788ac76734babd1338b023bb39559452ee54652b046e6f4 leds-leds-gpio-reserve-gpio-before-using-it.patch
513a5f387e7453169a7f41c1ba42da3229e47edd58b5ac18da31f04905c5c0bf kernelconfig.x86
e842cf49decc9a8f5c0f2e4b431382f521fe41db22f2c2e6a1c077b2b158b3ab kernelconfig.x86_64"
sha512sums="77fa521f42380409f8ab400c26f7b00e225cb075ef40834bb263325cfdcc3e65aef8511ec2fc2b50bbf4f50e226fb5ab07d7a479aaf09162adbbf318325d0790 linux-3.9.tar.xz
439e32edab86f8b1bd49bc4c9325e11520d78b8182ae88aebf46a4be319c4633d6d896e2ecd3fe0363d9247f5af88a989aafca9103b8e1544262bd191440dae9 patch-3.9.2.xz
-8b4fdb6d79ca3e25414064f1b303bb9f840b8a65778cda84c33063567dceff5dc46c265d1976b1e0e0aedb1f45547267e8bf3d92c25c8049ebf619268350204d grsecurity-2.9.1-3.9.2-201305142035.patch
+652847ba23a7761d6fe90a04deb68f28cdde65d71bd9a53355075ba8410279250d36169359fa759208fcf45b5bfc1cc9505f072e93dd47eae5c464652760aa97 grsecurity-2.9.1-3.9.2-201305162327.patch
b6fdf376009f0f0f3fa194cb11be97343e4d394cf5d3547de6cfca8ad619c5bd3f60719331fd8cfadc47f09d22be8376ba5f871b46b24887ea73fe47e233a54e 0004-arp-flush-arp-cache-on-device-change.patch
+10d2cf4fb308d1bc8cb5b9df3f9a6d7b9cef453244673bcbe66bd9b64af410a498e203d4dfa51f53461362ad981736eadc46537616b2c0514f57f4d8864c830d leds-leds-gpio-reserve-gpio-before-using-it.patch
57dc79b8b08a81993e1050197886c7f91a609843ed2f919eabd6769860fb1383e87a433def8f6b544a8c6382180822b863869ef76183c4d9df421465fe13c220 kernelconfig.x86
0ce361b417821fc3795c4d8e4b3a8eeecbdc7df66261f744c55d288186f9a7d2a367f80bac2ff29c0d5c54f133cbbd74f3ec5e0147b0e7c04462627724dd3572 kernelconfig.x86_64"
diff --git a/main/linux-grsec/grsecurity-2.9.1-3.9.2-201305142035.patch b/main/linux-grsec/grsecurity-2.9.1-3.9.2-201305162327.patch
index 7808b2716..588c5edc1 100644
--- a/main/linux-grsec/grsecurity-2.9.1-3.9.2-201305142035.patch
+++ b/main/linux-grsec/grsecurity-2.9.1-3.9.2-201305162327.patch
@@ -2028,6 +2028,19 @@ index 06e7d50..8a8e251 100644
nommu_start_thread(regs); \
})
+diff --git a/arch/arm/include/asm/psci.h b/arch/arm/include/asm/psci.h
+index ce0dbe7..c085b6f 100644
+--- a/arch/arm/include/asm/psci.h
++++ b/arch/arm/include/asm/psci.h
+@@ -29,7 +29,7 @@ struct psci_operations {
+ int (*cpu_off)(struct psci_power_state state);
+ int (*cpu_on)(unsigned long cpuid, unsigned long entry_point);
+ int (*migrate)(unsigned long cpuid);
+-};
++} __no_const;
+
+ extern struct psci_operations psci_ops;
+
diff --git a/arch/arm/include/asm/smp.h b/arch/arm/include/asm/smp.h
index d3a22be..3a69ad5 100644
--- a/arch/arm/include/asm/smp.h
@@ -2824,6 +2837,19 @@ index 047d3e4..7e96107 100644
return 0;
}
arch_initcall(gate_vma_init);
+diff --git a/arch/arm/kernel/psci.c b/arch/arm/kernel/psci.c
+index 3653164..d83e55d 100644
+--- a/arch/arm/kernel/psci.c
++++ b/arch/arm/kernel/psci.c
+@@ -24,7 +24,7 @@
+ #include <asm/opcodes-virt.h>
+ #include <asm/psci.h>
+
+-struct psci_operations psci_ops;
++struct psci_operations psci_ops __read_only;
+
+ static int (*invoke_psci_fn)(u32, u32, u32, u32);
+
diff --git a/arch/arm/kernel/ptrace.c b/arch/arm/kernel/ptrace.c
index 03deeff..741ce88 100644
--- a/arch/arm/kernel/ptrace.c
@@ -22547,7 +22573,7 @@ index 5cdff03..80fa283 100644
* Up to this point, the boot CPU has been using .init.data
* area. Reload any changed state for the boot CPU.
diff --git a/arch/x86/kernel/signal.c b/arch/x86/kernel/signal.c
-index 6956299..6797253 100644
+index 6956299..f20beae 100644
--- a/arch/x86/kernel/signal.c
+++ b/arch/x86/kernel/signal.c
@@ -196,7 +196,7 @@ static unsigned long align_sigframe(unsigned long sp)
@@ -22601,6 +22627,29 @@ index 6956299..6797253 100644
} put_user_catch(err);
err |= copy_siginfo_to_user(&frame->info, &ksig->info);
+@@ -615,7 +618,12 @@ setup_rt_frame(struct ksignal *ksig, struct pt_regs *regs)
+ {
+ int usig = signr_convert(ksig->sig);
+ sigset_t *set = sigmask_to_save();
+- compat_sigset_t *cset = (compat_sigset_t *) set;
++ sigset_t sigcopy;
++ compat_sigset_t *cset;
++
++ sigcopy = *set;
++
++ cset = (compat_sigset_t *) &sigcopy;
+
+ /* Set up the stack frame */
+ if (is_ia32_frame()) {
+@@ -626,7 +634,7 @@ setup_rt_frame(struct ksignal *ksig, struct pt_regs *regs)
+ } else if (is_x32_frame()) {
+ return x32_setup_rt_frame(ksig, cset, regs);
+ } else {
+- return __setup_rt_frame(ksig->sig, ksig, set, regs);
++ return __setup_rt_frame(ksig->sig, ksig, &sigcopy, regs);
+ }
+ }
+
diff --git a/arch/x86/kernel/smp.c b/arch/x86/kernel/smp.c
index 48d2b7d..90d328a 100644
--- a/arch/x86/kernel/smp.c
@@ -22953,7 +23002,7 @@ index 0000000..207bec6
+ return addr;
+}
diff --git a/arch/x86/kernel/sys_x86_64.c b/arch/x86/kernel/sys_x86_64.c
-index dbded5a..7916f74 100644
+index dbded5a..ace2781 100644
--- a/arch/x86/kernel/sys_x86_64.c
+++ b/arch/x86/kernel/sys_x86_64.c
@@ -81,8 +81,8 @@ out:
@@ -23020,7 +23069,7 @@ index dbded5a..7916f74 100644
/* requested length too big for entire address space */
if (len > TASK_SIZE)
-@@ -161,6 +167,10 @@ arch_get_unmapped_area_topdown(struct file *filp, const unsigned long addr0,
+@@ -161,12 +167,15 @@ arch_get_unmapped_area_topdown(struct file *filp, const unsigned long addr0,
if (!test_thread_flag(TIF_ADDR32) && (flags & MAP_32BIT))
goto bottomup;
@@ -23031,7 +23080,14 @@ index dbded5a..7916f74 100644
/* requesting a specific address */
if (addr) {
addr = PAGE_ALIGN(addr);
-@@ -176,6 +186,7 @@ arch_get_unmapped_area_topdown(struct file *filp, const unsigned long addr0,
+ vma = find_vma(mm, addr);
+- if (TASK_SIZE - len >= addr &&
+- (!vma || addr + len <= vma->vm_start))
++ if (TASK_SIZE - len >= addr && check_heap_stack_gap(vma, addr, len, offset))
+ return addr;
+ }
+
+@@ -176,6 +185,7 @@ arch_get_unmapped_area_topdown(struct file *filp, const unsigned long addr0,
info.high_limit = mm->mmap_base;
info.align_mask = filp ? get_align_mask() : 0;
info.align_offset = pgoff << PAGE_SHIFT;
@@ -35917,7 +35973,7 @@ index 4640adb..e1384ed 100644
for (;;) {
diff --git a/drivers/gpu/drm/vmwgfx/vmwgfx_marker.c b/drivers/gpu/drm/vmwgfx/vmwgfx_marker.c
-index 8a8725c..afed796 100644
+index 8a8725c2..afed796 100644
--- a/drivers/gpu/drm/vmwgfx/vmwgfx_marker.c
+++ b/drivers/gpu/drm/vmwgfx/vmwgfx_marker.c
@@ -151,7 +151,7 @@ int vmw_wait_lag(struct vmw_private *dev_priv,
@@ -36111,6 +36167,55 @@ index a14f634..2916ee2 100644
int err;
/* Set up read-only sensors */
+diff --git a/drivers/hwmon/pmbus/pmbus_core.c b/drivers/hwmon/pmbus/pmbus_core.c
+index 9add6092..ee7ba3f 100644
+--- a/drivers/hwmon/pmbus/pmbus_core.c
++++ b/drivers/hwmon/pmbus/pmbus_core.c
+@@ -781,7 +781,7 @@ static int pmbus_add_attribute(struct pmbus_data *data, struct attribute *attr)
+ return 0;
+ }
+
+-static void pmbus_dev_attr_init(struct device_attribute *dev_attr,
++static void pmbus_dev_attr_init(device_attribute_no_const *dev_attr,
+ const char *name,
+ umode_t mode,
+ ssize_t (*show)(struct device *dev,
+@@ -798,7 +798,7 @@ static void pmbus_dev_attr_init(struct device_attribute *dev_attr,
+ dev_attr->store = store;
+ }
+
+-static void pmbus_attr_init(struct sensor_device_attribute *a,
++static void pmbus_attr_init(sensor_device_attribute_no_const *a,
+ const char *name,
+ umode_t mode,
+ ssize_t (*show)(struct device *dev,
+@@ -820,7 +820,7 @@ static int pmbus_add_boolean(struct pmbus_data *data,
+ u16 reg, u8 mask)
+ {
+ struct pmbus_boolean *boolean;
+- struct sensor_device_attribute *a;
++ sensor_device_attribute_no_const *a;
+
+ boolean = devm_kzalloc(data->dev, sizeof(*boolean), GFP_KERNEL);
+ if (!boolean)
+@@ -845,7 +845,7 @@ static struct pmbus_sensor *pmbus_add_sensor(struct pmbus_data *data,
+ bool update, bool readonly)
+ {
+ struct pmbus_sensor *sensor;
+- struct device_attribute *a;
++ device_attribute_no_const *a;
+
+ sensor = devm_kzalloc(data->dev, sizeof(*sensor), GFP_KERNEL);
+ if (!sensor)
+@@ -876,7 +876,7 @@ static int pmbus_add_label(struct pmbus_data *data,
+ const char *lstring, int index)
+ {
+ struct pmbus_label *label;
+- struct device_attribute *a;
++ device_attribute_no_const *a;
+
+ label = devm_kzalloc(data->dev, sizeof(*label), GFP_KERNEL);
+ if (!label)
diff --git a/drivers/hwmon/sht15.c b/drivers/hwmon/sht15.c
index 2507f90..1645765 100644
--- a/drivers/hwmon/sht15.c
@@ -37129,7 +37234,7 @@ index 7c11ff3..5b2d7a7 100644
bool setup_remapped_irq(int irq, struct irq_cfg *cfg, struct irq_chip *chip)
diff --git a/drivers/irqchip/irq-gic.c b/drivers/irqchip/irq-gic.c
-index fc6aebf..94d5248 100644
+index fc6aebf..762c5f5 100644
--- a/drivers/irqchip/irq-gic.c
+++ b/drivers/irqchip/irq-gic.c
@@ -83,7 +83,7 @@ static u8 gic_cpu_map[NR_GIC_CPU_IF] __read_mostly;
@@ -37137,7 +37242,7 @@ index fc6aebf..94d5248 100644
* Default make them NULL.
*/
-struct irq_chip gic_arch_extn = {
-+irq_chip_no_const gic_arch_extn __read_only = {
++irq_chip_no_const gic_arch_extn = {
.irq_eoi = NULL,
.irq_mask = NULL,
.irq_unmask = NULL,
@@ -39318,6 +39423,50 @@ index fbe5363..266b4e3 100644
fifo->mempool =
__vxge_hw_mempool_create(vpath->hldev,
fifo->config->memblock_size,
+diff --git a/drivers/net/ethernet/qlogic/qlcnic/qlcnic_83xx_init.c b/drivers/net/ethernet/qlogic/qlcnic/qlcnic_83xx_init.c
+index 5c033f2..7bbb0d8 100644
+--- a/drivers/net/ethernet/qlogic/qlcnic/qlcnic_83xx_init.c
++++ b/drivers/net/ethernet/qlogic/qlcnic/qlcnic_83xx_init.c
+@@ -1894,7 +1894,9 @@ int qlcnic_83xx_config_default_opmode(struct qlcnic_adapter *adapter)
+ op_mode = QLCRDX(ahw, QLC_83XX_DRV_OP_MODE);
+
+ if (op_mode == QLC_83XX_DEFAULT_OPMODE) {
+- adapter->nic_ops->init_driver = qlcnic_83xx_init_default_driver;
++ pax_open_kernel();
++ *(void **)&adapter->nic_ops->init_driver = qlcnic_83xx_init_default_driver;
++ pax_close_kernel();
+ ahw->idc.state_entry = qlcnic_83xx_idc_ready_state_entry;
+ } else {
+ return -EIO;
+diff --git a/drivers/net/ethernet/qlogic/qlcnic/qlcnic_83xx_vnic.c b/drivers/net/ethernet/qlogic/qlcnic/qlcnic_83xx_vnic.c
+index b0c3de9..fc5857e 100644
+--- a/drivers/net/ethernet/qlogic/qlcnic/qlcnic_83xx_vnic.c
++++ b/drivers/net/ethernet/qlogic/qlcnic/qlcnic_83xx_vnic.c
+@@ -200,15 +200,21 @@ int qlcnic_83xx_config_vnic_opmode(struct qlcnic_adapter *adapter)
+ if (priv_level == QLCNIC_NON_PRIV_FUNC) {
+ ahw->op_mode = QLCNIC_NON_PRIV_FUNC;
+ ahw->idc.state_entry = qlcnic_83xx_idc_ready_state_entry;
+- nic_ops->init_driver = qlcnic_83xx_init_non_privileged_vnic;
++ pax_open_kernel();
++ *(void **)&nic_ops->init_driver = qlcnic_83xx_init_non_privileged_vnic;
++ pax_close_kernel();
+ } else if (priv_level == QLCNIC_PRIV_FUNC) {
+ ahw->op_mode = QLCNIC_PRIV_FUNC;
+ ahw->idc.state_entry = qlcnic_83xx_idc_vnic_pf_entry;
+- nic_ops->init_driver = qlcnic_83xx_init_privileged_vnic;
++ pax_open_kernel();
++ *(void **)&nic_ops->init_driver = qlcnic_83xx_init_privileged_vnic;
++ pax_close_kernel();
+ } else if (priv_level == QLCNIC_MGMT_FUNC) {
+ ahw->op_mode = QLCNIC_MGMT_FUNC;
+ ahw->idc.state_entry = qlcnic_83xx_idc_ready_state_entry;
+- nic_ops->init_driver = qlcnic_83xx_init_mgmt_vnic;
++ pax_open_kernel();
++ *(void **)&nic_ops->init_driver = qlcnic_83xx_init_mgmt_vnic;
++ pax_close_kernel();
+ } else {
+ return -EIO;
+ }
diff --git a/drivers/net/ethernet/realtek/r8169.c b/drivers/net/ethernet/realtek/r8169.c
index 15ba8c4..3f56838 100644
--- a/drivers/net/ethernet/realtek/r8169.c
@@ -40628,6 +40777,19 @@ index 0b00947..64f7c0a 100644
proc_create("devices", 0, proc_bus_pci_dir,
&proc_bus_pci_dev_operations);
proc_initialized = 1;
+diff --git a/drivers/platform/x86/chromeos_laptop.c b/drivers/platform/x86/chromeos_laptop.c
+index 3e5b4497..dcdfb70 100644
+--- a/drivers/platform/x86/chromeos_laptop.c
++++ b/drivers/platform/x86/chromeos_laptop.c
+@@ -301,7 +301,7 @@ static int __init setup_tsl2563_als(const struct dmi_system_id *id)
+ return 0;
+ }
+
+-static struct dmi_system_id __initdata chromeos_laptop_dmi_table[] = {
++static struct dmi_system_id __initconst chromeos_laptop_dmi_table[] = {
+ {
+ .ident = "Samsung Series 5 550 - Touchpad",
+ .matches = {
diff --git a/drivers/platform/x86/msi-laptop.c b/drivers/platform/x86/msi-laptop.c
index 6b22938..bc9700e 100644
--- a/drivers/platform/x86/msi-laptop.c
@@ -52386,27 +52548,9 @@ index a6597d6..41b30ec 100644
/*
diff --git a/fs/jfs/super.c b/fs/jfs/super.c
-index 2003e83..5e1975d 100644
+index 2003e83..40db287 100644
--- a/fs/jfs/super.c
+++ b/fs/jfs/super.c
-@@ -225,7 +225,7 @@ static const match_table_t tokens = {
- static int parse_options(char *options, struct super_block *sb, s64 *newLVSize,
- int *flag)
- {
-- void *nls_map = (void *)-1; /* -1: no change; NULL: none */
-+ const void *nls_map = (const void *)-1; /* -1: no change; NULL: none */
- char *p;
- struct jfs_sb_info *sbi = JFS_SBI(sb);
-
-@@ -253,7 +253,7 @@ static int parse_options(char *options, struct super_block *sb, s64 *newLVSize,
- /* Don't do anything ;-) */
- break;
- case Opt_iocharset:
-- if (nls_map && nls_map != (void *) -1)
-+ if (nls_map && nls_map != (const void *) -1)
- unload_nls(nls_map);
- if (!strcmp(args[0].from, "none"))
- nls_map = NULL;
@@ -856,7 +856,7 @@ static int __init init_jfs_fs(void)
jfs_inode_cachep =
@@ -68845,11 +68989,15 @@ index bc4e066..50468a9 100644
/*
* irq_chip specific flags
diff --git a/include/linux/irqchip/arm-gic.h b/include/linux/irqchip/arm-gic.h
-index 3fd8e42..d5403e1 100644
+index 3fd8e42..a73e966 100644
--- a/include/linux/irqchip/arm-gic.h
+++ b/include/linux/irqchip/arm-gic.h
-@@ -61,7 +61,7 @@
+@@ -59,9 +59,11 @@
+
+ #ifndef __ASSEMBLY__
++#include <linux/irq.h>
++
struct device_node;
-extern struct irq_chip gic_arch_extn;
@@ -72219,6 +72367,19 @@ index b797e8f..8e2c3aa 100644
/**
+diff --git a/include/sound/compress_driver.h b/include/sound/compress_driver.h
+index ff6c741..393815f 100644
+--- a/include/sound/compress_driver.h
++++ b/include/sound/compress_driver.h
+@@ -130,7 +130,7 @@ struct snd_compr_ops {
+ struct snd_compr_caps *caps);
+ int (*get_codec_caps) (struct snd_compr_stream *stream,
+ struct snd_compr_codec_caps *codec);
+-};
++} __no_const;
+
+ /**
+ * struct snd_compr: Compressed device
diff --git a/include/sound/soc.h b/include/sound/soc.h
index a6a059c..2243336 100644
--- a/include/sound/soc.h
@@ -87228,7 +87389,7 @@ index 5b1e5af..2358147 100644
return res;
}
diff --git a/net/mac80211/cfg.c b/net/mac80211/cfg.c
-index 843d8c4..6e0a0ff 100644
+index 843d8c4..cb04fa1 100644
--- a/net/mac80211/cfg.c
+++ b/net/mac80211/cfg.c
@@ -799,7 +799,7 @@ static int ieee80211_set_monitor_channel(struct wiphy *wiphy,
@@ -87255,8 +87416,8 @@ index 843d8c4..6e0a0ff 100644
ret = 0;
- } else if (local->open_count > 0 &&
- local->open_count == local->monitors &&
-+ } else if (atomic_read(&local->open_count) > 0 &&
-+ atomic_read(&local->open_count) == local->monitors &&
++ } else if (local_read(&local->open_count) > 0 &&
++ local_read(&local->open_count) == local->monitors &&
sdata->vif.type == NL80211_IFTYPE_MONITOR) {
if (local->use_chanctx)
*chandef = local->monitor_chandef;
@@ -90177,10 +90338,10 @@ index f5eb43d..1814de8 100644
shdr = (Elf_Shdr *)((char *)ehdr + _r(&ehdr->e_shoff));
shstrtab_sec = shdr + r2(&ehdr->e_shstrndx);
diff --git a/security/Kconfig b/security/Kconfig
-index e9c6ac7..eef8ada 100644
+index e9c6ac7..e6254cf 100644
--- a/security/Kconfig
+++ b/security/Kconfig
-@@ -4,6 +4,943 @@
+@@ -4,6 +4,944 @@
menu "Security options"
@@ -90214,6 +90375,7 @@ index e9c6ac7..eef8ada 100644
+ select CRYPTO_SHA256
+ select PROC_FS
+ select STOP_MACHINE
++ select TTY
+ help
+ If you say Y here, you will be able to configure many features
+ that will enhance the security of your system. It is highly
@@ -91124,7 +91286,7 @@ index e9c6ac7..eef8ada 100644
source security/keys/Kconfig
config SECURITY_DMESG_RESTRICT
-@@ -103,7 +1040,7 @@ config INTEL_TXT
+@@ -103,7 +1041,7 @@ config INTEL_TXT
config LSM_MMAP_MIN_ADDR
int "Low address space for LSM to protect from user allocation"
depends on SECURITY && SECURITY_SELINUX
@@ -92082,6 +92244,19 @@ index 22056c5..25d3244 100644
chip->card = card;
chip->pci = pci;
chip->irq = -1;
+diff --git a/sound/soc/fsl/fsl_ssi.c b/sound/soc/fsl/fsl_ssi.c
+index 7decbd9..d17d9d0 100644
+--- a/sound/soc/fsl/fsl_ssi.c
++++ b/sound/soc/fsl/fsl_ssi.c
+@@ -643,7 +643,7 @@ static int fsl_ssi_probe(struct platform_device *pdev)
+ {
+ struct fsl_ssi_private *ssi_private;
+ int ret = 0;
+- struct device_attribute *dev_attr = NULL;
++ device_attribute_no_const *dev_attr = NULL;
+ struct device_node *np = pdev->dev.of_node;
+ const char *p, *sprop;
+ const uint32_t *iprop;
diff --git a/tools/gcc/.gitignore b/tools/gcc/.gitignore
new file mode 100644
index 0000000..50f2f2f
diff --git a/main/linux-grsec/leds-leds-gpio-reserve-gpio-before-using-it.patch b/main/linux-grsec/leds-leds-gpio-reserve-gpio-before-using-it.patch
new file mode 100644
index 000000000..f7af3b2a0
--- /dev/null
+++ b/main/linux-grsec/leds-leds-gpio-reserve-gpio-before-using-it.patch
@@ -0,0 +1,114 @@
+From 37e3042c345024aa5e39a1a28a667a00b75fd6ce Mon Sep 17 00:00:00 2001
+From: =?UTF-8?q?Timo=20Ter=C3=A4s?= <timo.teras@iki.fi>
+Date: Fri, 17 May 2013 09:31:13 +0300
+Subject: [PATCH] leds: leds-gpio: reserve gpio before using it
+MIME-Version: 1.0
+Content-Type: text/plain; charset=UTF-8
+Content-Transfer-Encoding: 8bit
+
+This reverts commit a99d76f (leds: leds-gpio: use gpio_request_one)
+and commit 2d7c22f (leds: leds-gpio: set devm_gpio_request_one()
+flags param correctly) which was a fix of the first one.
+
+The conversion to devm_gpio_request in commit e3b1d44c (leds:
+leds-gpio: use devm_gpio_request_one) is not reverted.
+
+The problem is that gpio_cansleep() and gpio_get_value_cansleep()
+calls can crash if the gpio is not first reserved. Incidentally this
+same bug existed earlier and was fixed similarly in commit d95cbe61
+(leds: Fix potential leds-gpio oops). But the OOPS is real. It happens
+when GPIOs are provided by module which is not yet loaded.
+
+So this fixes the following BUG during my ALIX boot (3.9.2-vanilla):
+
+BUG: unable to handle kernel NULL pointer dereference at 0000004c
+IP: [<c11287d6>] __gpio_cansleep+0xe/0x1a
+*pde = 00000000
+Oops: 0000 [#1] SMP
+Modules linked in: leds_gpio(+) via_rhine mii cs5535_mfd mfd_core
+geode_rng rng_core geode_aes isofs nls_utf8 nls_cp437 vfat fat
+ata_generic pata_amd pata_cs5536 pata_acpi libata ehci_pci ehci_hcd
+ohci_hcd usb_storage usbcore usb_common sd_mod scsi_mod squashfs loop
+Pid: 881, comm: modprobe Not tainted 3.9.2 #1-Alpine
+EIP: 0060:[<c11287d6>] EFLAGS: 00010282 CPU: 0
+EIP is at __gpio_cansleep+0xe/0x1a
+EAX: 00000000 EBX: cf364018 ECX: c132b8b9 EDX: 00000000
+ESI: c13993a4 EDI: c1399370 EBP: cded9dbc ESP: cded9dbc
+ DS: 007b ES: 007b FS: 00d8 GS: 0033 SS: 0068
+CR0: 8005003b CR2: 0000004c CR3: 0f0c4000 CR4: 00000090
+DR0: 00000000 DR1: 00000000 DR2: 00000000 DR3: 00000000
+DR6: ffff0ff0 DR7: 00000400
+Process modprobe (pid: 881, ti=cded8000 task=cf094aa0 task.ti=cded8000)
+Stack:
+ cded9de0 d09471cb 00000000 c1399260 cf364014 00000000 c1399260 c1399254
+ d0949014 cded9df4 c118cd59 c1399260 d0949014 d0949014 cded9e08 c118ba47
+ c1399260 d0949014 c1399294 cded9e1c c118bb75 cded9e24 d0949014 00000000
+Call Trace:
+ [<d09471cb>] gpio_led_probe+0xba/0x203 [leds_gpio]
+ [<c118cd59>] platform_drv_probe+0x26/0x48
+ [<c118ba47>] driver_probe_device+0x75/0x15c
+ [<c118bb75>] __driver_attach+0x47/0x63
+ [<c118a727>] bus_for_each_dev+0x3c/0x66
+ [<c118b6f9>] driver_attach+0x14/0x16
+ [<c118bb2e>] ? driver_probe_device+0x15c/0x15c
+ [<c118b3d5>] bus_add_driver+0xbd/0x1bc
+ [<d08b4000>] ? 0xd08b3fff
+ [<d08b4000>] ? 0xd08b3fff
+ [<c118bffc>] driver_register+0x74/0xec
+ [<d08b4000>] ? 0xd08b3fff
+ [<c118c8e8>] platform_driver_register+0x38/0x3a
+ [<d08b400d>] gpio_led_driver_init+0xd/0x1000 [leds_gpio]
+ [<c100116c>] do_one_initcall+0x6b/0x10f
+ [<d08b4000>] ? 0xd08b3fff
+ [<c105e918>] load_module+0x1631/0x1907
+ [<c10975d6>] ? insert_vmalloc_vmlist+0x14/0x43
+ [<c1098d5b>] ? __vmalloc_node_range+0x13e/0x15f
+ [<c105ec50>] sys_init_module+0x62/0x77
+ [<c1257888>] syscall_call+0x7/0xb
+EIP: [<c11287d6>] __gpio_cansleep+0xe/0x1a SS:ESP 0068:cded9dbc
+CR2: 000000000000004c
+ ---[ end trace 5308fb20d2514822 ]---
+
+Signed-off-by: Timo Teräs <timo.teras@iki.f>
+Cc: Jingoo Han <jg1.han@samsung.com>
+Cc: Sachin Kamat <sachin.kamat@linaro.org>
+Cc: Raphael Assenat <raph@8d.com>
+Cc: Trent Piepho <tpiepho@freescale.com>
+Cc: Javier Martinez Canillas <javier.martinez@collabora.co.uk>
+Cc: Arnaud Patard <arnaud.patard@rtp-net.org>
+Cc: Ezequiel Garcia <ezequiel.garcia@free-electrons.com>
+---
+ drivers/leds/leds-gpio.c | 9 +++++----
+ 1 file changed, 5 insertions(+), 4 deletions(-)
+
+diff --git a/drivers/leds/leds-gpio.c b/drivers/leds/leds-gpio.c
+index a0d931b..b02b679 100644
+--- a/drivers/leds/leds-gpio.c
++++ b/drivers/leds/leds-gpio.c
+@@ -107,6 +107,10 @@ static int create_gpio_led(const struct gpio_led *template,
+ return 0;
+ }
+
++ ret = devm_gpio_request(parent, template->gpio, template->name);
++ if (ret < 0)
++ return ret;
++
+ led_dat->cdev.name = template->name;
+ led_dat->cdev.default_trigger = template->default_trigger;
+ led_dat->gpio = template->gpio;
+@@ -126,10 +130,7 @@ static int create_gpio_led(const struct gpio_led *template,
+ if (!template->retain_state_suspended)
+ led_dat->cdev.flags |= LED_CORE_SUSPENDRESUME;
+
+- ret = devm_gpio_request_one(parent, template->gpio,
+- (led_dat->active_low ^ state) ?
+- GPIOF_OUT_INIT_HIGH : GPIOF_OUT_INIT_LOW,
+- template->name);
++ ret = gpio_direction_output(led_dat->gpio, led_dat->active_low ^ state);
+ if (ret < 0)
+ return ret;
+
+--
+1.8.2.3
+
+