cpu: Rename {powerpc,ppc} => ppc64 (exported symbols)

Only the symbols exported by the driver have been updated;
the driver implementation itself still uses the old names
internally.

No functional changes.
This commit is contained in:
Andrea Bolognani 2015-07-20 14:35:22 +02:00
parent ef770f0160
commit e89733c4a4
5 changed files with 21 additions and 21 deletions

View File

@ -44,7 +44,7 @@ VIR_LOG_INIT("cpu.cpu");
static struct cpuArchDriver *drivers[] = {
&cpuDriverX86,
&cpuDriverPowerPC,
&cpuDriverPPC64,
&cpuDriverS390,
&cpuDriverArm,
&cpuDriverAARCH64,

View File

@ -38,7 +38,7 @@ struct _virCPUData {
virArch arch;
union {
virCPUx86Data *x86;
struct cpuPPCData ppc;
struct cpuPPC64Data ppc64;
/* generic driver needs no data */
} data;
};

View File

@ -1,5 +1,5 @@
/*
* cpu_ppc64.c: CPU driver for PowerPC CPUs
* cpu_ppc64.c: CPU driver for 64-bit PowerPC CPUs
*
* Copyright (C) 2013 Red Hat, Inc.
* Copyright (C) IBM Corporation, 2010
@ -36,7 +36,7 @@
#define VIR_FROM_THIS VIR_FROM_CPU
VIR_LOG_INIT("cpu.cpu_powerpc");
VIR_LOG_INIT("cpu.cpu_ppc64");
static const virArch archs[] = { VIR_ARCH_PPC64, VIR_ARCH_PPC64LE };
@ -48,7 +48,7 @@ struct ppc_vendor {
struct ppc_model {
char *name;
const struct ppc_vendor *vendor;
struct cpuPPCData data;
struct cpuPPC64Data data;
struct ppc_model *next;
};
@ -340,7 +340,7 @@ ppcLoadMap(void)
}
static virCPUDataPtr
ppcMakeCPUData(virArch arch, struct cpuPPCData *data)
ppcMakeCPUData(virArch arch, struct cpuPPC64Data *data)
{
virCPUDataPtr cpuData;
@ -348,7 +348,7 @@ ppcMakeCPUData(virArch arch, struct cpuPPCData *data)
return NULL;
cpuData->arch = arch;
cpuData->data.ppc = *data;
cpuData->data.ppc64 = *data;
data = NULL;
return cpuData;
@ -480,10 +480,10 @@ ppcDecode(virCPUDefPtr cpu,
if (data == NULL || (map = ppcLoadMap()) == NULL)
return -1;
if (!(model = ppcModelFindPVR(map, data->data.ppc.pvr))) {
if (!(model = ppcModelFindPVR(map, data->data.ppc64.pvr))) {
virReportError(VIR_ERR_OPERATION_FAILED,
_("Cannot find CPU model with PVR 0x%08x"),
data->data.ppc.pvr);
data->data.ppc64.pvr);
goto cleanup;
}
@ -529,7 +529,7 @@ ppcNodeData(virArch arch)
#if defined(__powerpc__) || defined(__powerpc64__)
asm("mfpvr %0"
: "=r" (cpuData->data.ppc.pvr));
: "=r" (cpuData->data.ppc64.pvr));
#endif
return cpuData;
@ -694,7 +694,7 @@ ppcGetModels(char ***models)
goto cleanup;
}
struct cpuArchDriver cpuDriverPowerPC = {
struct cpuArchDriver cpuDriverPPC64 = {
.name = "ppc64",
.arch = archs,
.narch = ARRAY_CARDINALITY(archs),

View File

@ -1,5 +1,5 @@
/*
* cpu_ppc64.h: CPU driver for PowerPC CPUs
* cpu_ppc64.h: CPU driver for 64-bit PowerPC CPUs
*
* Copyright (C) Copyright (C) IBM Corporation, 2010
*
@ -22,11 +22,11 @@
* Prerna Saxena <prerna@linux.vnet.ibm.com>
*/
#ifndef __VIR_CPU_POWERPC_H__
# define __VIR_CPU_POWERPC_H__
#ifndef __VIR_CPU_PPC64_H__
# define __VIR_CPU_PPC64_H__
# include "cpu.h"
extern struct cpuArchDriver cpuDriverPowerPC;
extern struct cpuArchDriver cpuDriverPPC64;
#endif /* __VIR_CPU_POWERPC_H__ */
#endif /* __VIR_CPU_PPC64_H__ */

View File

@ -1,5 +1,5 @@
/*
* cpu_ppc64_data.h: PowerPC specific CPU data
* cpu_ppc64_data.h: 64-bit PowerPC CPU specific data
*
* Copyright (C) 2012 IBM Corporation.
*
@ -21,13 +21,13 @@
* Li Zhang <zhlcindy@linux.vnet.ibm.com>
*/
#ifndef __VIR_CPU_PPC_DATA_H__
# define __VIR_CPU_PPC_DATA_H__
#ifndef __VIR_CPU_PPC64_DATA_H__
# define __VIR_CPU_PPC64_DATA_H__
# include <stdint.h>
struct cpuPPCData {
struct cpuPPC64Data {
uint32_t pvr;
};
#endif /* __VIR_CPU_PPC_DATA_H__ */
#endif /* __VIR_CPU_PPC64_DATA_H__ */