diff options
author | Joel Stanley <joel@jms.id.au> | 2015-04-09 13:00:07 +0930 |
---|---|---|
committer | Stewart Smith <stewart@linux.vnet.ibm.com> | 2015-04-09 14:00:55 +1000 |
commit | 4a574d2bbf3779a409fac9c46d4ab44b40a1803d (patch) | |
tree | 9df218adef96ae4e170dee020ba10b52f3ff2780 /hw/ipmi | |
parent | 3e3ed2e52e27d9b3fff7eb3cac97f943a686359a (diff) | |
download | talos-skiboot-4a574d2bbf3779a409fac9c46d4ab44b40a1803d.tar.gz talos-skiboot-4a574d2bbf3779a409fac9c46d4ab44b40a1803d.zip |
hw/ipmi: Fix FW Boot Progress sensor
Experiments determined that we need to set the assertion bits as well as
the event data bytes.
To verify the sensor is being set on your BMC, use ipmitool to query the
SEL logs:
$ ipmitool sel list
System Firmware Progress #0x05 | Motherboard initialization | Asserted
System Firmware Progress #0x05 | Memory initialization | Asserted
System Firmware Progress #0x05 | System boot initiated | Asserted
Signed-off-by: Joel Stanley <joel@jms.id.au>
Acked-by: Jeremy Kerr <jk@ozlabs.org>
Signed-off-by: Stewart Smith <stewart@linux.vnet.ibm.com>
Diffstat (limited to 'hw/ipmi')
-rw-r--r-- | hw/ipmi/ipmi-sensor.c | 8 |
1 files changed, 3 insertions, 5 deletions
diff --git a/hw/ipmi/ipmi-sensor.c b/hw/ipmi/ipmi-sensor.c index 7d88637f..d890534f 100644 --- a/hw/ipmi/ipmi-sensor.c +++ b/hw/ipmi/ipmi-sensor.c @@ -21,8 +21,6 @@ #include <string.h> #define IPMI_WRITE_SENSOR (1 << 0) -#define IPMI_WRITE_EVENT_BYTES (1 << 7) -#define IPMI_SET_ASSERTION (1 << 4) #define FW_PROGRESS_SENSOR_TYPE 0x0F #define BOOT_COUNT_SENSOR_TYPE 0xC3 @@ -85,11 +83,11 @@ int ipmi_set_fw_progress_sensor(uint8_t state) memset(&request, 0, sizeof(request)); request.sensor_number = fw_sensor_num; - request.operation = IPMI_WRITE_EVENT_BYTES; - request.assertion_mask[0] = 0x02; /* Firmware progress offset */ + request.operation = 0xa0; /* Set event data bytes, assertion bits */ + request.assertion_mask[0] = 0x04; /* Firmware progress offset */ request.event_data[1] = state; - prlog(PR_INFO, "IPMI: fw progress sensor (%02x) to %02x ...\n", + prlog(PR_INFO, "IPMI: setting fw progress sensor %02x to %02x\n", request.sensor_number, request.event_data[1]); msg = ipmi_mkmsg_simple(IPMI_SET_SENSOR_READING, &request, |