mirror of
https://github.com/libvirt/libvirt.git
synced 2026-09-03 20:53:04 -05:00
domiftune: Add API virDomain{S,G}etInterfaceParameters
The APIs are used to set/get domain's network interface's parameters. Currently supported parameters are bandwidth settings. * include/libvirt/libvirt.h.in: new API and parameters definition * python/generator.py: skip the Python API generation * src/driver.h: add new entry to the driver structure * src/libvirt_public.syms: export symbols
This commit is contained in:
@@ -645,6 +645,48 @@ typedef virTypedParameter *virTypedParameterPtr;
|
||||
*/
|
||||
#define VIR_DOMAIN_SCHEDULER_SHARES "shares"
|
||||
|
||||
/**
|
||||
* VIR_DOMAIN_BANDWIDTH_IN_AVERAGE:
|
||||
*
|
||||
* Macro represents the inbound average of NIC bandwidth.
|
||||
*/
|
||||
#define VIR_DOMAIN_BANDWIDTH_IN_AVERAGE "inbound.average"
|
||||
|
||||
/**
|
||||
* VIR_DOMAIN_BANDWIDTH_IN_PEAK:
|
||||
*
|
||||
* Macro represents the inbound peak of NIC bandwidth.
|
||||
*/
|
||||
#define VIR_DOMAIN_BANDWIDTH_IN_PEAK "inbound.peak"
|
||||
|
||||
/**
|
||||
* VIR_DOMAIN_BANDWIDTH_IN_BURST:
|
||||
*
|
||||
* Macro represents the inbound burst of NIC bandwidth.
|
||||
*/
|
||||
#define VIR_DOMAIN_BANDWIDTH_IN_BURST "inbound.burst"
|
||||
|
||||
/**
|
||||
* VIR_DOMAIN_BANDWIDTH_OUT_AVERAGE:
|
||||
*
|
||||
* Macro represents the outbound average of NIC bandwidth.
|
||||
*/
|
||||
#define VIR_DOMAIN_BANDWIDTH_OUT_AVERAGE "outbound.average"
|
||||
|
||||
/**
|
||||
* VIR_DOMAIN_BANDWIDTH_OUT_PEAK:
|
||||
*
|
||||
* Macro represents the outbound peak of NIC bandwidth.
|
||||
*/
|
||||
#define VIR_DOMAIN_BANDWIDTH_OUT_PEAK "outbound.peak"
|
||||
|
||||
/**
|
||||
* VIR_DOMAIN_BANDWIDTH_OUT_BURST:
|
||||
*
|
||||
* Macro represents the outbound burst of NIC bandwidth.
|
||||
*/
|
||||
#define VIR_DOMAIN_BANDWIDTH_OUT_BURST "outbound.burst"
|
||||
|
||||
/*
|
||||
* Fetch scheduler parameters, caller allocates 'params' field of size 'nparams'
|
||||
*/
|
||||
@@ -1446,6 +1488,14 @@ int virDomainInterfaceStats (virDomainPtr dom,
|
||||
const char *path,
|
||||
virDomainInterfaceStatsPtr stats,
|
||||
size_t size);
|
||||
int virDomainSetInterfaceParameters (virDomainPtr dom,
|
||||
const char *device,
|
||||
virTypedParameterPtr params,
|
||||
int nparams, unsigned int flags);
|
||||
int virDomainGetInterfaceParameters (virDomainPtr dom,
|
||||
const char *device,
|
||||
virTypedParameterPtr params,
|
||||
int *nparams, unsigned int flags);
|
||||
int virDomainMemoryStats (virDomainPtr dom,
|
||||
virDomainMemoryStatPtr stats,
|
||||
unsigned int nr_stats,
|
||||
|
||||
Reference in New Issue
Block a user