[Patch RESEND] x86/paravirt: remove unused operation

2015-09-14 Thread Juergen Gross
Remove the paravirt operation "get_tsc_khz" as it is used nowhere. Signed-off-by: Juergen Gross Acked-by: Rusty Russell --- arch/x86/include/asm/paravirt_types.h | 1 - 1 file changed, 1 deletion(-) diff --git a/arch/x86/include/asm/paravirt_types.h b/arch/x86/include/asm/paravi

Re: Hibernate resume bug around 3,18-rc2 - Full PAT support

2015-11-24 Thread Juergen Gross
On 24/11/15 23:46, Luis R. Rodriguez wrote: > On Mon, Nov 23, 2015 at 03:19:16PM +0100, Juergen Gross wrote: >> On 23/11/15 15:11, vas...@iit.demokritos.gr wrote: >>> Ok I will send the .config when I get back home. I have all kernels I >>> build in .deb archive. The

Re: [PATCH] target: xen-scsiback: Return proper -Exx instead of -1.

2015-11-25 Thread Juergen Gross
On 25/11/15 20:24, Konrad Rzeszutek Wilk wrote: > We could return EINVAL but EBUSY (or EALREADY?)is more appropiate. > > CC: jgr...@suse.com > Signed-off-by: Konrad Rzeszutek Wilk While it doesn't really matter it's cleaner. Reviewed-by: Juergen Gross > --- > dr

Re: [Patch V4 0/3] xen, usb: support pvUSB frontend driver

2015-07-19 Thread Juergen Gross
Ping? On 06/23/2015 08:53 AM, Juergen Gross wrote: This series adds XEN guest pvUSB support. With pvUSB it is possible to use physical USB devices from a XEN domain. The support consists of a frontend in form of a virtual hcd driver in the unprivileged domU passing I/O-requests to the backend

Re: [Xen-devel] [PATCH] xen: release lock occasionally during ballooning

2015-07-20 Thread Juergen Gross
On 07/20/2015 12:15 PM, David Vrabel wrote: On 10/07/15 15:42, Juergen Gross wrote: When dom0 is being ballooned balloon_process() will hold the balloon mutex until it is finished. This will block e.g. creation of new domains as the device backends for the new domain need some autoballooned

[Patch V2] xen: release lock occasionally during ballooning

2015-07-20 Thread Juergen Gross
during ballooning. Adjust the comment above balloon_process() regarding multiple instances of balloon_process(). Instead of open coding it, just use cond_resched(). Signed-off-by: Juergen Gross --- drivers/xen/balloon.c | 19 +++ 1 file changed, 15 insertions(+), 4 deletions

Re: [Patch V2] xen: release lock occasionally during ballooning

2015-07-20 Thread Juergen Gross
Please ignore, forgot stg refresh... Juergen On 07/20/2015 01:46 PM, Juergen Gross wrote: When dom0 is being ballooned balloon_process() will hold the balloon mutex until it is finished. This will block e.g. creation of new domains as the device backends for the new domain need some

[Patch V2] xen: release lock occasionally during ballooning

2015-07-20 Thread Juergen Gross
during ballooning. Adjust the comment above balloon_process() regarding multiple instances of balloon_process(). Instead of open coding it, just use cond_resched(). Signed-off-by: Juergen Gross --- drivers/xen/balloon.c | 15 +++ 1 file changed, 7 insertions(+), 8 deletions(-) diff

Re: [Patch V6 12/16] mm: provide early_memremap_ro to establish read-only mapping

2015-07-20 Thread Juergen Gross
Hi MM maintainers, this patch is the last requiring an ack for the series to go in. Could you please comment? Juergen On 07/17/2015 06:51 AM, Juergen Gross wrote: During early boot as Xen pv domain the kernel needs to map some page tables supplied by the hypervisor read only. This is needed

Re: [PATCH 3/3] xen-scsiback: fix license ident used in MODULE_LICENSE

2016-01-22 Thread Juergen Gross
On 22/01/16 13:34, Wei Liu wrote: > The comment at the beginning of the file is the canonical source of > licenses for this module. Currently it contains GPL and MIT license. > Fix the code to reflect the reality. > > Signed-off-by: Wei Liu Acked-by: Juergen Gross > ---

Re: p2m stuff and crash tool

2016-02-17 Thread Juergen Gross
On 17/02/16 14:59, Daniel Kiper wrote: > On Tue, Feb 16, 2016 at 01:55:33PM +0100, Juergen Gross wrote: >> Hi Daniel, >> >> On 16/02/16 12:35, Daniel Kiper wrote: >>> Hey Juergen, > > [...] > >>> After that I decided to take a look at Linux ke

Re: p2m stuff and crash tool

2016-02-17 Thread Juergen Gross
On 17/02/16 15:52, Daniel Kiper wrote: > On Wed, Feb 17, 2016 at 03:27:01PM +0100, Juergen Gross wrote: >> On 17/02/16 14:59, Daniel Kiper wrote: >>> On Tue, Feb 16, 2016 at 01:55:33PM +0100, Juergen Gross wrote: >>>> Hi Daniel, >>>> >>>> On

Re: [Xen-devel] [PATCH 1/9] x86/boot: enumerate documentation for the x86 hardware_subarch

2016-02-19 Thread Juergen Gross
On 19/02/16 14:08, Luis R. Rodriguez wrote: > Although hardware_subarch has been in place since the x86 boot > protocol 2.07 it hasn't been used much. Enumerate current possible > values to avoid misuses and help with semantics later at boot > time should this be used further. > > Cc: Andy Shevche

Re: [Xen-devel] [PATCH 8/9] x86/rtc: replace paravirt_enabled() check with subarch check

2016-02-19 Thread Juergen Gross
On 19/02/16 14:08, Luis R. Rodriguez wrote: > The current check is a super long winded way of asking if this > is on lguest. The flags is used for legacy features, this is What about Xen pv-domU? I wouldn't expect those to have PV_SUPPORTED_RTC set. Juergen > likely inspired by the ACPI IA-PC b

Re: [PATCH 2/2] xen/scsiback: avoid warnings when adding multiple LUNs to a domain

2016-02-08 Thread Juergen Gross
On 05/02/16 18:24, Boris Ostrovsky wrote: > > > On 02/05/2016 11:59 AM, Juergen Gross wrote: >> On 05/02/16 16:50, Boris Ostrovsky wrote: >>> >>> On 02/05/2016 08:21 AM, Juergen Gross wrote: >>>> When adding more than one LUN to a frontend a warning f

[PATCH v2 2/2] xen/scsiback: avoid warnings when adding multiple LUNs to a domain

2016-02-08 Thread Juergen Gross
for a third time, factor it out into a function. This in turn leads to a more or less complete rewrite of scsiback_del_translation_entry() which will now return a proper error code in case of failure. Signed-off-by: Juergen Gross Cc: sta...@vger.kernel.org --- v2: scsiback_del_translation_entry

[PATCH v2 1/2] xen/scsiback: correct frontend counting

2016-02-08 Thread Juergen Gross
When adding a new frontend to xen-scsiback don't decrement the number of active frontends in case of no error. Doing so results in a failure when trying to remove the xen-pvscsi nexus even if no domain is using it. Signed-off-by: Juergen Gross Reviewed-by: Boris Ostrovsky Cc

[PATCH v2 0/2] xen/scsiback: correct two issues

2016-02-08 Thread Juergen Gross
Correct two issues in the Xen pvscsi backend. Changes in V2: - Patch 2: scsiback_del_translation_entry() returns error code instead of 1 (Boris Ostrovsky) Juergen Gross (2): xen/scsiback: correct frontend counting xen/scsiback: avoid warnings when adding multiple LUNs to a domain

Re: [Xen-devel] [PATCH v2 2/2] xen/scsiback: avoid warnings when adding multiple LUNs to a domain

2016-02-08 Thread Juergen Gross
On 08/02/16 17:46, David Vrabel wrote: > On 08/02/16 14:30, Juergen Gross wrote: >> When adding more than one LUN to a frontend a warning for a failed >> assignment is issued in dom0 for each already existing LUN. Avoid this >> warning by checking for a LUN already exist

Re: p2m stuff and crash tool

2016-02-16 Thread Juergen Gross
Hi Daniel, On 16/02/16 12:35, Daniel Kiper wrote: > Hey Juergen, > > As I saw you are strongly playing with p2m stuff, so, > I hope that you can enlighten me a bit in that area. Yes, the p2m stuff is always fun. :-) > OVM, Oracle product, uses as dom0 kernel Linux 3.8.13 > (yep, I know this is

Re: [PATCH V3 2/8] xen: Delay remapping memory of pv-domain

2014-11-19 Thread Juergen Gross
On 11/19/2014 08:43 PM, Konrad Rzeszutek Wilk wrote: On Fri, Nov 14, 2014 at 06:14:06PM +0100, Juergen Gross wrote: On 11/14/2014 05:47 PM, Konrad Rzeszutek Wilk wrote: On Fri, Nov 14, 2014 at 05:53:19AM +0100, Juergen Gross wrote: On 11/13/2014 08:56 PM, Konrad Rzeszutek Wilk wrote

Re: [PATCH V3 0/8] xen: Switch to virtual mapped linear p2m list

2014-11-19 Thread Juergen Gross
On 11/19/2014 09:41 PM, Konrad Rzeszutek Wilk wrote: On Tue, Nov 11, 2014 at 06:43:38AM +0100, Juergen Gross wrote: Paravirtualized kernels running on Xen use a three level tree for translation of guest specific physical addresses to machine global addresses. This p2m tree is used for

Re: [PATCH V3 2/8] xen: Delay remapping memory of pv-domain

2014-11-12 Thread Juergen Gross
On 11/12/2014 10:45 PM, Konrad Rzeszutek Wilk wrote: On Tue, Nov 11, 2014 at 06:43:40AM +0100, Juergen Gross wrote: diff --git a/arch/x86/xen/mmu.c b/arch/x86/xen/mmu.c index a8a1a3d..d3e492b 100644 --- a/arch/x86/xen/mmu.c +++ b/arch/x86/xen/mmu.c @@ -1223,6 +1223,10 @@ static void __init

Re: [PATCH V3 4/8] xen: Delay invalidating extra memory

2014-11-12 Thread Juergen Gross
On 11/12/2014 11:10 PM, Konrad Rzeszutek Wilk wrote: @@ -376,12 +374,14 @@ void __init xen_build_dynamic_phys_to_machine(void) unsigned long max_pfn; unsigned long pfn; -if (xen_feature(XENFEAT_auto_translated_physmap)) + if (xen_feature(XENFEAT_auto_translated_phys

Re: [PATCH V3 5/8] x86: Introduce function to get pmd entry pointer

2014-11-12 Thread Juergen Gross
On 11/12/2014 11:12 PM, Konrad Rzeszutek Wilk wrote: On Tue, Nov 11, 2014 at 06:43:43AM +0100, Juergen Gross wrote: Introduces lookup_pmd_address() to get the address of the pmd entry related to a virtual address in the current address space. This function is needed for support of a virtual

Re: [PATCH V3 6/8] xen: Hide get_phys_to_machine() to be able to tune common path

2014-11-13 Thread Juergen Gross
On 11/12/2014 11:18 PM, Konrad Rzeszutek Wilk wrote: On Tue, Nov 11, 2014 at 06:43:44AM +0100, Juergen Gross wrote: Today get_phys_to_machine() is always called when the mfn for a pfn is to be obtained. Add a wrapper __pfn_to_mfn() as inline function to be able to avoid calling

Re: [Xen-devel] [PATCH V3 7/8] xen: switch to linear virtual mapped sparse p2m list

2014-11-13 Thread Juergen Gross
On 11/11/2014 06:47 PM, David Vrabel wrote: On 11/11/14 05:43, Juergen Gross wrote: At start of the day the Xen hypervisor presents a contiguous mfn list to a pv-domain. In order to support sparse memory this mfn list is accessed via a three level p2m tree built early in the boot process

Re: [PATCH V3 2/8] xen: Delay remapping memory of pv-domain

2014-11-13 Thread Juergen Gross
On 11/13/2014 08:56 PM, Konrad Rzeszutek Wilk wrote: + mfn_save = virt_to_mfn(buf); + + while (xen_remap_mfn != INVALID_P2M_ENTRY) { So the 'list' is constructed by going forward - that is from low-numbered PFNs to higher numbered ones. But the 'xen_remap_mfn' is going the other way

Re: [PATCH V6 00/18] x86: Full support of PAT

2014-11-13 Thread Juergen Gross
Ingo, could you take the patches, please? Juergen On 11/03/2014 02:01 PM, Juergen Gross wrote: The x86 architecture offers via the PAT (Page Attribute Table) a way to specify different caching modes in page table entries. The PAT MSR contains 8 entries each specifying one of 6 possible cache

Re: [Xen-devel] [PATCH V3 7/8] xen: switch to linear virtual mapped sparse p2m list

2014-11-14 Thread Juergen Gross
On 11/14/2014 12:58 PM, David Vrabel wrote: On 13/11/14 09:21, Juergen Gross wrote: On 11/11/2014 06:47 PM, David Vrabel wrote: Can you please test this with the following guests/scenarios. * 64 bit dom0 with PCI devices with high MMIO BARs. I'm not sure I have a machine available

Re: [PATCH V3 2/8] xen: Delay remapping memory of pv-domain

2014-11-14 Thread Juergen Gross
On 11/14/2014 05:47 PM, Konrad Rzeszutek Wilk wrote: On Fri, Nov 14, 2014 at 05:53:19AM +0100, Juergen Gross wrote: On 11/13/2014 08:56 PM, Konrad Rzeszutek Wilk wrote: + mfn_save = virt_to_mfn(buf); + + while (xen_remap_mfn != INVALID_P2M_ENTRY) { So the 'list' is cons

Re: [Xen-devel] [PATCH] xen: privcmd: schedule() after private hypercall when non CONFIG_PREEMPT

2014-11-27 Thread Juergen Gross
On 11/27/2014 07:50 PM, Andrew Cooper wrote: On 27/11/14 18:36, Luis R. Rodriguez wrote: On Thu, Nov 27, 2014 at 07:36:31AM +0100, Juergen Gross wrote: On 11/26/2014 11:26 PM, Luis R. Rodriguez wrote: From: "Luis R. Rodriguez" Some folks had reported that some xen hypercalls t

[PATCH V4 00/10] xen: Switch to virtual mapped linear p2m list

2014-11-28 Thread Juergen Gross
up set_phys_to_machine() as suggested by David Vrabel Changes in V2: - splitted patch 2 in 4 smaller ones as requested by David Vrabel - added highmem check when remapping kernel memory as requested by David Vrabel Juergen Gross (10): xen: fix some style issues in p2m.c xen: Make

[PATCH V4 08/10] xen: Hide get_phys_to_machine() to be able to tune common path

2014-11-28 Thread Juergen Gross
Today get_phys_to_machine() is always called when the mfn for a pfn is to be obtained. Add a wrapper __pfn_to_mfn() as inline function to be able to avoid calling get_phys_to_machine() when possible as soon as the switch to a linear mapped p2m list has been done. Signed-off-by: Juergen Gross

[PATCH V4 09/10] xen: switch to linear virtual mapped sparse p2m list

2014-11-28 Thread Juergen Gross
the patch) - 32 bit domU, ballooning up and down - 32 bit domU, save and restore - 32 bit domU with PCI passthrough - 64 bit domU, 8 GB, 2049 MB, 5000 MB - 64 bit domU, ballooning up and down - 64 bit domU, save and restore - 64 bit domU with PCI passthrough Signed-off-by: Juergen Gross --- arch/x8

[PATCH V4 10/10] xen: Speed up set_phys_to_machine() by using read-only mappings

2014-11-28 Thread Juergen Gross
with no allocation much faster as it only requires a single write of the new mfn instead of walking the address translation tables and checking for the special cases. Suggested-by: David Vrabel Signed-off-by: Juergen Gross Reviewed-by: David Vrabel Reviewed-by: Konrad Rzeszutek Wilk --- arch/x86

[PATCH V4 1/9] xen: fix some style issues in p2m.c

2014-11-28 Thread Juergen Gross
The source arch/x86/xen/p2m.c has some coding style issues. Fix them. Signed-off-by: Juergen Gross --- arch/x86/xen/p2m.c | 15 +++ 1 file changed, 7 insertions(+), 8 deletions(-) diff --git a/arch/x86/xen/p2m.c b/arch/x86/xen/p2m.c index 9201a38..73d354a 100644 --- a/arch/x86/xen

[PATCH V4 07/10] x86: Introduce function to get pmd entry pointer

2014-11-28 Thread Juergen Gross
. Signed-off-by: Juergen Gross --- arch/x86/include/asm/pgtable_types.h | 1 + arch/x86/mm/pageattr.c | 20 2 files changed, 21 insertions(+) diff --git a/arch/x86/include/asm/pgtable_types.h b/arch/x86/include/asm/pgtable_types.h index 0778964..d83f5e7 100644

[PATCH V4 05/10] xen: Delay m2p_override initialization

2014-11-28 Thread Juergen Gross
an be done later without doing any harm, removing the need for allocating memory via extend_brk(). While at it make some m2p override functions static as they are only used internally. Signed-off-by: Juergen Gross Reviewed-by: David Vrabel Reviewed-by: Konrad Rzeszutek Wilk --- arch/x86/xen/p2m.c

[PATCH V4 06/10] xen: Delay invalidating extra memory

2014-11-28 Thread Juergen Gross
g the boot process until some more basic memory management functions are callable. This removes the need to create new p2m entries until virtual memory management is available. Signed-off-by: Juergen Gross Reviewed-by: David Vrabel --- arch/x86/include/asm/xen/page.h | 3 + arch/x86

[PATCH V4 03/10] xen: use common page allocation function in p2m.c

2014-11-28 Thread Juergen Gross
the to be called allocation routine dynamically based on the boot progress. This allows moving initialization steps without having to care about changing allocation calls. Signed-off-by: Juergen Gross --- arch/x86/xen/mmu.c | 2 ++ arch/x86/xen/p2m.c | 57

[PATCH V4 04/10] xen: Delay remapping memory of pv-domain

2014-11-28 Thread Juergen Gross
sical memory initialization time due to it's fixed structure. A further advantage is the reduction in complexity and code volume as we don't have to be careful regarding memory restrictions during p2m updates. Signed-off-by: Juergen Gross Reviewed-by: David Vrabel --- arch/x86/include

[PATCH V4 2/9] xen: Make functions static

2014-11-28 Thread Juergen Gross
Some functions in arch/x86/xen/p2m.c are used locally only. Make them static. Rearrange the functions in p2m.c to avoid forward declarations. Signed-off-by: Juergen Gross --- arch/x86/include/asm/xen/page.h | 6 - arch/x86/xen/p2m.c | 346

Re: [PATCH V4 00/10] xen: Switch to virtual mapped linear p2m list

2014-12-01 Thread Juergen Gross
On 12/01/2014 12:31 PM, David Vrabel wrote: On 28/11/14 10:53, Juergen Gross wrote: Paravirtualized kernels running on Xen use a three level tree for translation of guest specific physical addresses to machine global addresses. This p2m tree is used for construction of page table entries, so

Re: [Xen-devel] [PATCH] xen: privcmd: schedule() after private hypercall when non CONFIG_PREEMPT

2014-12-01 Thread Juergen Gross
On 12/01/2014 02:32 PM, Luis R. Rodriguez wrote: On Mon, Dec 01, 2014 at 11:01:18AM +, David Vrabel wrote: On 28/11/14 04:49, Juergen Gross wrote: On 11/27/2014 07:50 PM, Andrew Cooper wrote: XenServer uses https://github.com/xenserver/linux-3.x.pg/blob/master/master/0001-x86-xen-allow

Re: [PATCH] xen: privcmd: schedule() after private hypercall when non CONFIG_PREEMPT

2014-12-01 Thread Juergen Gross
+, David Vrabel wrote: On 27/11/14 18:36, Luis R. Rodriguez wrote: On Thu, Nov 27, 2014 at 07:36:31AM +0100, Juergen Gross wrote: On 11/26/2014 11:26 PM, Luis R. Rodriguez wrote: From: "Luis R. Rodriguez" Some folks had reported that some xen hypercalls take a long time to complete w

[PATCH V3 6/8] xen: Hide get_phys_to_machine() to be able to tune common path

2014-11-10 Thread Juergen Gross
Today get_phys_to_machine() is always called when the mfn for a pfn is to be obtained. Add a wrapper __pfn_to_mfn() as inline function to be able to avoid calling get_phys_to_machine() when possible as soon as the switch to a linear mapped p2m list has been done. Signed-off-by: Juergen Gross

[PATCH V3 1/8] xen: Make functions static

2014-11-10 Thread Juergen Gross
Some functions in arch/x86/xen/p2m.c are used locally only. Make them static. Rearrange the functions in p2m.c to avoid forward declarations. While at it correct some style issues (long lines, use pr_warn()). Signed-off-by: Juergen Gross --- arch/x86/include/asm/xen/page.h | 6 - arch/x86

[PATCH V3 7/8] xen: switch to linear virtual mapped sparse p2m list

2014-11-10 Thread Juergen Gross
-> 32:35 System: 18:07 -> 17:47 User:104:00 -> 103:30 Tested on 64 bit dom0 and 32 bit domU. Signed-off-by: Juergen Gross --- arch/x86/include/asm/xen/page.h | 14 +- arch/x86/xen/mmu.c | 32 +- arch/x86/xen/p2m.c

[PATCH V3 0/8] xen: Switch to virtual mapped linear p2m list

2014-11-10 Thread Juergen Gross
ones as requested by David Vrabel - added highmem check when remapping kernel memory as requested by David Vrabel Juergen Gross (8): xen: Make functions static xen: Delay remapping memory of pv-domain xen: Delay m2p_override initialization xen: Delay invalidating extra memory x86

[PATCH V3 8/8] xen: Speed up set_phys_to_machine() by using read-only mappings

2014-11-10 Thread Juergen Gross
with no allocation much faster as it only requires a single write of the new mfn instead of walking the address translation tables and checking for the special cases. Suggested-by: David Vrabel Signed-off-by: Juergen Gross --- arch/x86/xen/p2m.c | 14 -- 1 file changed, 8 insertions

[PATCH V3 5/8] x86: Introduce function to get pmd entry pointer

2014-11-10 Thread Juergen Gross
Introduces lookup_pmd_address() to get the address of the pmd entry related to a virtual address in the current address space. This function is needed for support of a virtual mapped sparse p2m list in xen pv domains. Signed-off-by: Juergen Gross --- arch/x86/include/asm/pgtable_types.h | 1

[PATCH V3 4/8] xen: Delay invalidating extra memory

2014-11-10 Thread Juergen Gross
g the boot process until some more basic memory management functions are callable. This removes the need to create new p2m entries until virtual memory management is available. Signed-off-by: Juergen Gross Reviewed-by: David Vrabel --- arch/x86/include/asm/xen/page.h | 3 + arch/x86

[PATCH V3 2/8] xen: Delay remapping memory of pv-domain

2014-11-10 Thread Juergen Gross
sical memory initialization time due to it's fixed structure. A further advantage is the reduction in complexity and code volume as we don't have to be careful regarding memory restrictions during p2m updates. Signed-off-by: Juergen Gross Reviewed-by: David Vrabel --- arch/x86/include

[PATCH V3 3/8] xen: Delay m2p_override initialization

2014-11-10 Thread Juergen Gross
an be done later without doing any harm, removing the need for allocating memory via extend_brk(). While at it make some m2p override functions static as they are only used internally. Signed-off-by: Juergen Gross --- arch/x86/xen/p2m.c | 33 +++-- 1 file change

Re: [Xen-devel] [PATCH V3 1/8] xen: Make functions static

2014-11-11 Thread Juergen Gross
On 11/11/2014 11:21 AM, David Vrabel wrote: On 11/11/14 05:43, Juergen Gross wrote: Some functions in arch/x86/xen/p2m.c are used locally only. Make them static. Rearrange the functions in p2m.c to avoid forward declarations. While at it correct some style issues (long lines, use pr_warn

Re: [Xen-devel] [PATCH V3 2/8] xen: Delay remapping memory of pv-domain

2014-11-11 Thread Juergen Gross
On 11/11/2014 12:45 PM, Andrew Cooper wrote: On 11/11/14 05:43, Juergen Gross wrote: diff --git a/arch/x86/xen/p2m.c b/arch/x86/xen/p2m.c index fa75842..f67f8cf 100644 --- a/arch/x86/xen/p2m.c +++ b/arch/x86/xen/p2m.c @@ -268,6 +271,22 @@ static void p2m_init(unsigned long *p2m

Re: frequent lockups in 3.18rc4

2014-11-25 Thread Juergen Gross
On 11/26/2014 06:09 AM, Linus Torvalds wrote: On Nov 25, 2014 8:39 PM, "Jürgen Groß" mailto:jgr...@suse.com>> wrote: > > I COULD trigger it with 3.17. Took much longer, but I've seen it once. > And from Xen hypervisor data it was clear it was the same bug (cpu > spinning in pmd_lock()). I'm

Re: frequent lockups in 3.18rc4

2014-11-25 Thread Juergen Gross
On 11/26/2014 07:21 AM, Linus Torvalds wrote: On Tue, Nov 25, 2014 at 9:52 PM, Linus Torvalds wrote: And leave it running for a while, and see if the trace is always the same, or if there are variations on it... Amusing. Lookie here: http://lists.xenproject.org/archives/html/xen-chang

Re: frequent lockups in 3.18rc4

2014-11-26 Thread Juergen Gross
On 11/26/2014 07:21 AM, Linus Torvalds wrote: On Tue, Nov 25, 2014 at 9:52 PM, Linus Torvalds wrote: And leave it running for a while, and see if the trace is always the same, or if there are variations on it... Amusing. Lookie here: http://lists.xenproject.org/archives/html/xen-chang

Re: [PATCH] xen: privcmd: schedule() after private hypercall when non CONFIG_PREEMPT

2014-11-26 Thread Juergen Gross
lls/0001-x86-xen-allow-privcmd-hypercalls-to-be-preempted.patch Cc: Davidlohr Bueso Cc: Joerg Roedel Cc: Borislav Petkov Cc: Konrad Rzeszutek Wilk Cc: Jan Beulich Cc: Juergen Gross Cc: Olaf Hering Cc: David Vrabel Signed-off-by: Luis R. Rodriguez --- drivers/xen/privcmd.c | 3 +++ 1 file

Re: [Xen-devel] [PATCH] xen: privcmd: schedule() after private hypercall when non CONFIG_PREEMPT

2014-12-02 Thread Juergen Gross
On 12/03/2014 03:28 AM, Luis R. Rodriguez wrote: On Tue, Dec 02, 2014 at 11:11:18AM +, David Vrabel wrote: On 01/12/14 22:36, Luis R. Rodriguez wrote: Then I do agree its a fair analogy (and find this obviously odd that how widespread cond_resched() is), we just don't have an equivalent fo

Re: [PATCH] xen: avoid race in p2m handling

2014-10-16 Thread Juergen Gross
On 10/16/2014 05:50 PM, David Vrabel wrote: On 16/10/14 07:13, Juergen Gross wrote: When a new p2m leaf is allocated this leaf is linked into the p2m tree via cmpxchg. Unfortunately the compare value for checking the success of the update is read after checking for the need of a new leaf. It is

[PATCH V2] xen: avoid race in p2m handling

2014-10-17 Thread Juergen Gross
. Signed-off-by: Juergen Gross --- arch/x86/xen/p2m.c | 10 +- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/arch/x86/xen/p2m.c b/arch/x86/xen/p2m.c index d1b3da2..b456b04 100644 --- a/arch/x86/xen/p2m.c +++ b/arch/x86/xen/p2m.c @@ -532,12 +532,13 @@ static bool alloc_p2m

Re: [RESEND PATCH V3 0/3] x86: Full support of PAT

2014-10-19 Thread Juergen Gross
Hi x86 maintainers, any reason you seem to ignore this patch series? I think I've replied to all open issues and sent the patches more than one month ago. Each patch has a "Reviewed-by". Is there something else missing? Juergen On 10/13/2014 10:13 AM, Juergen Gross

Re: [PATCH 0/6] x86: reduce paravirtualized spinlock overhead

2015-05-15 Thread Juergen Gross
Ping? On 04/30/2015 12:53 PM, Juergen Gross wrote: Paravirtualized spinlocks produce some overhead even if the kernel is running on bare metal. The main reason are the more complex locking and unlocking functions. Especially unlocking is no longer just one instruction but so complex that it is

Re: [RESEND Patch V3 00/15] xen: support pv-domains larger than 512GB

2015-05-15 Thread Juergen Gross
Ping? On 05/04/2015 10:23 AM, Juergen Gross wrote: Support 64 bit pv-domains with more than 512GB of memory. Tested with 64 bit dom0 on machines with 8GB and 1TB and 32 bit dom0 on a 8GB machine. Conflicts between E820 map and different hypervisor populated memory areas have been tested via a

Re: [PATCH 0/6] x86: reduce paravirtualized spinlock overhead

2015-05-18 Thread Juergen Gross
On 05/17/2015 07:30 AM, Ingo Molnar wrote: * Juergen Gross wrote: On 05/05/2015 07:21 PM, Jeremy Fitzhardinge wrote: On 05/03/2015 10:55 PM, Juergen Gross wrote: I did a small measurement of the pure locking functions on bare metal without and with my patches. spin_lock() for the first

Re: [PATCH 0/6] x86: reduce paravirtualized spinlock overhead

2015-05-06 Thread Juergen Gross
On 05/05/2015 07:21 PM, Jeremy Fitzhardinge wrote: On 05/03/2015 10:55 PM, Juergen Gross wrote: I did a small measurement of the pure locking functions on bare metal without and with my patches. spin_lock() for the first time (lock and code not in cache) dropped from about 600 to 500 cycles

Re: [PATCH 09/12] target: Convert se_portal_group->tpg_lun_list[] to RCU hlist

2015-05-13 Thread Juergen Gross
On 05/13/2015 08:24 AM, Christoph Hellwig wrote: FIXME: Figure out how sbp-target se_lun usage should work The Xen usage also looks really weird. Maybe Juergen can explain what scsiback_add_translation_entry is trying to do? scsiback_add_translation_entry() makes the connection between a p

Re: [PATCH 0/6] x86: reduce paravirtualized spinlock overhead

2015-05-03 Thread Juergen Gross
On 04/30/2015 06:39 PM, Jeremy Fitzhardinge wrote: On 04/30/2015 03:53 AM, Juergen Gross wrote: Paravirtualized spinlocks produce some overhead even if the kernel is running on bare metal. The main reason are the more complex locking and unlocking functions. Especially unlocking is no longer

[RESEND Patch V3 01/15] xen: sync with xen headers

2015-05-04 Thread Juergen Gross
Use the newest headers from the xen tree to get some new structure layouts. Signed-off-by: Juergen Gross Reviewed-by: David Vrabel --- arch/x86/include/asm/xen/interface.h | 96 include/xen/interface/xen.h | 10 ++-- 2 files changed, 93 insertions

[RESEND Patch V3 00/15] xen: support pv-domains larger than 512GB

2015-05-04 Thread Juergen Gross
o 512GB (patch 13->14) - modify parameter parsing to work in very early boot (patch 13->14) - add new patch 15 to do some cleanup - remove old patch 05 (simplify xen_set_identity_and_remap() by using global variables) - remove old patch 08 (detect pre-allocated memory interfering with e820 map)

[RESEND Patch V3 11/15] xen: check for initrd conflicting with e820 map

2015-05-04 Thread Juergen Gross
Check whether the initrd is placed at a location which is conflicting with the target E820 map. If this is the case relocate it to a new area unused up to now and compliant to the E820 map. Signed-off-by: Juergen Gross Reviewed-by: David Vrabel --- arch/x86/xen/setup.c | 51

[RESEND Patch V3 13/15] xen: move p2m list if conflicting with e820 map

2015-05-04 Thread Juergen Gross
This requires to memblock_reserve() the start_info page on it's own. Signed-off-by: Juergen Gross --- arch/x86/xen/mmu.c | 232 ++--- arch/x86/xen/setup.c | 51 +-- arch/x86/xen/xen-ops.h | 3 + 3 files changed, 247 insertions(+), 39

[RESEND Patch V3 12/15] mm: provide early_memremap_ro to establish read-only mapping

2015-05-04 Thread Juergen Gross
early_memremap_ro() to provide this read only mapping. Signed-off-by: Juergen Gross --- include/asm-generic/early_ioremap.h | 2 ++ include/asm-generic/fixmap.h| 3 +++ mm/early_ioremap.c | 11 +++ 3 files changed, 16 insertions(+) diff --git a/include/asm-generic

[RESEND Patch V3 09/15] xen: check for kernel memory conflicting with memory layout

2015-05-04 Thread Juergen Gross
Checks whether the pre-allocated memory of the loaded kernel is in conflict with the target memory map. If this is the case, just panic instead of run into problems later, as there is nothing we can do to repair this situation. Signed-off-by: Juergen Gross Reviewed-by: David Vrabel --- arch

[RESEND Patch V3 15/15] xen: remove no longer needed p2m.h

2015-05-04 Thread Juergen Gross
sed at all, just delete it. The only define left is P2M_PER_PAGE which is moved to page.h as well. Signed-off-by: Juergen Gross --- arch/x86/include/asm/xen/page.h | 6 -- arch/x86/xen/p2m.c | 6 +- arch/x86/xen/p2m.h | 15 --- arch/x86/x

[RESEND Patch V3 10/15] xen: check pre-allocated page tables for conflict with memory map

2015-05-04 Thread Juergen Gross
Check whether the page tables built by the domain builder are at memory addresses which are in conflict with the target memory map. If this is the case just panic instead of running into problems later. Signed-off-by: Juergen Gross --- arch/x86/xen/mmu.c | 19 --- arch/x86

[RESEND Patch V3 07/15] xen: check memory area against e820 map

2015-05-04 Thread Juergen Gross
Provide a service routine to check a physical memory area against the E820 map. The routine will return false if the complete area is RAM according to the E820 map and true otherwise. Signed-off-by: Juergen Gross Reviewed-by: David Vrabel --- arch/x86/xen/setup.c | 23

[RESEND Patch V3 08/15] xen: find unused contiguous memory area

2015-05-04 Thread Juergen Gross
to be done in any case. Signed-off-by: Juergen Gross Reviewed-by: David Vrabel --- arch/x86/xen/setup.c | 34 ++ arch/x86/xen/xen-ops.h | 1 + 2 files changed, 35 insertions(+) diff --git a/arch/x86/xen/setup.c b/arch/x86/xen/setup.c index 99ef82c..973d294 1

[RESEND Patch V3 14/15] xen: allow more than 512 GB of RAM for 64 bit pv-domains

2015-05-04 Thread Juergen Gross
the domain limit is returned to the hypervisor instead of being identity mapped, which was wrong anyway. The kernel configuration parameter to specify the maximum size of a domain can be deleted, as it is not relevant any more. Signed-off-by: Juergen Gross --- Documentation/kernel-parameter

[RESEND Patch V3 06/15] xen: split counting of extra memory pages from remapping

2015-05-04 Thread Juergen Gross
before the memory might be clobbered by xen_set_identity_and_remap(). This requires to not destroy the Xen E820 map when the one for the system is being constructed. Signed-off-by: Juergen Gross --- arch/x86/xen/setup.c | 98 +++- 1 file changed, 58

[RESEND Patch V3 05/15] xen: move static e820 map to global scope

2015-05-04 Thread Juergen Gross
Instead of using a function local static e820 map in xen_memory_setup() and calling various functions in the same source with the map as a parameter use a map directly accessible by all functions in the source. Signed-off-by: Juergen Gross Reviewed-by: David Vrabel --- arch/x86/xen/setup.c

[RESEND Patch V3 04/15] xen: eliminate scalability issues from initial mapping setup

2015-05-04 Thread Juergen Gross
r being able to boot a Dom0 on a system with more than 512 GB memory. Signed-off-by: Juergen Gross Based-on-patch-by: Jan Beulich --- arch/x86/xen/mmu.c | 126 arch/x86/xen/setup.c| 67 ++--- arch/x86/xen/xen-head.S |

[RESEND Patch V3 02/15] xen: save linear p2m list address in shared info structure

2015-05-04 Thread Juergen Gross
of the p2m list. Reading the generation count the Xen tools can detect changes of the mappings and re-read the p2m list eventually. Signed-off-by: Juergen Gross Reviewed-by: David Vrabel --- arch/x86/xen/p2m.c | 17 + 1 file changed, 17 insertions(+) diff --git a/arch/x86/xen

[RESEND Patch V3 03/15] xen: don't build mfn tree if tools don't need it

2015-05-04 Thread Juergen Gross
In case the Xen tools indicate they don't need the p2m 3 level tree as they support the virtual mapped linear p2m list, just omit building the tree. Signed-off-by: Juergen Gross Reviewed-by: David Vrabel --- arch/x86/xen/p2m.c | 10 +++--- 1 file changed, 7 insertions(+), 3 dele

Re: [PATCH V2 2/3] xen: scsiback: add LUN of restored domain

2015-02-23 Thread Juergen Gross
On 02/18/2015 06:02 PM, Boris Ostrovsky wrote: On 02/17/2015 02:02 AM, Juergen Gross wrote: When a xen domain is being restored the LUN state of a pvscsi device is "Connected" and not "Initialising" as in case of attaching a new pvscsi LUN. This must be taken into accou

Re: [Xen-devel] [PATCH 05/13] xen: simplify xen_set_identity_and_remap() by using global variables

2015-02-23 Thread Juergen Gross
On 02/19/2015 07:10 PM, David Vrabel wrote: On 18/02/2015 06:51, Juergen Gross wrote: xen_set_identity_and_remap() is used to prepare remapping of memory conflicting with the E820 map. It is tracking the pfn where to remap new memory via a local variable which is passed to a subfunction which

Re: [Xen-devel] [PATCH 06/13] xen: detect pre-allocated memory interfering with e820 map

2015-02-23 Thread Juergen Gross
On 02/19/2015 07:07 PM, David Vrabel wrote: On 18/02/2015 06:51, Juergen Gross wrote: Currently especially for dom0 guest memory with guest pfns not matching host areas populated with RAM are remapped to areas which are RAM native as well. This is done to be able to use identity mappings (pfn

Re: [Xen-devel] [PATCH 08/13] xen: add service function to copy physical memory areas

2015-02-23 Thread Juergen Gross
On 02/19/2015 06:35 PM, David Vrabel wrote: On 18/02/2015 06:52, Juergen Gross wrote: In case a pre-allocated memory area is to be moved in order to avoid a conflict with the target E820 map we need a way to copy data between physical addresses. Add a function doing this via early_memremap

Re: [Xen-devel] [PATCH 10/13] xen: check pre-allocated page tables for conflict with memory map

2015-02-23 Thread Juergen Gross
On 02/19/2015 06:37 PM, David Vrabel wrote: On 18/02/2015 06:52, Juergen Gross wrote: Check whether the page tables built by the domain builder are at memory addresses which are in conflict with the target memory map. If this is the case just panic instead of running into problems later

Re: [Xen-devel] [PATCH 09/13] xen: check for kernel memory conflicting with memory layout

2015-02-23 Thread Juergen Gross
On 02/19/2015 06:36 PM, David Vrabel wrote: On 18/02/2015 06:52, Juergen Gross wrote: Checks whether the pre-allocated memory of the loaded kernel is in conflict with the target memory map. If this is the case, just panic instead of run into problems later. What ensures this doesn't act

Re: [Xen-devel] [PATCH 12/13] xen: if p2m list located in to be remapped region delay remapping

2015-02-23 Thread Juergen Gross
On 02/19/2015 06:44 PM, David Vrabel wrote: On 18/02/2015 06:52, Juergen Gross wrote: With adapting the memory layout of dom0 to that of the host care must be taken not to remap the initial p2m list supported by the hypervisor. "...supplied by the hypervisor" ? Yes, of course.

[PATCH 0/4] x86: use correct early_[mem,io][re,un]map pairs

2015-02-24 Thread Juergen Gross
using the appropriate variants. Juergen Gross (4): x86: use early_memunmap in arch/x86/kernel/devicetree.c x86: use early_memunmap in arch/x86/kernel/e820.c x86: use early_memunmap in arch/x86/kernel/setup.c x86, efi: use early_ioremap in arch/x86/platform/efi/efi-bgrt.c arch/x86/kernel

[PATCH 1/4] x86: use early_memunmap in arch/x86/kernel/devicetree.c

2015-02-24 Thread Juergen Gross
Memory mapped via early_memremap() should be unmapped with early_memunmap() instead of early_iounmap(). Signed-off-by: Juergen Gross --- arch/x86/kernel/devicetree.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/arch/x86/kernel/devicetree.c b/arch/x86/kernel

[PATCH 3/4] x86: use early_memunmap in arch/x86/kernel/setup.c

2015-02-24 Thread Juergen Gross
Memory mapped via early_memremap() should be unmapped with early_memunmap() instead of early_iounmap(). Signed-off-by: Juergen Gross --- arch/x86/kernel/setup.c | 8 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/arch/x86/kernel/setup.c b/arch/x86/kernel/setup.c index

[PATCH 2/4] x86: use early_memunmap in arch/x86/kernel/e820.c

2015-02-24 Thread Juergen Gross
Memory mapped via early_memremap() should be unmapped with early_memunmap() instead of early_iounmap(). Signed-off-by: Juergen Gross --- arch/x86/kernel/e820.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/arch/x86/kernel/e820.c b/arch/x86/kernel/e820.c index 46201de

[PATCH 4/4] x86, efi: use early_ioremap in arch/x86/platform/efi/efi-bgrt.c

2015-02-24 Thread Juergen Gross
Use early_ioremap() to map an I/O-area instead of early_memremap(). Signed-off-by: Juergen Gross --- arch/x86/platform/efi/efi-bgrt.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/arch/x86/platform/efi/efi-bgrt.c b/arch/x86/platform/efi/efi-bgrt.c index d143d21

Re: [Xen-devel] [PATCH 06/13] xen: detect pre-allocated memory interfering with e820 map

2015-02-25 Thread Juergen Gross
On 02/25/2015 03:24 PM, David Vrabel wrote: On 24/02/15 06:27, Juergen Gross wrote: On 02/19/2015 07:07 PM, David Vrabel wrote: On 18/02/2015 06:51, Juergen Gross wrote: +{ +unsigned long pfn; +unsigned long area_start, area_end; +unsigned i; + +for (i = 0; i

<    4   5   6   7   8   9   10   11   12   13   >