Richard Henderson <richard.henderson@xxxxxxxxxx> writes: > On 3/9/21 8:12 AM, Markus Armbruster wrote: >> @@ -2565,6 +2551,7 @@ static void fdctrl_realize_common(DeviceState *dev, FDCtrl *fdctrl, >> Error **errp) >> { >> int i, j; >> + FDrive *drive; >> static int command_tables_inited = 0; >> if (fdctrl->fallback == FLOPPY_DRIVE_TYPE_AUTO) { >> @@ -2604,7 +2591,13 @@ static void fdctrl_realize_common(DeviceState *dev, FDCtrl *fdctrl, >> } >> floppy_bus_create(fdctrl, &fdctrl->bus, dev); >> - fdctrl_connect_drives(fdctrl, dev, errp); >> + >> + for (i = 0; i < MAX_FD; i++) { >> + drive = &fdctrl->drives[i]; > > FWIW, the declaration could be local to this loop. Old-school habits. John, got a preference?