提交 db7b6172 编写于 作者: J Ján Tomko

bhyve: use G_GNUC_UNUSED

Use G_GNUC_UNUSED from GLib instead of ATTRIBUTE_UNUSED.
Signed-off-by: NJán Tomko <jtomko@redhat.com>
Reviewed-by: NMichal Privoznik <mprivozn@redhat.com>
上级 cf4befa1
...@@ -286,7 +286,7 @@ bhyveBuildUSBControllerArgStr(const virDomainDef *def, ...@@ -286,7 +286,7 @@ bhyveBuildUSBControllerArgStr(const virDomainDef *def,
} }
static int static int
bhyveBuildVirtIODiskArgStr(const virDomainDef *def ATTRIBUTE_UNUSED, bhyveBuildVirtIODiskArgStr(const virDomainDef *def G_GNUC_UNUSED,
virDomainDiskDefPtr disk, virDomainDiskDefPtr disk,
virCommandPtr cmd) virCommandPtr cmd)
{ {
...@@ -319,7 +319,7 @@ bhyveBuildVirtIODiskArgStr(const virDomainDef *def ATTRIBUTE_UNUSED, ...@@ -319,7 +319,7 @@ bhyveBuildVirtIODiskArgStr(const virDomainDef *def ATTRIBUTE_UNUSED,
} }
static int static int
bhyveBuildLPCArgStr(const virDomainDef *def ATTRIBUTE_UNUSED, bhyveBuildLPCArgStr(const virDomainDef *def G_GNUC_UNUSED,
virCommandPtr cmd) virCommandPtr cmd)
{ {
virCommandAddArgList(cmd, "-s", "1,lpc", NULL); virCommandAddArgList(cmd, "-s", "1,lpc", NULL);
...@@ -643,7 +643,7 @@ virBhyveProcessBuildBhyveCmd(virConnectPtr conn, ...@@ -643,7 +643,7 @@ virBhyveProcessBuildBhyveCmd(virConnectPtr conn,
} }
virCommandPtr virCommandPtr
virBhyveProcessBuildDestroyCmd(bhyveConnPtr driver ATTRIBUTE_UNUSED, virBhyveProcessBuildDestroyCmd(bhyveConnPtr driver G_GNUC_UNUSED,
virDomainDefPtr def) virDomainDefPtr def)
{ {
virCommandPtr cmd = virCommandNew(BHYVECTL); virCommandPtr cmd = virCommandNew(BHYVECTL);
......
...@@ -31,8 +31,8 @@ ...@@ -31,8 +31,8 @@
VIR_LOG_INIT("bhyve.bhyve_device"); VIR_LOG_INIT("bhyve.bhyve_device");
static int static int
bhyveCollectPCIAddress(virDomainDefPtr def ATTRIBUTE_UNUSED, bhyveCollectPCIAddress(virDomainDefPtr def G_GNUC_UNUSED,
virDomainDeviceDefPtr device ATTRIBUTE_UNUSED, virDomainDeviceDefPtr device G_GNUC_UNUSED,
virDomainDeviceInfoPtr info, virDomainDeviceInfoPtr info,
void *opaque) void *opaque)
{ {
......
...@@ -32,7 +32,7 @@ ...@@ -32,7 +32,7 @@
VIR_LOG_INIT("bhyve.bhyve_domain"); VIR_LOG_INIT("bhyve.bhyve_domain");
static void * static void *
bhyveDomainObjPrivateAlloc(void *opaque ATTRIBUTE_UNUSED) bhyveDomainObjPrivateAlloc(void *opaque G_GNUC_UNUSED)
{ {
bhyveDomainObjPrivatePtr priv; bhyveDomainObjPrivatePtr priv;
...@@ -74,10 +74,10 @@ bhyveDomainDefNeedsISAController(virDomainDefPtr def) ...@@ -74,10 +74,10 @@ bhyveDomainDefNeedsISAController(virDomainDefPtr def)
static int static int
bhyveDomainDefPostParse(virDomainDefPtr def, bhyveDomainDefPostParse(virDomainDefPtr def,
virCapsPtr caps ATTRIBUTE_UNUSED, virCapsPtr caps G_GNUC_UNUSED,
unsigned int parseFlags ATTRIBUTE_UNUSED, unsigned int parseFlags G_GNUC_UNUSED,
void *opaque ATTRIBUTE_UNUSED, void *opaque G_GNUC_UNUSED,
void *parseOpaque ATTRIBUTE_UNUSED) void *parseOpaque G_GNUC_UNUSED)
{ {
/* Add an implicit PCI root controller */ /* Add an implicit PCI root controller */
if (virDomainDefMaybeAddController(def, VIR_DOMAIN_CONTROLLER_TYPE_PCI, 0, if (virDomainDefMaybeAddController(def, VIR_DOMAIN_CONTROLLER_TYPE_PCI, 0,
...@@ -90,7 +90,7 @@ bhyveDomainDefPostParse(virDomainDefPtr def, ...@@ -90,7 +90,7 @@ bhyveDomainDefPostParse(virDomainDefPtr def,
static int static int
bhyveDomainDiskDefAssignAddress(bhyveConnPtr driver, bhyveDomainDiskDefAssignAddress(bhyveConnPtr driver,
virDomainDiskDefPtr def, virDomainDiskDefPtr def,
const virDomainDef *vmdef ATTRIBUTE_UNUSED) const virDomainDef *vmdef G_GNUC_UNUSED)
{ {
int idx = virDiskNameToIndex(def->dst); int idx = virDiskNameToIndex(def->dst);
...@@ -122,10 +122,10 @@ bhyveDomainDiskDefAssignAddress(bhyveConnPtr driver, ...@@ -122,10 +122,10 @@ bhyveDomainDiskDefAssignAddress(bhyveConnPtr driver,
static int static int
bhyveDomainDeviceDefPostParse(virDomainDeviceDefPtr dev, bhyveDomainDeviceDefPostParse(virDomainDeviceDefPtr dev,
const virDomainDef *def, const virDomainDef *def,
virCapsPtr caps ATTRIBUTE_UNUSED, virCapsPtr caps G_GNUC_UNUSED,
unsigned int parseFlags ATTRIBUTE_UNUSED, unsigned int parseFlags G_GNUC_UNUSED,
void *opaque, void *opaque,
void *parseOpaque ATTRIBUTE_UNUSED) void *parseOpaque G_GNUC_UNUSED)
{ {
bhyveConnPtr driver = opaque; bhyveConnPtr driver = opaque;
...@@ -156,10 +156,10 @@ bhyveDomainDeviceDefPostParse(virDomainDeviceDefPtr dev, ...@@ -156,10 +156,10 @@ bhyveDomainDeviceDefPostParse(virDomainDeviceDefPtr dev,
static int static int
bhyveDomainDefAssignAddresses(virDomainDef *def, bhyveDomainDefAssignAddresses(virDomainDef *def,
virCapsPtr caps ATTRIBUTE_UNUSED, virCapsPtr caps G_GNUC_UNUSED,
unsigned int parseFlags ATTRIBUTE_UNUSED, unsigned int parseFlags G_GNUC_UNUSED,
void *opaque ATTRIBUTE_UNUSED, void *opaque G_GNUC_UNUSED,
void *parseOpaque ATTRIBUTE_UNUSED) void *parseOpaque G_GNUC_UNUSED)
{ {
if (bhyveDomainAssignAddresses(def, NULL) < 0) if (bhyveDomainAssignAddresses(def, NULL) < 0)
return -1; return -1;
......
...@@ -191,8 +191,8 @@ bhyveConnectURIProbe(char **uri) ...@@ -191,8 +191,8 @@ bhyveConnectURIProbe(char **uri)
static virDrvOpenStatus static virDrvOpenStatus
bhyveConnectOpen(virConnectPtr conn, bhyveConnectOpen(virConnectPtr conn,
virConnectAuthPtr auth ATTRIBUTE_UNUSED, virConnectAuthPtr auth G_GNUC_UNUSED,
virConfPtr conf ATTRIBUTE_UNUSED, virConfPtr conf G_GNUC_UNUSED,
unsigned int flags) unsigned int flags)
{ {
virCheckFlags(VIR_CONNECT_RO, VIR_DRV_OPEN_ERROR); virCheckFlags(VIR_CONNECT_RO, VIR_DRV_OPEN_ERROR);
...@@ -1049,7 +1049,7 @@ bhyveDomainShutdown(virDomainPtr dom) ...@@ -1049,7 +1049,7 @@ bhyveDomainShutdown(virDomainPtr dom)
static int static int
bhyveDomainOpenConsole(virDomainPtr dom, bhyveDomainOpenConsole(virDomainPtr dom,
const char *dev_name ATTRIBUTE_UNUSED, const char *dev_name G_GNUC_UNUSED,
virStreamPtr st, virStreamPtr st,
unsigned int flags) unsigned int flags)
{ {
...@@ -1215,8 +1215,8 @@ bhyveStateCleanup(void) ...@@ -1215,8 +1215,8 @@ bhyveStateCleanup(void)
static int static int
bhyveStateInitialize(bool privileged, bhyveStateInitialize(bool privileged,
virStateInhibitCallback callback ATTRIBUTE_UNUSED, virStateInhibitCallback callback G_GNUC_UNUSED,
void *opaque ATTRIBUTE_UNUSED) void *opaque G_GNUC_UNUSED)
{ {
bool autostart = true; bool autostart = true;
...@@ -1550,20 +1550,20 @@ bhyveConnectGetType(virConnectPtr conn) ...@@ -1550,20 +1550,20 @@ bhyveConnectGetType(virConnectPtr conn)
return "BHYVE"; return "BHYVE";
} }
static int bhyveConnectIsAlive(virConnectPtr conn ATTRIBUTE_UNUSED) static int bhyveConnectIsAlive(virConnectPtr conn G_GNUC_UNUSED)
{ {
return 1; return 1;
} }
static int static int
bhyveConnectIsSecure(virConnectPtr conn ATTRIBUTE_UNUSED) bhyveConnectIsSecure(virConnectPtr conn G_GNUC_UNUSED)
{ {
/* Trivially secure, since always inside the daemon */ /* Trivially secure, since always inside the daemon */
return 1; return 1;
} }
static int static int
bhyveConnectIsEncrypted(virConnectPtr conn ATTRIBUTE_UNUSED) bhyveConnectIsEncrypted(virConnectPtr conn G_GNUC_UNUSED)
{ {
/* Not encrypted, but remote driver takes care of that */ /* Not encrypted, but remote driver takes care of that */
return 0; return 0;
......
...@@ -44,7 +44,7 @@ struct _bhyveMonitor { ...@@ -44,7 +44,7 @@ struct _bhyveMonitor {
}; };
static void static void
bhyveMonitorIO(int watch, int kq, int events ATTRIBUTE_UNUSED, void *opaque) bhyveMonitorIO(int watch, int kq, int events G_GNUC_UNUSED, void *opaque)
{ {
const struct timespec zerowait = { 0, 0 }; const struct timespec zerowait = { 0, 0 };
virDomainObjPtr vm = opaque; virDomainObjPtr vm = opaque;
......
...@@ -263,7 +263,7 @@ bhyveCommandLineToArgv(const char *nativeConfig, ...@@ -263,7 +263,7 @@ bhyveCommandLineToArgv(const char *nativeConfig,
static int static int
bhyveParseBhyveLPCArg(virDomainDefPtr def, bhyveParseBhyveLPCArg(virDomainDefPtr def,
unsigned caps ATTRIBUTE_UNUSED, unsigned caps G_GNUC_UNUSED,
const char *arg) const char *arg)
{ {
/* -l emulation[,config] */ /* -l emulation[,config] */
...@@ -414,7 +414,7 @@ bhyveParsePCISlot(const char *slotdef, ...@@ -414,7 +414,7 @@ bhyveParsePCISlot(const char *slotdef,
static int static int
bhyveParsePCIDisk(virDomainDefPtr def, bhyveParsePCIDisk(virDomainDefPtr def,
unsigned caps ATTRIBUTE_UNUSED, unsigned caps G_GNUC_UNUSED,
unsigned pcislot, unsigned pcislot,
unsigned pcibus, unsigned pcibus,
unsigned function, unsigned function,
...@@ -487,7 +487,7 @@ bhyveParsePCIDisk(virDomainDefPtr def, ...@@ -487,7 +487,7 @@ bhyveParsePCIDisk(virDomainDefPtr def,
static int static int
bhyveParsePCINet(virDomainDefPtr def, bhyveParsePCINet(virDomainDefPtr def,
virDomainXMLOptionPtr xmlopt, virDomainXMLOptionPtr xmlopt,
unsigned caps ATTRIBUTE_UNUSED, unsigned caps G_GNUC_UNUSED,
unsigned pcislot, unsigned pcislot,
unsigned pcibus, unsigned pcibus,
unsigned function, unsigned function,
...@@ -843,7 +843,7 @@ bhyveParseBhyveLoadCommandLine(virDomainDefPtr def, ...@@ -843,7 +843,7 @@ bhyveParseBhyveLoadCommandLine(virDomainDefPtr def,
static int static int
bhyveParseCustomLoaderCommandLine(virDomainDefPtr def, bhyveParseCustomLoaderCommandLine(virDomainDefPtr def,
int argc ATTRIBUTE_UNUSED, int argc G_GNUC_UNUSED,
char **argv) char **argv)
{ {
if (!argv) if (!argv)
......
...@@ -55,7 +55,7 @@ VIR_LOG_INIT("bhyve.bhyve_process"); ...@@ -55,7 +55,7 @@ VIR_LOG_INIT("bhyve.bhyve_process");
static void static void
bhyveProcessAutoDestroy(virDomainObjPtr vm, bhyveProcessAutoDestroy(virDomainObjPtr vm,
virConnectPtr conn ATTRIBUTE_UNUSED, virConnectPtr conn G_GNUC_UNUSED,
void *opaque) void *opaque)
{ {
bhyveConnPtr driver = opaque; bhyveConnPtr driver = opaque;
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册