1 /* 2 * Copyright (C) 2003-2015 FreeIPMI Core Team 3 * 4 * This program is free software: you can redistribute it and/or modify 5 * it under the terms of the GNU General Public License as published by 6 * the Free Software Foundation, either version 3 of the License, or 7 * (at your option) any later version. 8 * 9 * This program is distributed in the hope that it will be useful, 10 * but WITHOUT ANY WARRANTY; without even the implied warranty of 11 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 12 * GNU General Public License for more details. 13 * 14 * You should have received a copy of the GNU General Public License 15 * along with this program. If not, see <http://www.gnu.org/licenses/>. 16 * 17 */ 18 19 #ifndef IPMI_FRU_INVENTORY_DEVICE_CMDS_TEMPLATES_H 20 #define IPMI_FRU_INVENTORY_DEVICE_CMDS_TEMPLATES_H 21 22 #ifdef __cplusplus 23 extern "C" { 24 #endif 25 26 /* This header file is for documentation only */ 27 28 #if 0 29 30 Please see fiid.h for details concerning the fiid interface. 31 32 The following list the configurable fields of individual packet/record 33 templates in FreeIPMI. Each field is listed as a list of the 34 following. 35 36 { bits, "field name", field flag, field flag, ... } 37 38 bits - indicates the number of bits in the field 39 40 field name - indicates the name of the field, used for getting/setting 41 fields in the fiid API. 42 43 field flags - flags indicating qualities of the field. The following 44 qualities may exist for each field. 45 46 REQUIRED - field is required for the packet/record 47 OPTIONAL - field is optional for the packet/record 48 49 LENGTH-FIXED - field length is fixed at the number of bits listed 50 51 LENGTH-VARIABLE - field length is variable for the number of bits 52 listed 53 54 MAKES-PACKET-SUFFICIENT - indicates field or fields are 55 "sufficient" to make a packet/record valid 56 and not malformed, but not necessarily a 57 complete packet/record. 58 59 Get FRU Inventory Area Info Request 60 ----------------------------------- 61 62 FIID Template: tmpl_cmd_get_fru_inventory_area_info_rq 63 64 { 8, "cmd", REQUIRED, LENGTH-FIXED } 65 { 8, "fru_device_id", REQUIRED, LENGTH-FIXED } 66 67 Get FRU Inventory Area Info Response 68 ------------------------------------ 69 70 FIID Template: tmpl_cmd_get_fru_inventory_area_info_rs 71 72 { 8, "cmd", REQUIRED, LENGTH-FIXED, MAKES-PACKET-SUFFICIENT } 73 { 8, "comp_code", REQUIRED, LENGTH-FIXED, MAKES-PACKET-SUFFICIENT } 74 { 16, "fru_inventory_area_size", REQUIRED, LENGTH-FIXED } 75 { 1, "device_is_accessed", REQUIRED, LENGTH-FIXED } 76 { 7, "reserved", REQUIRED, LENGTH-FIXED } 77 78 Read FRU Data Request 79 --------------------- 80 81 FIID Template: tmpl_cmd_read_fru_data_rq 82 83 { 8, "cmd", REQUIRED, LENGTH-FIXED } 84 { 8, "fru_device_id", REQUIRED, LENGTH-FIXED } 85 { 16, "fru_inventory_offset_to_read", REQUIRED, LENGTH-FIXED } 86 { 8, "count_to_read", REQUIRED, LENGTH-FIXED } 87 88 Read FRU Data Response 89 ---------------------- 90 91 FIID Template: tmpl_cmd_read_fru_data_rs 92 93 { 8, "cmd", REQUIRED, LENGTH-FIXED, MAKES-PACKET-SUFFICIENT } 94 { 8, "comp_code", REQUIRED, LENGTH-FIXED, MAKES-PACKET-SUFFICIENT } 95 { 8, "count_returned", REQUIRED, LENGTH-FIXED } 96 { 2040, "requested_data", OPTIONAL, LENGTH-VARIABLE } 97 98 Write FRU Data Request 99 ---------------------- 100 101 FIID Template: tmpl_cmd_write_fru_data_rq 102 103 { 8, "cmd", REQUIRED, LENGTH-FIXED } 104 { 8, "fru_device_id", REQUIRED, LENGTH-FIXED } 105 { 16, "fru_inventory_offset_to_write", REQUIRED, LENGTH-FIXED } 106 { 2040, "data_to_write", REQUIRED, LENGTH-VARIABLE } 107 108 Write FRU Data Response 109 ----------------------- 110 111 FIID Template: tmpl_cmd_write_fru_data_rs 112 113 { 8, "cmd", REQUIRED, LENGTH-FIXED, MAKES-PACKET-SUFFICIENT } 114 { 8, "comp_code", REQUIRED, LENGTH-FIXED, MAKES-PACKET-SUFFICIENT } 115 { 8, "count_written", REQUIRED, LENGTH-FIXED } 116 117 #endif /* 0 */ 118 119 #ifdef __cplusplus 120 } 121 #endif 122 123 #endif /* IPMI_FRU_INVENTORY_DEVICE_CMDS_TEMPLATES_H */ 124