summaryrefslogtreecommitdiffstats
path: root/transporthandler.hpp
diff options
context:
space:
mode:
authorRatan Gupta <ratagupt@in.ibm.com>2017-07-27 07:07:48 +0530
committerRatan Gupta <ratagupt@in.ibm.com>2017-08-13 06:46:22 +0530
commitb8e9955db5216a0b170a2fb99125d1f22bb9d1c0 (patch)
tree122efef97394c3af93b4dc4bbc35fdef2a24c129 /transporthandler.hpp
parent8c31d237f67caa5698fca5aedd449f8c98f0b0c0 (diff)
downloadphosphor-host-ipmid-b8e9955db5216a0b170a2fb99125d1f22bb9d1c0.tar.gz
phosphor-host-ipmid-b8e9955db5216a0b170a2fb99125d1f22bb9d1c0.zip
Move LAN handling commands to the new xyz interfaces
Change-Id: I4631c79c171883e5f0d531cfb5957a09496e4b3a Signed-off-by: Ratan Gupta <ratagupt@in.ibm.com>
Diffstat (limited to 'transporthandler.hpp')
-rw-r--r--transporthandler.hpp41
1 files changed, 41 insertions, 0 deletions
diff --git a/transporthandler.hpp b/transporthandler.hpp
new file mode 100644
index 0000000..f1fd410
--- /dev/null
+++ b/transporthandler.hpp
@@ -0,0 +1,41 @@
+#pragma once
+
+#include <string>
+
+// IPMI commands for Transport net functions.
+enum ipmi_netfn_storage_cmds
+{
+ // Get capability bits
+ IPMI_CMD_SET_LAN = 0x01,
+ IPMI_CMD_GET_LAN = 0x02,
+};
+
+// Command specific completion codes
+enum ipmi_transport_return_codes
+{
+ IPMI_CC_PARM_NOT_SUPPORTED = 0x80,
+};
+
+// Parameters
+static const int LAN_PARM_INPROGRESS = 0;
+static const int LAN_PARM_AUTHSUPPORT = 1;
+static const int LAN_PARM_AUTHENABLES = 2;
+static const int LAN_PARM_IP = 3;
+static const int LAN_PARM_MAC = 5;
+static const int LAN_PARM_SUBNET = 6;
+static const int LAN_PARM_GATEWAY = 12;
+
+struct ChannelConfig_t
+{
+ std::string ipaddr;
+ std::string netmask;
+ std::string gateway;
+ std::string macAddress;
+ void clear()
+ {
+ ipaddr.clear();
+ netmask.clear();
+ gateway.clear();
+ macAddress.clear();
+ }
+};
OpenPOWER on IntegriCloud