On 8/2/24 23:03, Bernhard Beschow wrote:
There is no advantage in having these local variables which 1/ needlessly have
different identifiers in both machines and 2/ which are redundant to pcms->bus
which is almost as short.
Signed-off-by: Bernhard Beschow <shen...@gmail.com>
---
hw/i386/pc_piix.c | 14 ++++++--------
hw/i386/pc_q35.c | 16 +++++++---------
2 files changed, 13 insertions(+), 17 deletions(-)
IMO it is a design mistake to have these fields in PCMachineState:
27 typedef struct PCMachineState {
36 /* Pointers to devices and objects: */
37 PCIBus *bus;
38 I2CBus *smbus;
39 PFlashCFI01 *flash[2];
40 ISADevice *pcspk;
41 DeviceState *iommu;
42 BusState *idebus[MAX_IDE_BUS];
Anyhow, back to your patch, please rename 'bus' -> 'pcibus'. Maybe
in a preliminary patch?