github.com/mvdan/u-root-coreutils@v0.0.0-20230122170626-c2eef2898555/pkg/ipmi/constants.go (about)

     1  // Copyright 2022 the u-root Authors. All rights reserved
     2  // Use of this source code is governed by a BSD-style
     3  // license that can be found in the LICENSE file.
     4  
     5  package ipmi
     6  
     7  const (
     8  	_IPMI_BMC_CHANNEL                = 0xf
     9  	_IPMI_BUF_SIZE                   = 1024
    10  	_IPMI_IOC_MAGIC                  = 'i'
    11  	_IPMI_OPENIPMI_READ_TIMEOUT      = 15
    12  	_IPMI_SYSTEM_INTERFACE_ADDR_TYPE = 0x0c
    13  
    14  	// Net functions
    15  	_IPMI_NETFN_CHASSIS   NetFn = 0x0
    16  	_IPMI_NETFN_APP       NetFn = 0x6
    17  	_IPMI_NETFN_STORAGE   NetFn = 0xA
    18  	_IPMI_NETFN_TRANSPORT NetFn = 0xC
    19  
    20  	// IPM Device "Global" Commands
    21  	BMC_GET_DEVICE_ID Command = 0x01
    22  
    23  	// BMC Device and Messaging Commands
    24  	BMC_SET_WATCHDOG_TIMER     Command = 0x24
    25  	BMC_GET_WATCHDOG_TIMER     Command = 0x25
    26  	BMC_SET_GLOBAL_ENABLES     Command = 0x2E
    27  	BMC_GET_GLOBAL_ENABLES     Command = 0x2F
    28  	SET_SYSTEM_INFO_PARAMETERS Command = 0x58
    29  	BMC_ADD_SEL                Command = 0x44
    30  
    31  	// Chassis Device Commands
    32  	BMC_GET_CHASSIS_STATUS Command = 0x01
    33  
    34  	// SEL device Commands
    35  	BMC_GET_SEL_INFO Command = 0x40
    36  
    37  	// LAN Device Commands
    38  	BMC_GET_LAN_CONFIG Command = 0x02
    39  
    40  	IPM_WATCHDOG_NO_ACTION    = 0x00
    41  	IPM_WATCHDOG_SMS_OS       = 0x04
    42  	IPM_WATCHDOG_CLEAR_SMS_OS = 0x10
    43  
    44  	ADTL_SEL_DEVICE         = 0x04
    45  	EN_SYSTEM_EVENT_LOGGING = 0x08
    46  
    47  	// SEL
    48  	// STD_TYPE  = 0x02
    49  	OEM_NTS_TYPE = 0xFB
    50  
    51  	_SYSTEM_INFO_BLK_SZ = 16
    52  
    53  	_SYSTEM_FW_VERSION = 1
    54  
    55  	_ASCII = 0
    56  
    57  	// Set 62 Bytes (4 sets) as the maximal string length
    58  	strlenMax = 62
    59  )