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]
Message-ID: <20220506231737.GD122876@MiWiFi-R3L-srv>
Date:   Sat, 7 May 2022 07:17:37 +0800
From:   Baoquan He <bhe@...hat.com>
To:     Zhen Lei <thunder.leizhen@...wei.com>
Cc:     Thomas Gleixner <tglx@...utronix.de>,
        Ingo Molnar <mingo@...hat.com>, Borislav Petkov <bp@...en8.de>,
        x86@...nel.org, "H . Peter Anvin" <hpa@...or.com>,
        linux-kernel@...r.kernel.org, Dave Young <dyoung@...hat.com>,
        Vivek Goyal <vgoyal@...hat.com>,
        Eric Biederman <ebiederm@...ssion.com>,
        kexec@...ts.infradead.org,
        Catalin Marinas <catalin.marinas@....com>,
        Will Deacon <will@...nel.org>,
        linux-arm-kernel@...ts.infradead.org,
        Rob Herring <robh+dt@...nel.org>,
        Frank Rowand <frowand.list@...il.com>,
        devicetree@...r.kernel.org, Jonathan Corbet <corbet@....net>,
        linux-doc@...r.kernel.org, Randy Dunlap <rdunlap@...radead.org>,
        Feng Zhou <zhoufeng.zf@...edance.com>,
        Kefeng Wang <wangkefeng.wang@...wei.com>,
        Chen Zhou <dingguo.cz@...group.com>,
        John Donnelly <John.p.donnelly@...cle.com>,
        Dave Kleikamp <dave.kleikamp@...cle.com>
Subject: Re: [PATCH v24 5/6] of: Support more than one crash kernel regions
 for kexec -s

On 05/06/22 at 07:44pm, Zhen Lei wrote:
> When "crashkernel=X,high" is used, there may be two crash regions:
> high=crashk_res and low=crashk_low_res. But now the syscall
> kexec_file_load() only add crashk_res into "linux,usable-memory-range",
> this may cause the second kernel to have no available dma memory.
> 
> Fix it like kexec tool do for option -c, add both 'high' and 'low' regions
              ~~~~~~~~~~~~ 
              kexec-tools does

Other than this, LGTM,

Acked-by: Baoquan He <bhe@...hat.com>

> into the dtb.
> 
> Signed-off-by: Zhen Lei <thunder.leizhen@...wei.com>
> Acked-by: Rob Herring <robh@...nel.org>
> ---
>  drivers/of/kexec.c | 9 +++++++++
>  1 file changed, 9 insertions(+)
> 
> diff --git a/drivers/of/kexec.c b/drivers/of/kexec.c
> index b9bd1cff179388c..8d374cc552be5f2 100644
> --- a/drivers/of/kexec.c
> +++ b/drivers/of/kexec.c
> @@ -386,6 +386,15 @@ void *of_kexec_alloc_and_setup_fdt(const struct kimage *image,
>  				crashk_res.end - crashk_res.start + 1);
>  		if (ret)
>  			goto out;
> +
> +		if (crashk_low_res.end) {
> +			ret = fdt_appendprop_addrrange(fdt, 0, chosen_node,
> +					"linux,usable-memory-range",
> +					crashk_low_res.start,
> +					crashk_low_res.end - crashk_low_res.start + 1);
> +			if (ret)
> +				goto out;
> +		}
>  	}
>  
>  	/* add bootargs */
> -- 
> 2.25.1
> 

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ