On 06/04/20 12:26, Gerd Hoffmann wrote: > - if (isa->iobase != 0x0378) { > + for (i = 0; i < ARRAY_SIZE(isa_parallel_io); i++) { > + if (isa->iobase == isa_parallel_io[i]) { > + uid = i + 1; > + } > + } > + if (!uid) { > return; > } > > @@ -583,8 +589,9 @@ static void parallel_isa_build_aml(ISADevice *isadev, Aml > *scope) > aml_append(crs, aml_io(AML_DECODE16, 0x0378, 0x0378, 0x08, 0x08));
FWIW this should be replaced with iso->iobase if you want to support multiple parallel ports (we probably should since the patch has been written already :)). Paolo > aml_append(crs, aml_irq_no_flags(7)); > > - dev = aml_device("LPT"); > + dev = aml_device("LPT%d", uid); > aml_append(dev, aml_name_decl("_HID", aml_eisaid("PNP0400"))); > + aml_append(dev, aml_name_decl("_UID", aml_int(uid))); > aml_append(dev, aml_name_decl("_STA", aml_int(0xf))); > aml_append(dev, aml_name_decl("_CRS", crs)); >