1
0
mirror of https://gitlab.com/libvirt/libvirt.git synced 2024-12-22 17:34:18 +03:00

virsysinfo: Rename virSysinfoReadX86 to virSysinfoReadDMI

There's nothing x86 specific about this function. Rename the
function so that it has DMI suffix which enables it to be reused
on different arches (as using X86 from say ARM would look
suspicious).

Signed-off-by: Michal Privoznik <mprivozn@redhat.com>
Reviewed-by: Andrea Bolognani <abologna@redhat.com>
This commit is contained in:
Michal Privoznik 2019-05-10 14:08:09 +02:00
parent 667a373526
commit ac61c9cfc3
4 changed files with 5 additions and 5 deletions

View File

@ -3070,9 +3070,9 @@ virSysinfoSystemDefFree;
# util/virsysinfopriv.h
virSysinfoReadARM;
virSysinfoReadDMI;
virSysinfoReadPPC;
virSysinfoReadS390;
virSysinfoReadX86;
# util/virsystemd.h

View File

@ -1139,7 +1139,7 @@ virSysinfoParseX86Memory(const char *base, virSysinfoDefPtr ret)
}
virSysinfoDefPtr
virSysinfoReadX86(void)
virSysinfoReadDMI(void)
{
char *path;
virSysinfoDefPtr ret = NULL;
@ -1220,7 +1220,7 @@ virSysinfoRead(void)
(defined(__x86_64__) || \
defined(__i386__) || \
defined(__amd64__))
return virSysinfoReadX86();
return virSysinfoReadDMI();
#else /* WIN32 || not supported arch */
/*
* this can probably be extracted from Windows using API or registry

View File

@ -39,6 +39,6 @@ virSysinfoDefPtr
virSysinfoReadS390(void);
virSysinfoDefPtr
virSysinfoReadX86(void);
virSysinfoReadDMI(void);
#endif /* LIBVIRT_VIRSYSINFOPRIV_H */

View File

@ -133,7 +133,7 @@ mymain(void)
TEST("s390", virSysinfoReadS390);
TEST("s390-freq", virSysinfoReadS390);
TEST("ppc", virSysinfoReadPPC);
TEST_FULL("x86", virSysinfoReadX86, "/sysinfodata/x86dmidecode.sh");
TEST_FULL("x86", virSysinfoReadDMI, "/sysinfodata/x86dmidecode.sh");
TEST("arm", virSysinfoReadARM);
TEST("arm-rpi2", virSysinfoReadARM);
TEST("aarch64", virSysinfoReadARM);