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

node_device: 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>
上级 adf76a7f
......@@ -46,8 +46,8 @@ virNodeDeviceDriverStatePtr driver;
virDrvOpenStatus
nodeConnectOpen(virConnectPtr conn,
virConnectAuthPtr auth ATTRIBUTE_UNUSED,
virConfPtr conf ATTRIBUTE_UNUSED,
virConnectAuthPtr auth G_GNUC_UNUSED,
virConfPtr conf G_GNUC_UNUSED,
unsigned int flags)
{
virCheckFlags(VIR_CONNECT_RO, VIR_DRV_OPEN_ERROR);
......@@ -69,27 +69,27 @@ nodeConnectOpen(virConnectPtr conn,
return VIR_DRV_OPEN_SUCCESS;
}
int nodeConnectClose(virConnectPtr conn ATTRIBUTE_UNUSED)
int nodeConnectClose(virConnectPtr conn G_GNUC_UNUSED)
{
return 0;
}
int nodeConnectIsSecure(virConnectPtr conn ATTRIBUTE_UNUSED)
int nodeConnectIsSecure(virConnectPtr conn G_GNUC_UNUSED)
{
/* Trivially secure, since always inside the daemon */
return 1;
}
int nodeConnectIsEncrypted(virConnectPtr conn ATTRIBUTE_UNUSED)
int nodeConnectIsEncrypted(virConnectPtr conn G_GNUC_UNUSED)
{
/* Not encrypted, but remote driver takes care of that */
return 0;
}
int nodeConnectIsAlive(virConnectPtr conn ATTRIBUTE_UNUSED)
int nodeConnectIsAlive(virConnectPtr conn G_GNUC_UNUSED)
{
return 1;
}
......@@ -142,7 +142,7 @@ nodeDeviceUpdateDriverName(virNodeDeviceDefPtr def)
#else
/* XXX: Implement me for non-linux */
static int
nodeDeviceUpdateDriverName(virNodeDeviceDefPtr def ATTRIBUTE_UNUSED)
nodeDeviceUpdateDriverName(virNodeDeviceDefPtr def G_GNUC_UNUSED)
{
return 0;
}
......
......@@ -520,7 +520,7 @@ dev_refresh(const char *udi)
}
static void
device_added(LibHalContext *ctx ATTRIBUTE_UNUSED,
device_added(LibHalContext *ctx G_GNUC_UNUSED,
const char *udi)
{
VIR_DEBUG("%s", hal_name(udi));
......@@ -529,7 +529,7 @@ device_added(LibHalContext *ctx ATTRIBUTE_UNUSED,
static void
device_removed(LibHalContext *ctx ATTRIBUTE_UNUSED,
device_removed(LibHalContext *ctx G_GNUC_UNUSED,
const char *udi)
{
const char *name = hal_name(udi);
......@@ -565,7 +565,7 @@ device_cap_added(LibHalContext *ctx,
static void
device_cap_lost(LibHalContext *ctx ATTRIBUTE_UNUSED,
device_cap_lost(LibHalContext *ctx G_GNUC_UNUSED,
const char *udi,
const char *cap)
{
......@@ -577,11 +577,11 @@ device_cap_lost(LibHalContext *ctx ATTRIBUTE_UNUSED,
static void
device_prop_modified(LibHalContext *ctx ATTRIBUTE_UNUSED,
device_prop_modified(LibHalContext *ctx G_GNUC_UNUSED,
const char *udi,
const char *key,
dbus_bool_t is_removed ATTRIBUTE_UNUSED,
dbus_bool_t is_added ATTRIBUTE_UNUSED)
dbus_bool_t is_removed G_GNUC_UNUSED,
dbus_bool_t is_added G_GNUC_UNUSED)
{
const char *name = hal_name(udi);
VIR_DEBUG("%s %s", name, key);
......@@ -591,9 +591,9 @@ device_prop_modified(LibHalContext *ctx ATTRIBUTE_UNUSED,
static int
nodeStateInitialize(bool privileged ATTRIBUTE_UNUSED,
virStateInhibitCallback callback ATTRIBUTE_UNUSED,
void *opaque ATTRIBUTE_UNUSED)
nodeStateInitialize(bool privileged G_GNUC_UNUSED,
virStateInhibitCallback callback G_GNUC_UNUSED,
void *opaque G_GNUC_UNUSED)
{
LibHalContext *hal_ctx = NULL;
char **udi = NULL;
......
......@@ -606,7 +606,7 @@ udevProcessNetworkInterface(struct udev_device *device,
static int
udevProcessSCSIHost(struct udev_device *device ATTRIBUTE_UNUSED,
udevProcessSCSIHost(struct udev_device *device G_GNUC_UNUSED,
virNodeDeviceDefPtr def)
{
virNodeDevCapSCSIHostPtr scsi_host = &def->caps->data.scsi_host;
......@@ -654,7 +654,7 @@ udevProcessSCSITarget(struct udev_device *device,
static int
udevGetSCSIType(virNodeDeviceDefPtr def ATTRIBUTE_UNUSED,
udevGetSCSIType(virNodeDeviceDefPtr def G_GNUC_UNUSED,
unsigned int type,
char **typestring)
{
......@@ -714,7 +714,7 @@ udevGetSCSIType(virNodeDeviceDefPtr def ATTRIBUTE_UNUSED,
static int
udevProcessSCSIDevice(struct udev_device *device ATTRIBUTE_UNUSED,
udevProcessSCSIDevice(struct udev_device *device G_GNUC_UNUSED,
virNodeDeviceDefPtr def)
{
int ret = -1;
......@@ -1578,7 +1578,7 @@ udevEventMonitorSanityCheck(udevEventDataPtr priv,
* would still come into play.
*/
static void
udevEventHandleThread(void *opaque ATTRIBUTE_UNUSED)
udevEventHandleThread(void *opaque G_GNUC_UNUSED)
{
udevEventDataPtr priv = driver->privateData;
struct udev_device *device = NULL;
......@@ -1645,10 +1645,10 @@ udevEventHandleThread(void *opaque ATTRIBUTE_UNUSED)
static void
udevEventHandleCallback(int watch ATTRIBUTE_UNUSED,
udevEventHandleCallback(int watch G_GNUC_UNUSED,
int fd,
int events ATTRIBUTE_UNUSED,
void *data ATTRIBUTE_UNUSED)
int events G_GNUC_UNUSED,
void *data G_GNUC_UNUSED)
{
udevEventDataPtr priv = driver->privateData;
......@@ -1783,7 +1783,7 @@ nodeStateInitializeEnumerate(void *opaque)
static int
udevPCITranslateInit(bool privileged ATTRIBUTE_UNUSED)
udevPCITranslateInit(bool privileged G_GNUC_UNUSED)
{
#if defined __s390__ || defined __s390x_
/* On s390(x) system there is no PCI bus.
......@@ -1808,8 +1808,8 @@ udevPCITranslateInit(bool privileged ATTRIBUTE_UNUSED)
static int
nodeStateInitialize(bool privileged,
virStateInhibitCallback callback ATTRIBUTE_UNUSED,
void *opaque ATTRIBUTE_UNUSED)
virStateInhibitCallback callback G_GNUC_UNUSED,
void *opaque G_GNUC_UNUSED)
{
udevEventDataPtr priv = NULL;
struct udev *udev = NULL;
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册