LKML Archive on lore.kernel.org help / color / mirror / Atom feed
From: Dave Young <dyoung@redhat.com> To: Peter Zijlstra <peterz@infradead.org> Cc: Baoquan He <bhe@redhat.com>, Borislav Petkov <bp@alien8.de>, j-nomura@ce.jp.nec.com, kasong@redhat.com, fanc.fnst@cn.fujitsu.com, x86@kernel.org, kexec@lists.infradead.org, linux-kernel@vger.kernel.org, hpa@zytor.com, tglx@linutronix.de Subject: Re: [PATCH v6 1/2] x86/kexec: Build identity mapping for EFI systab and ACPI tables Date: Tue, 14 May 2019 20:58:35 +0800 [thread overview] Message-ID: <20190514125835.GA29045@dhcp-128-65.nay.redhat.com> (raw) In-Reply-To: <20190514113826.GM2589@hirez.programming.kicks-ass.net> On 05/14/19 at 01:38pm, Peter Zijlstra wrote: > On Tue, May 14, 2019 at 04:48:41PM +0800, Dave Young wrote: > > > > I did some tests on the laptop, thing is: > > > 1. apply the 3 patches (two you posted + Boris's revert commit 52b922c3d49c) > > > on latest Linus master branch, everything works fine. > > > > > > 2. build and test the tip/next-merge-window branch, kernel hangs early > > > without output, (both 1st boot and kexec boot) > > > > Update about 2. It should be not early rsdp related, I got the boot log > > Since can not reproduce with Linus master branch it may have been fixed. > > Nothing was changed here since PTI. > > > [ 0.685374][ T1] rcu: Hierarchical SRCU implementation. > > [ 0.686414][ T1] general protection fault: 0000 [#1] SMP PTI > > [ 0.687328][ T1] CPU: 0 PID: 1 Comm: swapper/0 Not tainted 5.1.0-rc6+ #877 > > [ 0.687328][ T1] Hardware name: LENOVO 4236NUC/4236NUC, BIOS 83ET82WW (1.52 ) 06/04/2018 > > [ 0.687328][ T1] RIP: 0010:reserve_ds_buffers+0x34e/0x450 > > > [ 0.687328][ T1] Call Trace: > > [ 0.687328][ T1] ? hardlockup_detector_event_create+0x50/0x50 > > [ 0.687328][ T1] x86_reserve_hardware+0x173/0x180 > > [ 0.687328][ T1] x86_pmu_event_init+0x39/0x220 > > The DS buffers are special in that they're part of cpu_entrt_area. If > this comes apart it might mean your pagetables are dodgy. Hmm, it seems caused by some WIP branch patches, I suspect below: commit 124d6af5a5f559e516ed2c6ea857e889ed293b43 x86/paravirt: Standardize 'insn_buff' variable names The suspicious line is "per_cpu(insn_buff, cpu) = insn_buff;" I can help to test if need to try anything, eg. debug patch. I do not know anything of the pti and ds buffer logic, but below chunk make the next-merge-window branch booting fine on the laptop. --- diff --git a/arch/x86/events/intel/ds.c b/arch/x86/events/intel/ds.c index ad47f6415b17..fa254c576032 100644 --- a/arch/x86/events/intel/ds.c +++ b/arch/x86/events/intel/ds.c @@ -337,7 +337,7 @@ static int alloc_pebs_buffer(int cpu) struct debug_store *ds = hwev->ds; size_t bsiz = x86_pmu.pebs_buffer_size; int max, node = cpu_to_node(cpu); - void *buffer, *insn_buff, *cea; + void *buffer, *ibuff, *cea; if (!x86_pmu.pebs) return 0; @@ -351,12 +351,12 @@ static int alloc_pebs_buffer(int cpu) * buffer then. */ if (x86_pmu.intel_cap.pebs_format < 2) { - insn_buff = kzalloc_node(PEBS_FIXUP_SIZE, GFP_KERNEL, node); - if (!insn_buff) { + ibuff = kzalloc_node(PEBS_FIXUP_SIZE, GFP_KERNEL, node); + if (!ibuff) { dsfree_pages(buffer, bsiz); return -ENOMEM; } - per_cpu(insn_buff, cpu) = insn_buff; + per_cpu(insn_buff, cpu) = ibuff; } hwev->ds_pebs_vaddr = buffer; /* Update the cpu entry area mapping */
next prev parent reply other threads:[~2019-05-14 12:58 UTC|newest] Thread overview: 42+ messages / expand[flat|nested] mbox.gz Atom feed top 2019-04-24 9:29 [PATCH v5 0/2] x86/boot: Use efi_setup_data for searching RSDP on kexec-ed kernel Baoquan He 2019-04-24 9:29 ` [PATCH v5 1/2] x86/kexec: Build identity mapping for EFI systab and ACPI tables Baoquan He 2019-04-27 16:11 ` Borislav Petkov 2019-04-28 5:41 ` Baoquan He 2019-04-29 12:50 ` Borislav Petkov 2019-04-29 0:23 ` [PATCH v6 " Baoquan He 2019-04-29 13:55 ` Borislav Petkov 2019-04-29 14:16 ` Baoquan He 2019-05-13 1:43 ` Baoquan He 2019-05-13 7:07 ` Borislav Petkov 2019-05-13 7:32 ` Baoquan He 2019-05-13 7:50 ` Borislav Petkov 2019-05-13 8:02 ` Baoquan He 2019-05-15 5:17 ` Junichi Nomura 2019-05-15 6:58 ` Borislav Petkov 2019-05-15 7:09 ` Junichi Nomura 2019-05-21 9:02 ` Kairui Song 2019-05-21 10:43 ` Junichi Nomura 2019-05-21 18:09 ` Borislav Petkov 2019-05-28 2:49 ` Kairui Song 2019-06-06 19:20 ` Borislav Petkov 2019-05-13 8:06 ` Baoquan He 2019-05-14 3:22 ` Dave Young 2019-05-14 3:33 ` Baoquan He 2019-05-21 21:53 ` Dirk van der Merwe 2019-05-21 23:04 ` Borislav Petkov 2019-05-14 8:48 ` Dave Young 2019-05-14 11:18 ` Kairui Song 2019-05-14 11:38 ` Peter Zijlstra 2019-05-14 12:58 ` Dave Young [this message] 2019-05-14 13:54 ` Peter Zijlstra 2019-05-14 14:09 ` Ingo Molnar 2019-05-15 1:08 ` Dave Young 2019-05-15 6:43 ` Junichi Nomura 2019-05-17 13:41 ` Borislav Petkov 2019-05-17 13:50 ` [PATCH] x86/boot: Call get_rsdp_addr() after console_init() Borislav Petkov 2019-05-21 9:28 ` Baoquan He 2019-06-06 19:22 ` [tip:x86/boot] x86/kexec: Add the EFI system tables and ACPI tables to the ident map tip-bot for Kairui Song 2019-04-24 9:29 ` [PATCH v5 2/2] x86/boot: Use efi_setup_data for searching RSDP on kexec-ed kernels Baoquan He 2019-04-24 9:33 ` Baoquan He 2019-04-24 9:38 ` [PATCH v5 0/2] x86/boot: Use efi_setup_data for searching RSDP on kexec-ed kernel Borislav Petkov 2019-04-24 10:00 ` Baoquan He
Reply instructions: You may reply publicly to this message via plain-text email using any one of the following methods: * Save the following mbox file, import it into your mail client, and reply-to-all from there: mbox Avoid top-posting and favor interleaved quoting: https://en.wikipedia.org/wiki/Posting_style#Interleaved_style * Reply using the --to, --cc, and --in-reply-to switches of git-send-email(1): git send-email \ --in-reply-to=20190514125835.GA29045@dhcp-128-65.nay.redhat.com \ --to=dyoung@redhat.com \ --cc=bhe@redhat.com \ --cc=bp@alien8.de \ --cc=fanc.fnst@cn.fujitsu.com \ --cc=hpa@zytor.com \ --cc=j-nomura@ce.jp.nec.com \ --cc=kasong@redhat.com \ --cc=kexec@lists.infradead.org \ --cc=linux-kernel@vger.kernel.org \ --cc=peterz@infradead.org \ --cc=tglx@linutronix.de \ --cc=x86@kernel.org \ /path/to/YOUR_REPLY https://kernel.org/pub/software/scm/git/docs/git-send-email.html * If your mail client supports setting the In-Reply-To header via mailto: links, try the mailto: linkBe sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions for how to clone and mirror all data and code used for this inbox; as well as URLs for NNTP newsgroup(s).