aboutsummaryrefslogtreecommitdiff
path: root/hw/hppa/machine.c
diff options
context:
space:
mode:
authorHelge Deller <deller@gmx.de>2019-12-20 22:15:08 +0100
committerRichard Henderson <richard.henderson@linaro.org>2020-01-27 10:49:51 -0800
commit376b851909d42c6faf4f780f25b6be55f17f3a6e (patch)
tree4498917486d47539b4b58ba80f6e12cefe234f69 /hw/hppa/machine.c
parent18092598a50ab62aba2059a25a7fff8286875610 (diff)
downloadqemu-376b851909d42c6faf4f780f25b6be55f17f3a6e.zip
qemu-376b851909d42c6faf4f780f25b6be55f17f3a6e.tar.gz
qemu-376b851909d42c6faf4f780f25b6be55f17f3a6e.tar.bz2
hppa: Add support for LASI chip with i82596 NIC
LASI is a built-in multi-I/O chip which supports serial, parallel, network (Intel i82596 Apricot), sound and other functionalities. LASI has been used in many HP PARISC machines. This patch adds the necessary parts to allow Linux and HP-UX to detect LASI and the network card. Signed-off-by: Helge Deller <deller@gmx.de> Signed-off-by: Sven Schnelle <svens@stackframe.org> Message-Id: <20191220211512.3289-3-svens@stackframe.org> Signed-off-by: Richard Henderson <richard.henderson@linaro.org>
Diffstat (limited to 'hw/hppa/machine.c')
-rw-r--r--hw/hppa/machine.c8
1 files changed, 7 insertions, 1 deletions
diff --git a/hw/hppa/machine.c b/hw/hppa/machine.c
index 5d0de26..33e3769 100644
--- a/hw/hppa/machine.c
+++ b/hw/hppa/machine.c
@@ -16,6 +16,7 @@
#include "hw/ide.h"
#include "hw/timer/i8254.h"
#include "hw/char/serial.h"
+#include "hw/net/lasi_82596.h"
#include "hppa_sys.h"
#include "qemu/units.h"
#include "qapi/error.h"
@@ -101,6 +102,9 @@ static void machine_hppa_init(MachineState *machine)
"ram", ram_size);
memory_region_add_subregion(addr_space, 0, ram_region);
+ /* Init Lasi chip */
+ lasi_init(addr_space);
+
/* Init Dino (PCI host bus chip). */
pci_bus = dino_init(addr_space, &rtc_irq, &serial_irq);
assert(pci_bus);
@@ -125,7 +129,9 @@ static void machine_hppa_init(MachineState *machine)
/* Network setup. e1000 is good enough, failing Tulip support. */
for (i = 0; i < nb_nics; i++) {
- pci_nic_init_nofail(&nd_table[i], pci_bus, "e1000", NULL);
+ if (!enable_lasi_lan()) {
+ pci_nic_init_nofail(&nd_table[i], pci_bus, "e1000", NULL);
+ }
}
/* Load firmware. Given that this is not "real" firmware,