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] [day] [month] [year] [list]
Message-ID: <96aae430-1bbf-1274-d6d1-262e93b5fe7d@huawei.com>
Date: Mon, 29 Jul 2024 19:28:50 +0800
From: Jinjie Ruan <ruanjinjie@...wei.com>
To: Baoquan He <bhe@...hat.com>
CC: <akpm@...ux-foundation.org>, <vgoyal@...hat.com>, <dyoung@...hat.com>,
	<paul.walmsley@...ive.com>, <palmer@...belt.com>, <aou@...s.berkeley.edu>,
	<rppt@...nel.org>, <kexec@...ts.infradead.org>,
	<linux-kernel@...r.kernel.org>, <linux-riscv@...ts.infradead.org>,
	<linux-arm-kernel@...ts.infradead.org>
Subject: Re: [PATCH v5] crash: Fix crash memory reserve exceed system memory
 bug



On 2024/7/29 11:29, Baoquan He wrote:
> On 07/29/24 at 11:24am, Jinjie Ruan wrote:
>>
>>
>> On 2024/7/23 13:17, Baoquan He wrote:
>>> On 07/23/24 at 10:07am, Jinjie Ruan wrote:
>>>> On x86_32 Qemu machine with 1GB memory, the cmdline "crashkernel=4G" is ok
>>>> as below:
>>>> 	crashkernel reserved: 0x0000000020000000 - 0x0000000120000000 (4096 MB)
>>>>
>>>> It's similar on other architectures, such as ARM32 and RISCV32.
>>>>
>>>> The cause is that the crash_size is parsed and printed with "unsigned long
>>>> long" data type which is 8 bytes but allocated used with "phys_addr_t"
>>>> which is 4 bytes in memblock_phys_alloc_range().
>>>>
>>>> Fix it by checking if crash_size is greater than system RAM size and
>>>> return error if so.
>>>>
>>>> After this patch, there is no above confusing reserve success info.
>>>>
>>>> Signed-off-by: Jinjie Ruan <ruanjinjie@...wei.com>
>>>> Suggested-by: Baoquan He <bhe@...hat.com>
>>>> Suggested-by: Mike Rapoport <rppt@...nel.org>
>>>
>>>
>>> My Suggested-by can be taken off because I suggested to check the parsed
>>> value after parse_crashkernel(), Mike's suggestion is better.
>>
>> Hi, Can the suggested-by be removed when this version is merged, or a
>> new version needs to be sent?
> 
> You can send a new one and CC Andrew.

Thank you!

> 
> 

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ