Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]
Groups > linux.kernel > #1613835 > unrolled thread
| Started by | Juergen Gross <jgross@suse.com> |
|---|---|
| First post | 2017-03-31 12:20 +0200 |
| Last post | 2017-04-04 14:00 +0200 |
| Articles | 4 — 3 participants |
Back to article view | Back to linux.kernel
[PATCH v2] xen,kdump: handle pv domain in paddr_vmcoreinfo_note() Juergen Gross <jgross@suse.com> - 2017-03-31 12:20 +0200
Re: [PATCH v2] xen,kdump: handle pv domain in paddr_vmcoreinfo_note() Boris Ostrovsky <boris.ostrovsky@oracle.com> - 2017-03-31 16:10 +0200
Re: [Xen-devel] [PATCH v2] xen, kdump: handle pv domain in paddr_vmcoreinfo_note() Daniel Kiper <dkiper@net-space.pl> - 2017-04-03 14:50 +0200
Re: [Xen-devel] [PATCH v2] xen, kdump: handle pv domain in paddr_vmcoreinfo_note() Juergen Gross <jgross@suse.com> - 2017-04-04 14:00 +0200
| From | Juergen Gross <jgross@suse.com> |
|---|---|
| Date | 2017-03-31 12:20 +0200 |
| Subject | [PATCH v2] xen,kdump: handle pv domain in paddr_vmcoreinfo_note() |
| Message-ID | <tr1OV-3i8-1@gated-at.bofh.it> |
For kdump to work correctly it needs the physical address of
vmcoreinfo_note. When running as dom0 this means the virtual address
has to be translated to the related machine address.
paddr_vmcoreinfo_note() is meant to do the translation via
__pa_symbol() only, but being attributed "weak" it can be replaced
easily in Xen case.
Signed-off-by: Juergen Gross <jgross@suse.com>
---
Changes in V2:
- use __pa_symbol() (Boris Ostrovsky)
- remove unneeded casts (Jan Beulich)
This patch needs to be rebased on top of Vitaly's series to split
pv- and hvm-code. I'll do this as soon as his series is in the Xen
tree in its final form.
---
arch/x86/xen/mmu.c | 13 +++++++++++++
1 file changed, 13 insertions(+)
diff --git a/arch/x86/xen/mmu.c b/arch/x86/xen/mmu.c
index 37cb5aa..33ab96c 100644
--- a/arch/x86/xen/mmu.c
+++ b/arch/x86/xen/mmu.c
@@ -49,6 +49,9 @@
#include <linux/memblock.h>
#include <linux/seq_file.h>
#include <linux/crash_dump.h>
+#ifdef CONFIG_KEXEC_CORE
+#include <linux/kexec.h>
+#endif
#include <trace/events/xen.h>
@@ -2903,3 +2906,13 @@ int xen_unmap_domain_gfn_range(struct vm_area_struct *vma,
return -EINVAL;
}
EXPORT_SYMBOL_GPL(xen_unmap_domain_gfn_range);
+
+#ifdef CONFIG_KEXEC_CORE
+phys_addr_t paddr_vmcoreinfo_note(void)
+{
+ if (xen_pv_domain())
+ return virt_to_machine(&vmcoreinfo_note).maddr;
+ else
+ return __pa_symbol(&vmcoreinfo_note);
+}
+#endif /* CONFIG_KEXEC_CORE */
--
2.10.2
[toc] | [next] | [standalone]
| From | Boris Ostrovsky <boris.ostrovsky@oracle.com> |
|---|---|
| Date | 2017-03-31 16:10 +0200 |
| Message-ID | <tr5pv-5Cr-5@gated-at.bofh.it> |
| In reply to | #1613835 |
On 03/31/2017 06:14 AM, Juergen Gross wrote: > For kdump to work correctly it needs the physical address of > vmcoreinfo_note. When running as dom0 this means the virtual address > has to be translated to the related machine address. > > paddr_vmcoreinfo_note() is meant to do the translation via > __pa_symbol() only, but being attributed "weak" it can be replaced > easily in Xen case. > > Signed-off-by: Juergen Gross <jgross@suse.com> Similar to Jan's concern, if bare-metal x86 people decide to have their own paddr_vmcoreinfo_note() (and they usually build with !CONFIG_XEN) we will have to update this again. I suppose we can deal with that if/when it happens since we will discover this immediately. Reviewed-by: Boris Ostrovsky <boris.ostrovsky@oracle.com>
[toc] | [prev] | [next] | [standalone]
| From | Daniel Kiper <dkiper@net-space.pl> |
|---|---|
| Date | 2017-04-03 14:50 +0200 |
| Subject | Re: [Xen-devel] [PATCH v2] xen, kdump: handle pv domain in paddr_vmcoreinfo_note() |
| Message-ID | <ts9AL-6V6-29@gated-at.bofh.it> |
| In reply to | #1613835 |
On Fri, Mar 31, 2017 at 12:14:38PM +0200, Juergen Gross wrote: > For kdump to work correctly it needs the physical address of > vmcoreinfo_note. When running as dom0 this means the virtual address > has to be translated to the related machine address. > > paddr_vmcoreinfo_note() is meant to do the translation via > __pa_symbol() only, but being attributed "weak" it can be replaced > easily in Xen case. > > Signed-off-by: Juergen Gross <jgross@suse.com> Have you tested this patch with latest crash tool? Do dom0 and Xen hypervisor analysis work without any issue (at least basic commands like dmesg, bt, ps, etc.)? If yes for both you can add: Reviewed-by: Daniel Kiper <daniel.kiper@oracle.com> Daniel
[toc] | [prev] | [next] | [standalone]
| From | Juergen Gross <jgross@suse.com> |
|---|---|
| Date | 2017-04-04 14:00 +0200 |
| Subject | Re: [Xen-devel] [PATCH v2] xen, kdump: handle pv domain in paddr_vmcoreinfo_note() |
| Message-ID | <tsvhU-4mH-11@gated-at.bofh.it> |
| In reply to | #1615178 |
On 03/04/17 14:42, Daniel Kiper wrote: > On Fri, Mar 31, 2017 at 12:14:38PM +0200, Juergen Gross wrote: >> For kdump to work correctly it needs the physical address of >> vmcoreinfo_note. When running as dom0 this means the virtual address >> has to be translated to the related machine address. >> >> paddr_vmcoreinfo_note() is meant to do the translation via >> __pa_symbol() only, but being attributed "weak" it can be replaced >> easily in Xen case. >> >> Signed-off-by: Juergen Gross <jgross@suse.com> > > Have you tested this patch with latest crash tool? Do dom0 and Xen > hypervisor analysis work without any issue (at least basic commands > like dmesg, bt, ps, etc.)? If yes for both you can add: > > Reviewed-by: Daniel Kiper <daniel.kiper@oracle.com> This patch isn't for dump analysis, but for dump creation. Petr has verified that the dump is in the expected format. Please ask Petr for further details, e.g. user side modifications being necessary. Juergen
[toc] | [prev] | [standalone]
Back to top | Article view | linux.kernel
csiph-web