Lines Matching defs:def
56 convert_field(const uint8_t *field, const fru_regdef_t *def, const char *path,
64 switch (def->dataType) {
66 assert(def->payloadLen <= sizeof (value));
67 switch (def->dispType) {
70 if (def->payloadLen > sizeof (timefield)) {
92 sizeof (value) - def->payloadLen),
93 field, def->payloadLen);
95 switch (def->payloadLen) {
121 def->payloadLen), field, def->payloadLen);
123 for (i = 0; i < def->enumCount; i++) {
124 if (def->enumTable[i].value == value) {
126 def->enumTable[i].text);
134 def->payloadLen);
140 convert_element(const uint8_t *data, const fru_regdef_t *def, char *ppath,
147 if ((def->iterationCount == 0) &&
148 (def->iterationType != FRU_NOT_ITERATED)) {
151 path = (char *)def->name;
155 if (def->iterationCount) {
162 iterlen = (def->payloadLen - NUM_ITER_BYTES) /
163 def->iterationCount;
169 (void) memcpy(&newdef, def, sizeof (newdef));
174 if ((data[HEAD_ITER] >= def->iterationCount) ||
175 (data[NUM_ITER] > def->iterationCount) ||
176 (data[MAX_ITER] != def->iterationCount)) {
179 num = def->iterationCount;
189 i = ((i + 1) % def->iterationCount), n++) {
198 } else if (def->dataType == FDTYPE_Record) {
210 for (i = 0; i < def->enumCount; i++,
213 def->enumTable[i].text);
221 convert_field(data, def, path, nv);
259 const fru_regdef_t *def;
286 } else if ((def = fru_reg_lookup_def_by_tag(*tag)) == NULL) {
303 convert_element(payload, def, "", nv, B_FALSE);