qemu-block
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Qemu-block] [RFC PATCH 4/4] pc: Support firmware configuration with


From: Philippe Mathieu-Daudé
Subject: Re: [Qemu-block] [RFC PATCH 4/4] pc: Support firmware configuration with -blockdev
Date: Tue, 5 Mar 2019 18:53:15 +0100
User-agent: Mozilla/5.0 (X11; Linux x86_64; rv:60.0) Gecko/20100101 Thunderbird/60.5.1

Hi Laszlo!

On 3/5/19 6:34 PM, Laszlo Ersek wrote:
> Hi Phil,
> 
> On 03/04/19 20:48, Philippe Mathieu-Daudé wrote:
> 
>> [PMD: rebased on 'pflash: Fixes and cleanups'
>>       replaced CFI_PFLASH01 -> PFLASH_CFI01]
> 
> [...]
> 
>> -#define FLASH_MAP_UNIT_MAX 2
>> +static PFlashCFI01 *pc_pflash_create(const char *name)
>> +{
>> +    DeviceState *dev = qdev_create(NULL, TYPE_PFLASH_CFI01);
>> +
>> +    qdev_prop_set_uint64(dev, "sector-length", 4096);
> 
> [...]
> 
>> -static void pc_system_flash_init(MemoryRegion *rom_memory)
>> +static void pc_system_flash_map(PCMachineState *pcms,
>> +                                MemoryRegion *rom_memory)
>>  {
>> -    int unit;
>> -    DriveInfo *pflash_drv;
>> +    hwaddr total_size = 0;
>> +    int i;
>>      BlockBackend *blk;
>>      int64_t size;
>> -    char *fatal_errmsg = NULL;
>> -    hwaddr phys_addr = 0x100000000ULL;
>>      uint32_t sector_size = 4096;
> 
> [...]
> 
>> +        if (size == 0) {
>> +            error_report("system firmware block device %s is empty",
>> +                         blk_name(blk));
>> +            exit(1);
>> +        }
>> +        if (size == 0 || size % sector_size != 0) {
> 
> I think you missed my points (1) and (2), and Markus's followup, here:
> 
> https://lists.gnu.org/archive/html/qemu-devel/2019-02/msg07018.html

Actually I missed your whole mail...

I'll let Markus take what he likes from this 'splitting' series, and
apply your comments on top if it :)

Markus: you can also drop patches 3/4 of this series if it makes your
work harder.

Thanks both!

Phil.



reply via email to

[Prev in Thread] Current Thread [Next in Thread]