mirror of
https://gitlab.com/libvirt/libvirt.git
synced 2025-02-22 19:32:19 +00:00
AArch64: Parse cputopology from /proc/cpuinfo.
CPU "parser" for AArch64. Showing cputopology in arm64 linux is work-in-progress so for now all AArch64 cpus belong to same socket (like PPC). Also we parse BogoMIPS same like arm 32bit. Signed-off-by: Anup Patel <anup.patel@linaro.org> Signed-off-by: Pranavkumar Sawargaonkar <pranavkumar@linaro.org>
This commit is contained in:
parent
5cb6816715
commit
950127620d
@ -205,7 +205,8 @@ virNodeParseSocket(const char *dir, unsigned int cpu)
|
|||||||
# if defined(__powerpc__) || \
|
# if defined(__powerpc__) || \
|
||||||
defined(__powerpc64__) || \
|
defined(__powerpc64__) || \
|
||||||
defined(__s390__) || \
|
defined(__s390__) || \
|
||||||
defined(__s390x__)
|
defined(__s390x__) || \
|
||||||
|
defined(__aarch64__)
|
||||||
/* ppc and s390(x) has -1 */
|
/* ppc and s390(x) has -1 */
|
||||||
if (ret < 0)
|
if (ret < 0)
|
||||||
ret = 0;
|
ret = 0;
|
||||||
@ -441,7 +442,7 @@ int linuxNodeInfoCPUPopulate(FILE *cpuinfo,
|
|||||||
* and parsed in next iteration, because it is not in expected
|
* and parsed in next iteration, because it is not in expected
|
||||||
* format and thus lead to error. */
|
* format and thus lead to error. */
|
||||||
}
|
}
|
||||||
# elif defined(__arm__)
|
# elif defined(__arm__) || defined(__aarch64__)
|
||||||
char *buf = line;
|
char *buf = line;
|
||||||
if (STRPREFIX(buf, "BogoMIPS")) {
|
if (STRPREFIX(buf, "BogoMIPS")) {
|
||||||
char *p;
|
char *p;
|
||||||
|
Loading…
x
Reference in New Issue
Block a user