|
From: | Liu, Jing2 |
Subject: | Re: [Qemu-devel] [PATCH v2 1/3] hw/pci: factor PCI reserve resources to a separate structure |
Date: | Mon, 20 Aug 2018 14:00:05 +0800 |
User-agent: | Mozilla/5.0 (Windows NT 10.0; WOW64; rv:52.0) Gecko/20100101 Thunderbird/52.9.1 |
Hi Marcel, On 8/17/2018 11:49 PM, Marcel Apfelbaum wrote:
Hi Jing,
[...]
+/* + * additional resources to reserve on firmware init + */ +typedef struct PCIResReserve { + uint32_t bus_reserve; + uint64_t io_reserve; + uint64_t mem_reserve;The patch looks good to me, I noticed you renamed 'mem_no_pref_reserve' to 'mem reserve'. I remember we had a lot of discussions about the naming, so they would be clear and consistent with the firmware counterpart.
OK, will change 'mem_no_pref_reserve' to 'mem_no_pref' and also for others.
Please add a least a comment in the PCIResReserve.
Will add a comment to the structure definition, and where it's called.
Also, since you encapsulated the fields into a new struct, you could remove the "_reserve" suffix so we remain with clear "bus", "io", "mem" ...
Got it. Thanks, Jing
Thanks, Marcel+ uint64_t pref32_reserve; + uint64_t pref64_reserve; +} PCIResReserve; + int pci_bridge_qemu_reserve_cap_init(PCIDevice *dev, int cap_offset, - uint32_t bus_reserve, uint64_t io_reserve, - uint64_t mem_non_pref_reserve, - uint64_t mem_pref_32_reserve, - uint64_t mem_pref_64_reserve, - Error **errp); + PCIResReserve res_reserve, Error **errp); #endif /* QEMU_PCI_BRIDGE_H */
[Prev in Thread] | Current Thread | [Next in Thread] |