return ret;
}
-static int
+static void
virSysinfoParsePPCProcessor(const char *base, virSysinfoDef *ret)
{
const char *cur;
}
}
-
- return 0;
}
/* virSysinfoRead for PowerPC
ret->nprocessor = 0;
ret->processor = NULL;
- if (virSysinfoParsePPCProcessor(outbuf, ret) < 0)
- return NULL;
+ virSysinfoParsePPCProcessor(outbuf, ret);
if (virSysinfoParsePPCSystem(outbuf, &ret->system) < 0)
return NULL;
return ret;
}
-static int
+static void
virSysinfoParseARMProcessor(const char *base, virSysinfoDef *ret)
{
const char *cur;
if (!(tmp_base = strstr(base, "model name")) &&
!(tmp_base = strstr(base, "Processor")))
- return 0;
+ return;
eol = strchr(tmp_base, '\n');
cur = strchr(tmp_base, ':') + 1;
}
VIR_FREE(processor_type);
- return 0;
+ return;
}
/* virSysinfoRead for ARMv7
ret->nprocessor = 0;
ret->processor = NULL;
- if (virSysinfoParseARMProcessor(outbuf, ret) < 0)
- return NULL;
+ virSysinfoParseARMProcessor(outbuf, ret);
if (virSysinfoParseARMSystem(outbuf, &ret->system) < 0)
return NULL;
return ret;
}
-static int
+static void
virSysinfoParseX86BaseBoard(const char *base,
virSysinfoBaseBoardDef **baseBoard,
size_t *nbaseBoard)
*nbaseBoard = nboards;
*baseBoard = g_steal_pointer(&boards);
- return 0;
}
}
-static int
+static void
virSysinfoParseX86Processor(const char *base, virSysinfoDef *ret)
{
const char *cur, *tmp_base;
base += strlen("Processor Information");
}
-
- return 0;
}
-static int
+static void
virSysinfoParseX86Memory(const char *base, virSysinfoDef *ret)
{
const char *cur, *tmp_base;
next:
base += strlen("Memory Device");
}
-
- return 0;
}
virSysinfoDef *
if (virSysinfoParseX86System(outbuf, &ret->system) < 0)
return NULL;
- if (virSysinfoParseX86BaseBoard(outbuf, &ret->baseBoard, &ret->nbaseBoard) < 0)
- return NULL;
+ virSysinfoParseX86BaseBoard(outbuf, &ret->baseBoard, &ret->nbaseBoard);
if (virSysinfoParseX86Chassis(outbuf, &ret->chassis) < 0)
return NULL;
ret->nprocessor = 0;
ret->processor = NULL;
- if (virSysinfoParseX86Processor(outbuf, ret) < 0)
- return NULL;
+ virSysinfoParseX86Processor(outbuf, ret);
ret->nmemory = 0;
ret->memory = NULL;
- if (virSysinfoParseX86Memory(outbuf, ret) < 0)
- return NULL;
+ virSysinfoParseX86Memory(outbuf, ret);
return g_steal_pointer(&ret);
}