dbus-sdr: implement SDR Record Type 8
- implement SDR Record Type 8 sensor like ipmi_entity_get_sdr function
in sensorhandler.cpp, and will locate at the last of SDR list
TEST:
~# ipmitool sdr elist all -vvv
...
...
...
SDR record ID : 0x00d9
SDR record type : 0x08
SDR record next : 0x00da
SDR record bytes: 11
Getting 11 bytes from SDR at offset 5
SDR record ID : 0x00d9
SDR record ID : 0x00da
SDR record type : 0x08
SDR record next : 0xffff
SDR record bytes: 11
Getting 11 bytes from SDR at offset 5
SDR record ID : 0x00da
~# ipmitool raw 0x04 0x21 0x00 0x00 0xd9 0x00 0x00 0xff
da 00 d9 00 51 08 0b 1e 00 80 0b 03 0b 07 1d 00
1d 01
~# ipmitool raw 0x04 0x21 0x00 0x00 0xda 0x00 0x00 0xff
ff ff da 00 51 08 0b 1e 01 80 0b 08 0b 0b 1d 02
1d 03
Signed-off-by: Harvey Wu <Harvey.Wu@quantatw.com>
Change-Id: I4998532402158f299dcb34c29734b23b5f8dc719
diff --git a/include/dbus-sdr/storagecommands.hpp b/include/dbus-sdr/storagecommands.hpp
index d0fa110..79feb56 100644
--- a/include/dbus-sdr/storagecommands.hpp
+++ b/include/dbus-sdr/storagecommands.hpp
@@ -107,6 +107,9 @@
ipmi_ret_t getFruSdrCount(ipmi::Context::ptr ctx, size_t& count);
+std::vector<uint8_t>
+ getType8SDRs(ipmi::sensor::EntityInfoMap::const_iterator& entity,
+ uint16_t recordId);
std::vector<uint8_t> getType12SDRs(uint16_t index, uint16_t recordId);
std::vector<uint8_t> getNMDiscoverySDR(uint16_t index, uint16_t recordId);
} // namespace storage