oemcommands: Update USB debug command to get FRU data
Use dbus call to get FRU path instead of just "baseboard".
Change-Id: Icf940ea9221da46a4424a2b439ce021dd48daf3e
Signed-off-by: Daniel Hsu <Daniel-Hsu@quantatw.com>
diff --git a/src/usb-dbg.cpp b/src/usb-dbg.cpp
index bb2052e..78fff85 100644
--- a/src/usb-dbg.cpp
+++ b/src/usb-dbg.cpp
@@ -21,6 +21,7 @@
{
ipmi_ret_t getNetworkData(uint8_t lan_param, char* data);
+std::string getMotherBoardFruName();
int8_t getFruData(std::string& serial, std::string& name);
int8_t sysConfig(std::vector<std::string>& data, size_t pos);
int8_t procInfo(std::string& result, size_t pos);
@@ -654,7 +655,8 @@
getMaxHostPosition(maxPosition);
if (hostPosition == BMC_POSITION || hostInstances == "0")
{
- frame_info.append("FRU:spb");
+ std::string data = "FRU:" + getMotherBoardFruName();
+ frame_info.append(data);
}
else if (hostPosition != BMC_POSITION && hostPosition <= maxPosition)
{