Fix Get Payload Data failing for type 0 and 5 files.

Issue: Get Payload Data for type 0 and type 5 is giving command response
error(0xce).

Fix: Added validation code to get response data.

Tested:
Before Fix:
Command: ipmitool raw 0x30 0xd6 1 5 0 0 0 0 0x44 0 0 0
Response:
Unable to send RAW command (channel=0x0 netfn=0x30 lun=0x0 cmd=0xd6
rsp=0xce): Command response could not be provided

After Fix:
Case-1: For Payload type 0
Command: Get Payload Info
ipmitool raw 0x30 0xd6 0x0 0x0
Response :
 00 00 00 47 36 04 00 62 c8 b8 62 00 01 3a 43 a9
 61
Command: Get Payload Data
ipmitool raw 0x30 0xd6 1 0 0 0 0 0 0x08 0 0 0
Response:
 00 08 00 00 00 06 bb c3 29 5d 00 00 00 01 22 54
 ac
Case-2: For Payload type 5
1. Create Payload 5
Command: Set Payload Start Info
ipmitool raw 0x30 0xd5 0 5 0 0 0x44 0 0 0 0xc 0xab 0xc2 0x53 0x0
Response: Success with Reservation ID
Command: Set Payload In Progress
ipmitool raw 0x30 0xd5 1 5 <ReservationID> 0 0 0 0 0x44 0 0 0 0xc 0xab
0xc2 0x53 0x50 0x58 0x4F 0x24 0x44 00 0x20 00 0x02 0x4E 0x81 00 0x03 00
0x03 0xF8 0x02 00 00 0x79 0x18 00 0x04 00 0x07 00 00 00 00 00 00 00
0x02 0x24 00 00 0xE8 0x7E 0xF8 0x83 0x06 00 00 00 00 00 00 00 00 00 00
00 00 0x7F 00 0x07 00 00 0x81 00 00 00 00 00 00 00 00 00
Response: Success
Command: Set Payload End Transfer
ipmitool raw 0x30 0xd5 2 5 <ReservationID>
Response: Success
2. Reboot BMC
3. Check for Payload 5 file in /var/oob folder
4. Check with Get Payload
Command: Get Payload Info
ipmitool raw 0x30 0xd6 0 5
Response:
 00 00 05 44 00 00 00 0c ab c2 53 00 01 fc 43 a9
 61
Command: Get Payload Data
ipmitool raw 0x30 0xd6 1 5 0 0 0 0 0x44 0 0 0
Response: Success with data

Signed-off-by: Snehalatha Venkatesh <snehalathax.v@intel.com>
Change-Id: I198fa005f1732f80d5eb94550ab6cabd0f3754be
1 file changed
tree: 31f479e674fe5c96cb45dde8e34ebf09af44cdf8
  1. cmake/
  2. docs/
  3. include/
  4. non-yocto/
  5. src/
  6. tests/
  7. .clang-format
  8. .gitignore
  9. cmake-format.json
  10. CMakeLists.txt
  11. CMakeLists.txt.in
  12. generate-whitelist.py
  13. ipmi-whitelist.conf
  14. LICENSE
  15. MAINTAINERS
  16. OWNERS
  17. README.md
README.md

Intel IPMI OEM support library

This component is intended to provide Intel-specific IPMI[3] command handlers for OpenBMC. These handlers are intended to integrate BMC with servers based on Intel architecture.

Overview

intel-ipmi-oem serves as an extension[1] to OpenBMC IPMI daemon[2]. It is compiled as a shared library and intended to both:

  • override existing implementation of standard IPMI commands to comply with Intel-specific solutions,
  • provide implementation for non-standard OEM extensions.

Capabilities

Related features provided by the library are grouped in separate source files. Main extensions to vanilla OpenBMC IPMI stack are the following:

  • Acquiring SMBIOS data over IPMI
  • Commands for better integration with Intel hardware
  • Firmware update extensions
  • Extended parsing of IPMI Platform Events[4]

References

  1. OpenBMC IPMI Architecture
  2. Phosphor IPMI Host
  3. IPMI Specification v2.0
  4. Intel Platform Events parsing