Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]
Groups > linux.kernel > #1260073 > unrolled thread
| Started by | Stephen Rothwell <sfr@canb.auug.org.au> |
|---|---|
| First post | 2015-11-01 01:00 +0100 |
| Last post | 2015-11-02 11:40 +0100 |
| Articles | 2 — 2 participants |
Back to article view | Back to linux.kernel
linux-next: manual merge of the arm64 tree with Linus' tree Stephen Rothwell <sfr@canb.auug.org.au> - 2015-11-01 01:00 +0100
Re: linux-next: manual merge of the arm64 tree with Linus' tree Catalin Marinas <catalin.marinas@arm.com> - 2015-11-02 11:40 +0100
| From | Stephen Rothwell <sfr@canb.auug.org.au> |
|---|---|
| Date | 2015-11-01 01:00 +0100 |
| Subject | linux-next: manual merge of the arm64 tree with Linus' tree |
| Message-ID | <qpOdY-QP-9@gated-at.bofh.it> |
Hi Catalin,
Today's linux-next merge of the arm64 tree got a conflict in:
arch/arm64/kernel/suspend.c
between commit:
e13d918a19a7 ("arm64: kernel: fix tcr_el1.t0sz restore on systems with extended idmap")
from Linus' tree and commit:
8e63d3887669 ("arm64: flush: use local TLB and I-cache invalidation")
from the arm64 tree.
I fixed it up (I think - see below) and can carry the fix as necessary
(no action is required).
--
Cheers,
Stephen Rothwell sfr@canb.auug.org.au
diff --cc arch/arm64/kernel/suspend.c
index 44ca4143b013,3c5e4e6dcf68..000000000000
--- a/arch/arm64/kernel/suspend.c
+++ b/arch/arm64/kernel/suspend.c
@@@ -80,21 -80,17 +80,21 @@@ int cpu_suspend(unsigned long arg, int
if (ret == 0) {
/*
* We are resuming from reset with TTBR0_EL1 set to the
- * idmap to enable the MMU; restore the active_mm mappings in
- * TTBR0_EL1 unless the active_mm == &init_mm, in which case
- * the thread entered cpu_suspend with TTBR0_EL1 set to
- * reserved TTBR0 page tables and should be restored as such.
+ * idmap to enable the MMU; set the TTBR0 to the reserved
+ * page tables to prevent speculative TLB allocations, flush
+ * the local tlb and set the default tcr_el1.t0sz so that
+ * the TTBR0 address space set-up is properly restored.
+ * If the current active_mm != &init_mm we entered cpu_suspend
+ * with mappings in TTBR0 that must be restored, so we switch
+ * them back to complete the address space configuration
+ * restoration before returning.
*/
- if (mm == &init_mm)
- cpu_set_reserved_ttbr0();
- else
- cpu_switch_mm(mm->pgd, mm);
-
+ cpu_set_reserved_ttbr0();
- flush_tlb_all();
+ local_flush_tlb_all();
+ cpu_set_default_tcr_t0sz();
+
+ if (mm != &init_mm)
+ cpu_switch_mm(mm->pgd, mm);
/*
* Restore per-cpu offset before any kernel
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/
[toc] | [next] | [standalone]
| From | Catalin Marinas <catalin.marinas@arm.com> |
|---|---|
| Date | 2015-11-02 11:40 +0100 |
| Message-ID | <qqkGR-4bJ-11@gated-at.bofh.it> |
| In reply to | #1260073 |
On Sun, Nov 01, 2015 at 10:53:27AM +1100, Stephen Rothwell wrote:
> Today's linux-next merge of the arm64 tree got a conflict in:
>
> arch/arm64/kernel/suspend.c
>
> between commit:
>
> e13d918a19a7 ("arm64: kernel: fix tcr_el1.t0sz restore on systems with extended idmap")
>
> from Linus' tree and commit:
>
> 8e63d3887669 ("arm64: flush: use local TLB and I-cache invalidation")
>
> from the arm64 tree.
>
> I fixed it up (I think - see below) and can carry the fix as necessary
> (no action is required).
The fix-up is fine. Thanks.
--
Catalin
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/
[toc] | [prev] | [standalone]
Back to top | Article view | linux.kernel
csiph-web