From cdaabfdbec148d9ce85f422507c596a8ae6ced08 Mon Sep 17 00:00:00 2001 From: Thi Tran Date: Sat, 11 Jun 2011 15:49:38 -0500 Subject: Initial XSCOM delivery Change-Id: I80278bf2e03b4e6403d9a36b8782b225dba29fe3 Reviewed-on: http://gfw160.austin.ibm.com:8080/gerrit/144 Tested-by: Jenkins Server Reviewed-by: MIKE J. JONES Reviewed-by: A. Patrick Williams III --- src/include/usr/devicefw/driverif.H | 7 +++++++ src/include/usr/hbotcompid.H | 15 +++++++++++++++ src/include/usr/xscom/xscomreasoncodes.H | 22 ++++++++++++++++++++++ 3 files changed, 44 insertions(+) create mode 100644 src/include/usr/xscom/xscomreasoncodes.H (limited to 'src/include/usr') diff --git a/src/include/usr/devicefw/driverif.H b/src/include/usr/devicefw/driverif.H index a3c5b37b6..c7f094d8a 100644 --- a/src/include/usr/devicefw/driverif.H +++ b/src/include/usr/devicefw/driverif.H @@ -56,6 +56,13 @@ namespace DeviceFW WILDCARD = -1, }; + /** Construct the device addressing parameters for XSCOM device ops. + * @param[in] i_address - XSCom address to operate on. + */ + #define DEVICE_XSCOM_ADDRESS(i_address) \ + DeviceFW::XSCOM, static_cast((i_address)) + + /** @class InvalidParameterType * @brief Unused type to cause compiler fails for invalid template types. * diff --git a/src/include/usr/hbotcompid.H b/src/include/usr/hbotcompid.H index b99e91c35..e6be3adc8 100644 --- a/src/include/usr/hbotcompid.H +++ b/src/include/usr/hbotcompid.H @@ -46,5 +46,20 @@ const compId_t DEVFW_COMP_ID = 0x0200; const char DEVFW_COMP_NAME[] = "devfw"; //@} +/** @name SCOM + * SCOM component + */ +//@{ +const compId_t SCOM_COMP_ID = 0x0300; +const char SCOM_COMP_NAME[] = "scom"; +//@} + +/** @name XSCOM + * XSCOM component + */ +//@{ +const compId_t XSCOM_COMP_ID = 0x0400; +const char XSCOM_COMP_NAME[] = "xscom"; +//@} #endif diff --git a/src/include/usr/xscom/xscomreasoncodes.H b/src/include/usr/xscom/xscomreasoncodes.H new file mode 100644 index 000000000..552b517e9 --- /dev/null +++ b/src/include/usr/xscom/xscomreasoncodes.H @@ -0,0 +1,22 @@ +#ifndef __XSCOM_REASONCODES_H +#define __XSCOM_REASONCODES_H + +#include + +namespace XSCOM +{ + enum xscomModuleId + { + XSCOM_PERFORM_OP = 0x00, + XSCOM_SANITY_CHECK = 0x01, + }; + + enum xscomReasonCode + { + XSCOM_STATUS_ERR = XSCOM_COMP_ID | 0x01, + XSCOM_INVALID_DATA_BUFFER = XSCOM_COMP_ID | 0x02, + XSCOM_INVALID_OP_TYPE = XSCOM_COMP_ID | 0x03, + }; +}; + +#endif -- cgit v1.2.3