blob: dbfade4a518cda2d786527f59aadd51bd2640676 [file] [log] [blame]
William A. Kennington III194375f2018-12-14 02:14:33 -08001#include <ipmid/api.h>
Patrick Venture0b02be92018-08-31 11:55:55 -07002
Patrick Ventureb51bf9c2018-09-10 15:53:14 -07003#include <cstdio>
4
Chris Austenc2cd29d2016-02-05 20:02:29 -06005#define GRPEXT_GET_GROUP_CMD 0
6void register_netfn_groupext_functions() __attribute__((constructor));
7
8ipmi_ret_t ipmi_groupext(ipmi_netfn_t netfn, ipmi_cmd_t cmd,
Patrick Venture0b02be92018-08-31 11:55:55 -07009 ipmi_request_t request, ipmi_response_t response,
10 ipmi_data_len_t data_len, ipmi_context_t context)
Chris Austenc2cd29d2016-02-05 20:02:29 -060011{
Patrick Venture0b02be92018-08-31 11:55:55 -070012 // Generic return from IPMI commands.
Chris Austenc2cd29d2016-02-05 20:02:29 -060013 ipmi_ret_t rc = IPMI_CC_OK;
Patrick Venture0b02be92018-08-31 11:55:55 -070014 uint8_t* p = (uint8_t*)response;
Chris Austenc2cd29d2016-02-05 20:02:29 -060015
Patrick Ventureb51bf9c2018-09-10 15:53:14 -070016 std::printf("IPMI GROUP EXTENSIONS\n");
Chris Austenc2cd29d2016-02-05 20:02:29 -060017
18 *data_len = 1;
19 *p = 0;
20
21 return rc;
22}
23
24void register_netfn_groupext_functions()
25{
Tom05732372016-09-06 17:21:23 +053026 // <Group Extension Command>
Patrick Venture0b02be92018-08-31 11:55:55 -070027 ipmi_register_callback(NETFUN_GRPEXT, GRPEXT_GET_GROUP_CMD, NULL,
28 ipmi_groupext, PRIVILEGE_USER);
Chris Austenc2cd29d2016-02-05 20:02:29 -060029
30 return;
31}