Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > linux.kernel > #1465715 > unrolled thread

Re: [PATCH 1/2] x86: Set up resources correctly on Hyper-V Generation 2

Started byDan Williams <dan.j.williams@intel.com>
First post2016-08-19 03:10 +0200
Last post2016-08-19 04:50 +0200
Articles 10 — 2 participants

Back to article view | Back to linux.kernel

This discussion starts older than the indexed window; earlier articles aren't shown. The article labeled Started by below is the oldest one visible, not the original post.


Contents

  Re: [PATCH 1/2] x86: Set up resources correctly on Hyper-V Generation 2 Dan Williams <dan.j.williams@intel.com> - 2016-08-19 03:10 +0200
    Re: [PATCH 1/2] x86: Set up resources correctly on Hyper-V Generation 2 Dan Williams <dan.j.williams@intel.com> - 2016-08-19 03:40 +0200
      RE: [PATCH 1/2] x86: Set up resources correctly on Hyper-V Generation  2 Matthew Wilcox <mawilcox@microsoft.com> - 2016-08-19 04:00 +0200
        RE: [PATCH 1/2] x86: Set up resources correctly on Hyper-V Generation  2 Matthew Wilcox <mawilcox@microsoft.com> - 2016-08-19 07:10 +0200
        Re: [PATCH 1/2] x86: Set up resources correctly on Hyper-V Generation 2 Dan Williams <dan.j.williams@intel.com> - 2016-08-19 07:30 +0200
    RE: [PATCH 1/2] x86: Set up resources correctly on Hyper-V Generation  2 Matthew Wilcox <mawilcox@microsoft.com> - 2016-08-19 03:50 +0200
      Re: [PATCH 1/2] x86: Set up resources correctly on Hyper-V Generation 2 Dan Williams <dan.j.williams@intel.com> - 2016-08-19 03:50 +0200
        RE: [PATCH 1/2] x86: Set up resources correctly on Hyper-V Generation  2 Matthew Wilcox <mawilcox@microsoft.com> - 2016-08-19 04:00 +0200
    RE: [PATCH 1/2] x86: Set up resources correctly on Hyper-V Generation  2 Matthew Wilcox <mawilcox@microsoft.com> - 2016-08-19 03:50 +0200
      Re: [PATCH 1/2] x86: Set up resources correctly on Hyper-V Generation 2 Dan Williams <dan.j.williams@intel.com> - 2016-08-19 04:50 +0200

#1465715 — Re: [PATCH 1/2] x86: Set up resources correctly on Hyper-V Generation 2

FromDan Williams <dan.j.williams@intel.com>
Date2016-08-19 03:10 +0200
SubjectRe: [PATCH 1/2] x86: Set up resources correctly on Hyper-V Generation 2
Message-ID<s7GtR-7go-47@gated-at.bofh.it>
On Thu, Aug 18, 2016 at 12:12 PM, Matthew Wilcox
<mawilcox@linuxonhyperv.com> wrote:
> From: Matthew Wilcox <mawilcox@microsoft.com>
>
> The Generation 2 Hyper-V virtual machine does not emulate PCI.
> This check causes the call to pcibios_resource_survey() to be skipped,
> and pcibios_resource_survey() calls e820_reserve_resources_late(), which
> is where PMEM resources are added to the resource tree.  With this patch,
> the PMEM devices now show up.
>
> Signed-off-by: Matthew Wilcox <mawilcox@microsoft.com>
> ---
>  arch/x86/pci/common.c | 5 -----
>  1 file changed, 5 deletions(-)
>
> diff --git a/arch/x86/pci/common.c b/arch/x86/pci/common.c
> index 7b6a9d1..d39e799 100644
> --- a/arch/x86/pci/common.c
> +++ b/arch/x86/pci/common.c
> @@ -516,11 +516,6 @@ void __init pcibios_set_cache_line_size(void)
>
>  int __init pcibios_init(void)
>  {
> -       if (!raw_pci_ops && !raw_pci_ext_ops) {
> -               printk(KERN_WARNING "PCI: System does not support PCI\n");
> -               return 0;
> -       }
> -
>         pcibios_set_cache_line_size();
>         pcibios_resource_survey();

Is this for the memmap= kernel command line option or the ACPI NFIT
method for defining NVDIMM resources?

[toc] | [next] | [standalone]


#1465820

FromDan Williams <dan.j.williams@intel.com>
Date2016-08-19 03:40 +0200
Message-ID<s7GWS-7sc-57@gated-at.bofh.it>
In reply to#1465715
On Thu, Aug 18, 2016 at 11:26 AM, Matthew Wilcox <mawilcox@microsoft.com> wrote:
> *Until* such a mechanism is in, I see no reason to not keep feature parity for all platforms.  This is the exact "You should boil the ocean" response that Arjan famously complained about at Kernel Summit a few years ago.

Feature parity for all platforms is the NFIT which Hyper-V is already
implementing.

Setting that aside, if we want to fix memmap= for the general case,
implementing a table like mBFT does not amount to ocean boiling in my
opinion.

[toc] | [prev] | [next] | [standalone]


#1465852 — RE: [PATCH 1/2] x86: Set up resources correctly on Hyper-V Generation 2

FromMatthew Wilcox <mawilcox@microsoft.com>
Date2016-08-19 04:00 +0200
SubjectRE: [PATCH 1/2] x86: Set up resources correctly on Hyper-V Generation 2
Message-ID<s7Hgd-7z4-1@gated-at.bofh.it>
In reply to#1465820
Compared to a patch which removes 5 lines of code, almost any additional work is ocean-boiling.

-----Original Message-----
From: Dan Williams [mailto:dan.j.williams@intel.com] 
Sent: Thursday, August 18, 2016 3:12 PM
To: Matthew Wilcox <mawilcox@microsoft.com>
Cc: X86 ML <x86@kernel.org>; linux-kernel@vger.kernel.org; linux-nvdimm@lists.01.org
Subject: Re: [PATCH 1/2] x86: Set up resources correctly on Hyper-V Generation 2

On Thu, Aug 18, 2016 at 11:26 AM, Matthew Wilcox <mawilcox@microsoft.com> wrote:
> *Until* such a mechanism is in, I see no reason to not keep feature parity for all platforms.  This is the exact "You should boil the ocean" response that Arjan famously complained about at Kernel Summit a few years ago.

Feature parity for all platforms is the NFIT which Hyper-V is already implementing.

Setting that aside, if we want to fix memmap= for the general case, implementing a table like mBFT does not amount to ocean boiling in my opinion.

[toc] | [prev] | [next] | [standalone]


#1465991 — RE: [PATCH 1/2] x86: Set up resources correctly on Hyper-V Generation 2

FromMatthew Wilcox <mawilcox@microsoft.com>
Date2016-08-19 07:10 +0200
SubjectRE: [PATCH 1/2] x86: Set up resources correctly on Hyper-V Generation 2
Message-ID<s7Ke5-1ke-11@gated-at.bofh.it>
In reply to#1465852
Yes, but this actually *removes a bug* in the Linux kernel; if any memory resource is left to be set up later, it is currently not set up on x86 machines which don't have PCI busses.  That's not very many x86 systems, I'll agree, but I'm sure some enterprising person is busy creating an SoC which lacks PCI.

-----Original Message-----
From: Dan Williams [mailto:dan.j.williams@intel.com] 
Sent: Thursday, August 18, 2016 4:17 PM
To: Matthew Wilcox <mawilcox@microsoft.com>
Cc: X86 ML <x86@kernel.org>; linux-kernel@vger.kernel.org; linux-nvdimm@lists.01.org
Subject: Re: [PATCH 1/2] x86: Set up resources correctly on Hyper-V Generation 2

On Thu, Aug 18, 2016 at 12:56 PM, Matthew Wilcox <mawilcox@microsoft.com> wrote:
> Compared to a patch which removes 5 lines of code, almost any additional work is ocean-boiling.
>

Did you check the state of NFIT enabling in Hyper-V?  Not patching the Linux kernel at all is even less work.

[toc] | [prev] | [next] | [standalone]


#1466009

FromDan Williams <dan.j.williams@intel.com>
Date2016-08-19 07:30 +0200
Message-ID<s7Ke5-1ke-13@gated-at.bofh.it>
In reply to#1465852
On Thu, Aug 18, 2016 at 12:56 PM, Matthew Wilcox <mawilcox@microsoft.com> wrote:
> Compared to a patch which removes 5 lines of code, almost any additional work is ocean-boiling.
>

Did you check the state of NFIT enabling in Hyper-V?  Not patching the
Linux kernel at all is even less work.

[toc] | [prev] | [next] | [standalone]


#1465830 — RE: [PATCH 1/2] x86: Set up resources correctly on Hyper-V Generation 2

FromMatthew Wilcox <mawilcox@microsoft.com>
Date2016-08-19 03:50 +0200
SubjectRE: [PATCH 1/2] x86: Set up resources correctly on Hyper-V Generation 2
Message-ID<s7GWS-7sc-63@gated-at.bofh.it>
In reply to#1465715
I'd rather the memmap= option works on all platforms.  Unless we're going to get rid of it entirely and exclusively use ACPI tables, I see no good reason to leave this landmine lying around for someone else to blow their own leg off.

-----Original Message-----
From: Dan Williams [mailto:dan.j.williams@intel.com] 
Sent: Thursday, August 18, 2016 2:03 PM
To: Matthew Wilcox <mawilcox@microsoft.com>
Cc: Matthew Wilcox <mawilcox@linuxonhyperv.com>; X86 ML <x86@kernel.org>; linux-kernel@vger.kernel.org; linux-nvdimm@lists.01.org
Subject: Re: [PATCH 1/2] x86: Set up resources correctly on Hyper-V Generation 2

On Thu, Aug 18, 2016 at 10:50 AM, Matthew Wilcox <mawilcox@microsoft.com> wrote:
> This is the memmap= kernel command line option.

The Hyper-V ACPI tables are growing NFIT support, or I believe that work is already underway.  I'd rather not touch the Linux PCI core to cover for the fact that Hyper-V disables one of the kernel's debug command line options when there's a platform standard way to communicate these resources.

[toc] | [prev] | [next] | [standalone]


#1465846

FromDan Williams <dan.j.williams@intel.com>
Date2016-08-19 03:50 +0200
Message-ID<s7GWS-7sc-65@gated-at.bofh.it>
In reply to#1465830
On Thu, Aug 18, 2016 at 11:05 AM, Matthew Wilcox <mawilcox@microsoft.com> wrote:
> I'd rather the memmap= option works on all platforms.  Unless we're going to get rid of it entirely and exclusively use ACPI tables, I see no good reason to leave this landmine lying around for someone else to blow their own leg off.
>

memmap= is already a landmine: https://lkml.org/lkml/2016/6/28/819

Killing memmap= in favor of NFIT is a better way to go.  I chatted
with Peter off list about this problem and he wondered about
re-purposing using the mBFT mechanism to define memory ranges:

http://omniboot.org/txt/syslinux/memdisk.txt

[toc] | [prev] | [next] | [standalone]


#1465865 — RE: [PATCH 1/2] x86: Set up resources correctly on Hyper-V Generation 2

FromMatthew Wilcox <mawilcox@microsoft.com>
Date2016-08-19 04:00 +0200
SubjectRE: [PATCH 1/2] x86: Set up resources correctly on Hyper-V Generation 2
Message-ID<s7GWS-7sc-67@gated-at.bofh.it>
In reply to#1465846
*Until* such a mechanism is in, I see no reason to not keep feature parity for all platforms.  This is the exact "You should boil the ocean" response that Arjan famously complained about at Kernel Summit a few years ago.

-----Original Message-----
From: Dan Williams [mailto:dan.j.williams@intel.com] 
Sent: Thursday, August 18, 2016 2:15 PM
To: Matthew Wilcox <mawilcox@microsoft.com>
Cc: Matthew Wilcox <mawilcox@linuxonhyperv.com>; X86 ML <x86@kernel.org>; linux-kernel@vger.kernel.org; linux-nvdimm@lists.01.org
Subject: Re: [PATCH 1/2] x86: Set up resources correctly on Hyper-V Generation 2

On Thu, Aug 18, 2016 at 11:05 AM, Matthew Wilcox <mawilcox@microsoft.com> wrote:
> I'd rather the memmap= option works on all platforms.  Unless we're going to get rid of it entirely and exclusively use ACPI tables, I see no good reason to leave this landmine lying around for someone else to blow their own leg off.
>

memmap= is already a landmine: https://lkml.org/lkml/2016/6/28/819

Killing memmap= in favor of NFIT is a better way to go.  I chatted with Peter off list about this problem and he wondered about re-purposing using the mBFT mechanism to define memory ranges:

http://omniboot.org/txt/syslinux/memdisk.txt

[toc] | [prev] | [next] | [standalone]


#1465851 — RE: [PATCH 1/2] x86: Set up resources correctly on Hyper-V Generation 2

FromMatthew Wilcox <mawilcox@microsoft.com>
Date2016-08-19 03:50 +0200
SubjectRE: [PATCH 1/2] x86: Set up resources correctly on Hyper-V Generation 2
Message-ID<s7GWS-7sc-59@gated-at.bofh.it>
In reply to#1465715
This is the memmap= kernel command line option.

-----Original Message-----
From: Dan Williams [mailto:dan.j.williams@intel.com] 
Sent: Thursday, August 18, 2016 1:32 PM
To: Matthew Wilcox <mawilcox@linuxonhyperv.com>
Cc: X86 ML <x86@kernel.org>; linux-kernel@vger.kernel.org; linux-nvdimm@lists.01.org; Matthew Wilcox <mawilcox@microsoft.com>
Subject: Re: [PATCH 1/2] x86: Set up resources correctly on Hyper-V Generation 2

Is this for the memmap= kernel command line option or the ACPI NFIT
method for defining NVDIMM resources?

[toc] | [prev] | [next] | [standalone]


#1465940

FromDan Williams <dan.j.williams@intel.com>
Date2016-08-19 04:50 +0200
Message-ID<s7GWS-7sc-61@gated-at.bofh.it>
In reply to#1465851
On Thu, Aug 18, 2016 at 10:50 AM, Matthew Wilcox <mawilcox@microsoft.com> wrote:
> This is the memmap= kernel command line option.

The Hyper-V ACPI tables are growing NFIT support, or I believe that
work is already underway.  I'd rather not touch the Linux PCI core to
cover for the fact that Hyper-V disables one of the kernel's debug
command line options when there's a platform standard way to
communicate these resources.

[toc] | [prev] | [standalone]


Back to top | Article view | linux.kernel


csiph-web