2 * QEMU Parallel PORT (ISA bus helpers)
4 * Copyright (c) 2003 Fabrice Bellard
6 * SPDX-License-Identifier: MIT
8 #include "qemu/osdep.h"
9 #include "sysemu/sysemu.h"
10 #include "hw/isa/isa.h"
11 #include "hw/char/parallel.h"
13 static void parallel_init(ISABus
*bus
, int index
, Chardev
*chr
)
18 isadev
= isa_create(bus
, "isa-parallel");
20 qdev_prop_set_uint32(dev
, "index", index
);
21 qdev_prop_set_chr(dev
, "chardev", chr
);
22 qdev_init_nofail(dev
);
25 void parallel_hds_isa_init(ISABus
*bus
, int n
)
29 assert(n
<= MAX_PARALLEL_PORTS
);
31 for (i
= 0; i
< n
; i
++) {
32 if (parallel_hds
[i
]) {
33 parallel_init(bus
, i
, parallel_hds
[i
]);