blob: 66d02f822077c7d2432031b551de53b2695cff02 [file] [log] [blame]
Vernon Mauerye08fbff2019-04-03 09:19:34 -07001#include <ipmid/api.hpp>
Patrick Ventureb51bf9c2018-09-10 15:53:14 -07002
Patrick Williamsfbc6c9d2023-05-10 07:50:16 -05003#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
Willy Tu11d68892022-01-20 10:37:34 -08008ipmi_ret_t ipmi_groupext(ipmi_netfn_t, ipmi_cmd_t, ipmi_request_t,
9 ipmi_response_t response, ipmi_data_len_t data_len,
10 ipmi_context_t)
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}