summaryrefslogtreecommitdiff
path: root/hw/i386
diff options
context:
space:
mode:
authorPaulo Alcantara <pcacjr@gmail.com>2015-06-28 14:58:56 -0300
committerMichael S. Tsirkin <mst@redhat.com>2015-07-07 13:12:22 +0300
commit920557971b60e53c2f3f22e5d6c620ab1ed411fd (patch)
tree5630d4b1c74b28ba22273d5980ecedcbe367fa38 /hw/i386
parent71ba2f0af398f616e154137d9fdda25c2da01324 (diff)
downloadqemu-920557971b60e53c2f3f22e5d6c620ab1ed411fd.tar.gz
qemu-920557971b60e53c2f3f22e5d6c620ab1ed411fd.tar.bz2
qemu-920557971b60e53c2f3f22e5d6c620ab1ed411fd.zip
ich9: add TCO interface emulation
This interface provides some registers within a 32-byte range and can be acessed through PCI-to-LPC bridge interface (PMBASE + 0x60). It's commonly used as a watchdog timer to detect system lockups through SMIs that are generated -- if TCO_EN bit is set -- on every timeout. If NO_REBOOT bit is not set in GCS (General Control and Status register), the system will be resetted upon second timeout if TCO_RLD register wasn't previously written to prevent timeout. This patch adds support to TCO watchdog logic and few other features like mapping NMIs to SMIs (NMI2SMI_EN bit), system intruder detection, etc. are not implemented yet. Signed-off-by: Paulo Alcantara <pcacjr@zytor.com> Reviewed-by: Michael S. Tsirkin <mst@redhat.com> Signed-off-by: Michael S. Tsirkin <mst@redhat.com>
Diffstat (limited to 'hw/i386')
-rw-r--r--hw/i386/pc_q35.c4
1 files changed, 3 insertions, 1 deletions
diff --git a/hw/i386/pc_q35.c b/hw/i386/pc_q35.c
index 8aa3a67fdf..24ee08657d 100644
--- a/hw/i386/pc_q35.c
+++ b/hw/i386/pc_q35.c
@@ -253,7 +253,7 @@ static void pc_q35_init(MachineState *machine)
(pc_machine->vmport != ON_OFF_AUTO_ON), 0xff0104);
/* connect pm stuff to lpc */
- ich9_lpc_pm_init(lpc, pc_machine_is_smm_enabled(pc_machine));
+ ich9_lpc_pm_init(lpc, pc_machine_is_smm_enabled(pc_machine), !mc->no_tco);
/* ahci and SATA device, for q35 1 ahci controller is built-in */
ahci = pci_create_simple_multifunction(host_bus,
@@ -397,6 +397,7 @@ static void pc_q35_2_4_machine_options(MachineClass *m)
m->default_machine_opts = "firmware=bios-256k.bin";
m->default_display = "std";
m->no_floppy = 1;
+ m->no_tco = 0;
m->alias = "q35";
}
@@ -408,6 +409,7 @@ static void pc_q35_2_3_machine_options(MachineClass *m)
{
pc_q35_2_4_machine_options(m);
m->no_floppy = 0;
+ m->no_tco = 1;
m->alias = NULL;
SET_MACHINE_COMPAT(m, PC_COMPAT_2_3);
}