[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [RFC PATCH 0/5] ARM: reduce the memory consumed when mapping UEFI fl
From: |
Markus Armbruster |
Subject: |
Re: [RFC PATCH 0/5] ARM: reduce the memory consumed when mapping UEFI flash images |
Date: |
Mon, 16 Nov 2020 14:48:26 +0100 |
User-agent: |
Gnus/5.13 (Gnus v5.13) Emacs/27.1 (gnu/linux) |
Philippe Mathieu-Daudé <philmd@redhat.com> writes:
> Hi David,
>
> On 11/16/20 11:42 AM, David Edmondson wrote:
>> Currently ARM UEFI images are typically built as 2MB/768kB flash
>> images for code and variables respectively. These images are both then
>> padded out to 64MB before being loaded by QEMU.
>>
>> Because the images are 64MB each, QEMU allocates 128MB of memory to
>> read them, and then proceeds to read all 128MB from disk (dirtying the
>> memory). Of this 128MB less than 3MB is useful - the rest is zero
>> padding.
>
> 2 years ago I commented the same problem, and suggested to access the
> underlying storage by "block", as this is a "block storage".
>
> Back then the response was "do not try to fix something that works".
> This is why we choose the big hammer "do not accept image size not
> matching device size" way.
>
> While your series seems to help, it only postpone the same
> implementation problem. If what you want is use the least memory
> required, I still believe accessing the device by block is the
> best approach.
"Do not try to fix something that works" is hard to disagree with.
However, at least some users seem to disagree with "this works". Enough
to overcome the resistance to change?
- Re: [RFC PATCH 1/5] hw/block: blk_check_size_and_read_all should report backend name, (continued)
- [RFC PATCH 4/5] hw/arm: Flash image mapping follows image size, David Edmondson, 2020/11/16
- [RFC PATCH 5/5] hw/arm: Only minimise flash size on older machines, David Edmondson, 2020/11/16
- [RFC PATCH 3/5] hw/arm: Convert assertions about flash image size to error_report, David Edmondson, 2020/11/16
- [RFC PATCH 2/5] hw/block: Flash images can be smaller than the device, David Edmondson, 2020/11/16
- Re: [RFC PATCH 0/5] ARM: reduce the memory consumed when mapping UEFI flash images, Philippe Mathieu-Daudé, 2020/11/16