File: cmd_chassis_reset.go

package info (click to toggle)
golang-github-bougou-go-ipmi 0.7.8-1
  • links: PTS, VCS
  • area: main
  • in suites: forky, sid
  • size: 1,880 kB
  • sloc: makefile: 38
file content (42 lines) | stat: -rw-r--r-- 945 bytes parent folder | download | duplicates (2)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
package ipmi

import "context"

// 28.4 Chassis Reset Command
type ChassisResetRequest struct {
	// empty
}

type ChassisResetResponse struct {
	// empty
}

func (req *ChassisResetRequest) Pack() []byte {
	return []byte{}
}

func (req *ChassisResetRequest) Command() Command {
	return CommandChassisReset
}

func (res *ChassisResetResponse) CompletionCodes() map[uint8]string {
	return map[uint8]string{}
}

func (res *ChassisResetResponse) Unpack(msg []byte) error {
	return nil
}

func (res *ChassisResetResponse) Format() string {
	return ""
}

// This command was used with early versions of the ICMB.
// It has been superseded by the Chassis Control command
// For host systems, this corresponds to a system hard reset.
func (c *Client) ChassisReset(ctx context.Context) (response *ChassisResetResponse, err error) {
	request := &ChassisResetRequest{}
	response = &ChassisResetResponse{}
	err = c.Exchange(ctx, request, response)
	return
}