lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Date:   Wed, 3 Jul 2019 13:10:58 +0200
From:   "Rafael J. Wysocki" <rafael@...nel.org>
To:     Dan Williams <dan.j.williams@...el.com>
Cc:     "the arch/x86 maintainers" <x86@...nel.org>,
        Dave Hansen <dave.hansen@...ux.intel.com>,
        Peter Zijlstra <peterz@...radead.org>,
        Vishal Verma <vishal.l.verma@...el.com>,
        Ard Biesheuvel <ard.biesheuvel@...aro.org>,
        Thomas Gleixner <tglx@...utronix.de>,
        ACPI Devel Maling List <linux-acpi@...r.kernel.org>,
        "linux-nvdimm@...ts.01.org" <linux-nvdimm@...ts.01.org>,
        Linux Kernel Mailing List <linux-kernel@...r.kernel.org>
Subject: Re: [PATCH v4 02/10] acpi/numa/hmat: Skip publishing target info for
 nodes with no online memory

On Mon, Jun 24, 2019 at 8:33 PM Dan Williams <dan.j.williams@...el.com> wrote:
>
> There are multiple scenarios where the HMAT may contain information
> about proximity domains that are not currently online. Rather than fail
> to report any HMAT data just elide those offline domains.
>
> If and when those domains are later onlined they can be added to the
> HMEM reporting at that point.
>
> This was found while testing EFI_MEMORY_SP support which reserves
> "specific purpose" memory from the general allocation pool. If that
> reservation results in an empty numa-node then the node is not marked
> online leading a spurious:
>
>     "acpi/hmat: Ignoring HMAT: Invalid table"
>
> ...result for HMAT parsing.
>
> Reviewed-by: Dave Hansen <dave.hansen@...ux.intel.com>
> Signed-off-by: Dan Williams <dan.j.williams@...el.com>

Acked-by: Rafael J. Wysocki <rafael.j.wysocki@...el.com>

> ---
>  drivers/acpi/numa/hmat.c |   14 +++++++++++---
>  1 file changed, 11 insertions(+), 3 deletions(-)
>
> diff --git a/drivers/acpi/numa/hmat.c b/drivers/acpi/numa/hmat.c
> index 96b7d39a97c6..2c220cb7b620 100644
> --- a/drivers/acpi/numa/hmat.c
> +++ b/drivers/acpi/numa/hmat.c
> @@ -96,9 +96,6 @@ static __init void alloc_memory_target(unsigned int mem_pxm)
>  {
>         struct memory_target *target;
>
> -       if (pxm_to_node(mem_pxm) == NUMA_NO_NODE)
> -               return;
> -
>         target = find_mem_target(mem_pxm);
>         if (target)
>                 return;
> @@ -588,6 +585,17 @@ static __init void hmat_register_targets(void)
>         struct memory_target *target;
>
>         list_for_each_entry(target, &targets, node) {
> +               int nid = pxm_to_node(target->memory_pxm);
> +
> +               /*
> +                * Skip offline nodes. This can happen when memory
> +                * marked EFI_MEMORY_SP, "specific purpose", is applied
> +                * to all the memory in a promixity domain leading to
> +                * the node being marked offline / unplugged, or if
> +                * memory-only "hotplug" node is offline.
> +                */
> +               if (nid == NUMA_NO_NODE || !node_online(nid))
> +                       continue;
>                 hmat_register_target_initiators(target);
>                 hmat_register_target_perf(target);
>         }
>

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ