mirror of
https://gitlab.com/libvirt/libvirt.git
synced 2025-01-12 15:52:55 +00:00
Rename virResctrlInfo to virResctrlInfoPerCache
Just to ease the review of following patches. Signed-off-by: Martin Kletzander <mkletzan@redhat.com>
This commit is contained in:
parent
23594ccda9
commit
b2211a9e54
@ -904,7 +904,7 @@ virCapabilitiesFormatCaches(virBufferPtr buf,
|
|||||||
virBufferSetChildIndent(&controlBuf, buf);
|
virBufferSetChildIndent(&controlBuf, buf);
|
||||||
for (j = 0; j < bank->ncontrols; j++) {
|
for (j = 0; j < bank->ncontrols; j++) {
|
||||||
const char *min_unit;
|
const char *min_unit;
|
||||||
virResctrlInfoPtr controls = bank->controls[j];
|
virResctrlInfoPerCachePtr controls = bank->controls[j];
|
||||||
unsigned long long gran_short_size = controls->granularity;
|
unsigned long long gran_short_size = controls->granularity;
|
||||||
unsigned long long min_short_size = controls->min;
|
unsigned long long min_short_size = controls->min;
|
||||||
|
|
||||||
|
@ -148,7 +148,7 @@ struct _virCapsHostCacheBank {
|
|||||||
virCacheType type; /* Data, Instruction or Unified */
|
virCacheType type; /* Data, Instruction or Unified */
|
||||||
virBitmapPtr cpus; /* All CPUs that share this bank */
|
virBitmapPtr cpus; /* All CPUs that share this bank */
|
||||||
size_t ncontrols;
|
size_t ncontrols;
|
||||||
virResctrlInfoPtr *controls;
|
virResctrlInfoPerCachePtr *controls;
|
||||||
};
|
};
|
||||||
|
|
||||||
typedef struct _virCapsHost virCapsHost;
|
typedef struct _virCapsHost virCapsHost;
|
||||||
|
@ -59,7 +59,7 @@ int
|
|||||||
virResctrlGetCacheInfo(unsigned int level,
|
virResctrlGetCacheInfo(unsigned int level,
|
||||||
unsigned long long size,
|
unsigned long long size,
|
||||||
virCacheType scope,
|
virCacheType scope,
|
||||||
virResctrlInfoPtr **controls,
|
virResctrlInfoPerCachePtr **controls,
|
||||||
size_t *ncontrols)
|
size_t *ncontrols)
|
||||||
{
|
{
|
||||||
int ret = -1;
|
int ret = -1;
|
||||||
@ -69,7 +69,7 @@ virResctrlGetCacheInfo(unsigned int level,
|
|||||||
char *type_upper = NULL;
|
char *type_upper = NULL;
|
||||||
unsigned int bits = 0;
|
unsigned int bits = 0;
|
||||||
unsigned int min_cbm_bits = 0;
|
unsigned int min_cbm_bits = 0;
|
||||||
virResctrlInfoPtr control;
|
virResctrlInfoPerCachePtr control;
|
||||||
|
|
||||||
if (VIR_ALLOC(control) < 0)
|
if (VIR_ALLOC(control) < 0)
|
||||||
goto cleanup;
|
goto cleanup;
|
||||||
|
@ -36,9 +36,9 @@ typedef enum {
|
|||||||
VIR_ENUM_DECL(virCache);
|
VIR_ENUM_DECL(virCache);
|
||||||
|
|
||||||
|
|
||||||
typedef struct _virResctrlInfo virResctrlInfo;
|
typedef struct _virResctrlInfoPerCache virResctrlInfoPerCache;
|
||||||
typedef virResctrlInfo *virResctrlInfoPtr;
|
typedef virResctrlInfoPerCache *virResctrlInfoPerCachePtr;
|
||||||
struct _virResctrlInfo {
|
struct _virResctrlInfoPerCache {
|
||||||
/* Smallest possible increase of the allocation size in bytes */
|
/* Smallest possible increase of the allocation size in bytes */
|
||||||
unsigned long long granularity;
|
unsigned long long granularity;
|
||||||
/* Minimal allocatable size in bytes (if different from granularity) */
|
/* Minimal allocatable size in bytes (if different from granularity) */
|
||||||
@ -54,7 +54,7 @@ int
|
|||||||
virResctrlGetCacheInfo(unsigned int level,
|
virResctrlGetCacheInfo(unsigned int level,
|
||||||
unsigned long long size,
|
unsigned long long size,
|
||||||
virCacheType scope,
|
virCacheType scope,
|
||||||
virResctrlInfoPtr **controls,
|
virResctrlInfoPerCachePtr **controls,
|
||||||
size_t *ncontrols);
|
size_t *ncontrols);
|
||||||
|
|
||||||
int
|
int
|
||||||
|
Loading…
x
Reference in New Issue
Block a user