From: Greg Kroah-Hartman Date: Sun, 8 Dec 2013 19:56:58 +0000 (-0800) Subject: 3.10-stable patches X-Git-Tag: v3.4.74~36 X-Git-Url: http://git.ipfire.org/?a=commitdiff_plain;h=1b86b58a11537c510d884b24bb8561ca7fb418f3;p=thirdparty%2Fkernel%2Fstable-queue.git 3.10-stable patches added patches: arm-at91-sama5d3-reduce-twi-internal-clock-frequency.patch arm-fix-booting-low-vectors-machines.patch arm-footbridge-fix-ebsa285-leds.patch arm-footbridge-fix-vga-initialisation.patch arm-mvebu-re-enable-pcie-on-armada-370-db.patch arm-mvebu-use-the-virtual-cpu-registers-to-access-coherency-registers.patch --- diff --git a/queue-3.10/arm-at91-sama5d3-reduce-twi-internal-clock-frequency.patch b/queue-3.10/arm-at91-sama5d3-reduce-twi-internal-clock-frequency.patch new file mode 100644 index 00000000000..b7f7af5e23f --- /dev/null +++ b/queue-3.10/arm-at91-sama5d3-reduce-twi-internal-clock-frequency.patch @@ -0,0 +1,52 @@ +From 58e7b1d5826ac6a64b1101d8a70162bc084a7d1e Mon Sep 17 00:00:00 2001 +From: Ludovic Desroches +Date: Fri, 22 Nov 2013 17:08:43 +0100 +Subject: ARM: at91: sama5d3: reduce TWI internal clock frequency + +From: Ludovic Desroches + +commit 58e7b1d5826ac6a64b1101d8a70162bc084a7d1e upstream. + +With some devices, transfer hangs during I2C frame transmission. This issue +disappears when reducing the internal frequency of the TWI IP. Even if it is +indicated that internal clock max frequency is 66MHz, it seems we have +oversampling on I2C signals making TWI believe that a transfer in progress +is done. + +This fix has no impact on the I2C bus frequency. + +Signed-off-by: Ludovic Desroches +Acked-by: Wolfram Sang +Acked-by: Jean-Christophe PLAGNIOL-VILLARD +Signed-off-by: Nicolas Ferre +Signed-off-by: Greg Kroah-Hartman + +--- + arch/arm/mach-at91/sama5d3.c | 6 +++--- + 1 file changed, 3 insertions(+), 3 deletions(-) + +--- a/arch/arm/mach-at91/sama5d3.c ++++ b/arch/arm/mach-at91/sama5d3.c +@@ -95,19 +95,19 @@ static struct clk twi0_clk = { + .name = "twi0_clk", + .pid = SAMA5D3_ID_TWI0, + .type = CLK_TYPE_PERIPHERAL, +- .div = AT91_PMC_PCR_DIV2, ++ .div = AT91_PMC_PCR_DIV8, + }; + static struct clk twi1_clk = { + .name = "twi1_clk", + .pid = SAMA5D3_ID_TWI1, + .type = CLK_TYPE_PERIPHERAL, +- .div = AT91_PMC_PCR_DIV2, ++ .div = AT91_PMC_PCR_DIV8, + }; + static struct clk twi2_clk = { + .name = "twi2_clk", + .pid = SAMA5D3_ID_TWI2, + .type = CLK_TYPE_PERIPHERAL, +- .div = AT91_PMC_PCR_DIV2, ++ .div = AT91_PMC_PCR_DIV8, + }; + static struct clk mmc0_clk = { + .name = "mci0_clk", diff --git a/queue-3.10/arm-fix-booting-low-vectors-machines.patch b/queue-3.10/arm-fix-booting-low-vectors-machines.patch new file mode 100644 index 00000000000..1c2ae8aed54 --- /dev/null +++ b/queue-3.10/arm-fix-booting-low-vectors-machines.patch @@ -0,0 +1,59 @@ +From d8aa712c30148ba26fd89a5dc14de95d4c375184 Mon Sep 17 00:00:00 2001 +From: Russell King +Date: Thu, 28 Nov 2013 21:43:40 +0000 +Subject: ARM: fix booting low-vectors machines + +From: Russell King + +commit d8aa712c30148ba26fd89a5dc14de95d4c375184 upstream. + +Commit f6f91b0d9fd9 (ARM: allow kuser helpers to be removed from the +vector page) required two pages for the vectors code. Although the +code setting up the initial page tables was updated, the code which +allocates page tables for new processes wasn't, neither was the code +which tears down the mappings. Fix this. + +Fixes: f6f91b0d9fd9 ("ARM: allow kuser helpers to be removed from the vector page") +Signed-off-by: Russell King +Signed-off-by: Greg Kroah-Hartman + +--- + arch/arm/include/asm/pgtable.h | 2 +- + arch/arm/mm/mmap.c | 2 +- + arch/arm/mm/pgd.c | 3 ++- + 3 files changed, 4 insertions(+), 3 deletions(-) + +--- a/arch/arm/include/asm/pgtable.h ++++ b/arch/arm/include/asm/pgtable.h +@@ -58,7 +58,7 @@ extern void __pgd_error(const char *file + * mapping to be mapped at. This is particularly important for + * non-high vector CPUs. + */ +-#define FIRST_USER_ADDRESS PAGE_SIZE ++#define FIRST_USER_ADDRESS (PAGE_SIZE * 2) + + /* + * Use TASK_SIZE as the ceiling argument for free_pgtables() and +--- a/arch/arm/mm/mmap.c ++++ b/arch/arm/mm/mmap.c +@@ -146,7 +146,7 @@ arch_get_unmapped_area_topdown(struct fi + + info.flags = VM_UNMAPPED_AREA_TOPDOWN; + info.length = len; +- info.low_limit = PAGE_SIZE; ++ info.low_limit = FIRST_USER_ADDRESS; + info.high_limit = mm->mmap_base; + info.align_mask = do_align ? (PAGE_MASK & (SHMLBA - 1)) : 0; + info.align_offset = pgoff << PAGE_SHIFT; +--- a/arch/arm/mm/pgd.c ++++ b/arch/arm/mm/pgd.c +@@ -87,7 +87,8 @@ pgd_t *pgd_alloc(struct mm_struct *mm) + init_pud = pud_offset(init_pgd, 0); + init_pmd = pmd_offset(init_pud, 0); + init_pte = pte_offset_map(init_pmd, 0); +- set_pte_ext(new_pte, *init_pte, 0); ++ set_pte_ext(new_pte + 0, init_pte[0], 0); ++ set_pte_ext(new_pte + 1, init_pte[1], 0); + pte_unmap(init_pte); + pte_unmap(new_pte); + } diff --git a/queue-3.10/arm-footbridge-fix-ebsa285-leds.patch b/queue-3.10/arm-footbridge-fix-ebsa285-leds.patch new file mode 100644 index 00000000000..1d1e5e89a01 --- /dev/null +++ b/queue-3.10/arm-footbridge-fix-ebsa285-leds.patch @@ -0,0 +1,77 @@ +From 67130c5464f50428aea0b4526a6729d61f9a1d53 Mon Sep 17 00:00:00 2001 +From: Russell King +Date: Fri, 29 Nov 2013 00:54:38 +0000 +Subject: ARM: footbridge: fix EBSA285 LEDs + +From: Russell King + +commit 67130c5464f50428aea0b4526a6729d61f9a1d53 upstream. + +- The LEDs register is write-only: it can't be read-modify-written. +- The LEDs are write-1-for-off not 0. +- The check for the platform was inverted. + +Fixes: cf6856d693dd ("ARM: mach-footbridge: retire custom LED code") +Signed-off-by: Russell King +Signed-off-by: Greg Kroah-Hartman + +--- + arch/arm/mach-footbridge/ebsa285.c | 22 +++++++++++++--------- + 1 file changed, 13 insertions(+), 9 deletions(-) + +--- a/arch/arm/mach-footbridge/ebsa285.c ++++ b/arch/arm/mach-footbridge/ebsa285.c +@@ -30,21 +30,24 @@ static const struct { + const char *name; + const char *trigger; + } ebsa285_leds[] = { +- { "ebsa285:amber", "heartbeat", }, +- { "ebsa285:green", "cpu0", }, ++ { "ebsa285:amber", "cpu0", }, ++ { "ebsa285:green", "heartbeat", }, + { "ebsa285:red",}, + }; + ++static unsigned char hw_led_state; ++ + static void ebsa285_led_set(struct led_classdev *cdev, + enum led_brightness b) + { + struct ebsa285_led *led = container_of(cdev, + struct ebsa285_led, cdev); + +- if (b != LED_OFF) +- *XBUS_LEDS |= led->mask; ++ if (b == LED_OFF) ++ hw_led_state |= led->mask; + else +- *XBUS_LEDS &= ~led->mask; ++ hw_led_state &= ~led->mask; ++ *XBUS_LEDS = hw_led_state; + } + + static enum led_brightness ebsa285_led_get(struct led_classdev *cdev) +@@ -52,18 +55,19 @@ static enum led_brightness ebsa285_led_g + struct ebsa285_led *led = container_of(cdev, + struct ebsa285_led, cdev); + +- return (*XBUS_LEDS & led->mask) ? LED_FULL : LED_OFF; ++ return hw_led_state & led->mask ? LED_OFF : LED_FULL; + } + + static int __init ebsa285_leds_init(void) + { + int i; + +- if (machine_is_ebsa285()) ++ if (!machine_is_ebsa285()) + return -ENODEV; + +- /* 3 LEDS All ON */ +- *XBUS_LEDS |= XBUS_LED_AMBER | XBUS_LED_GREEN | XBUS_LED_RED; ++ /* 3 LEDS all off */ ++ hw_led_state = XBUS_LED_AMBER | XBUS_LED_GREEN | XBUS_LED_RED; ++ *XBUS_LEDS = hw_led_state; + + for (i = 0; i < ARRAY_SIZE(ebsa285_leds); i++) { + struct ebsa285_led *led; diff --git a/queue-3.10/arm-footbridge-fix-vga-initialisation.patch b/queue-3.10/arm-footbridge-fix-vga-initialisation.patch new file mode 100644 index 00000000000..c472bf0d7f4 --- /dev/null +++ b/queue-3.10/arm-footbridge-fix-vga-initialisation.patch @@ -0,0 +1,77 @@ +From 43659222e7a0113912ed02f6b2231550b3e471ac Mon Sep 17 00:00:00 2001 +From: Russell King +Date: Thu, 28 Nov 2013 21:55:41 +0000 +Subject: ARM: footbridge: fix VGA initialisation + +From: Russell King + +commit 43659222e7a0113912ed02f6b2231550b3e471ac upstream. + +It's no good setting vga_base after the VGA console has been +initialised, because if we do that we get this: + +Unable to handle kernel paging request at virtual address 000b8000 +pgd = c0004000 +[000b8000] *pgd=07ffc831, *pte=00000000, *ppte=00000000 +0Internal error: Oops: 5017 [#1] ARM +Modules linked in: +CPU: 0 PID: 0 Comm: swapper Not tainted 3.12.0+ #49 +task: c03e2974 ti: c03d8000 task.ti: c03d8000 +PC is at vgacon_startup+0x258/0x39c +LR is at request_resource+0x10/0x1c +pc : [] lr : [] psr: 60000053 +sp : c03d9f68 ip : 000b8000 fp : c03d9f8c +r10: 000055aa r9 : 4401a103 r8 : ffffaa55 +r7 : c03e357c r6 : c051b460 r5 : 000000ff r4 : 000c0000 +r3 : 000b8000 r2 : c03e0514 r1 : 00000000 r0 : c0304971 +Flags: nZCv IRQs on FIQs off Mode SVC_32 ISA ARM Segment kernel + +which is an access to the 0xb8000 without the PCI offset required to +make it work. + +Fixes: cc22b4c18540 ("ARM: set vga memory base at run-time") +Signed-off-by: Russell King +Signed-off-by: Greg Kroah-Hartman + +--- + arch/arm/mach-footbridge/common.c | 3 +++ + arch/arm/mach-footbridge/dc21285.c | 2 -- + 2 files changed, 3 insertions(+), 2 deletions(-) + +--- a/arch/arm/mach-footbridge/common.c ++++ b/arch/arm/mach-footbridge/common.c +@@ -15,6 +15,7 @@ + #include + #include + #include ++#include