aboutsummaryrefslogtreecommitdiff
path: root/samples/gpio-pci-idio-16.c
diff options
context:
space:
mode:
authorSwapnil Ingle <swapnil.ingle@nutanix.com>2020-11-12 05:08:04 -0500
committerSwapnil Ingle <swapnil.ingle@nutanix.com>2020-11-12 09:40:36 -0500
commitbc14a86815855af69141d4c6a44dbda24c270757 (patch)
tree5045e90fef5e9a2d7031b39b27afac499ad0cdf6 /samples/gpio-pci-idio-16.c
parentb0c8341d6fdd34988a3cdf20108b8eb64ba3cf55 (diff)
downloadlibvfio-user-bc14a86815855af69141d4c6a44dbda24c270757.zip
libvfio-user-bc14a86815855af69141d4c6a44dbda24c270757.tar.gz
libvfio-user-bc14a86815855af69141d4c6a44dbda24c270757.tar.bz2
Fix issues pointed by CFLAGS "-Wall -Werror -Wextra"
Signed-off-by: Swapnil Ingle <swapnil.ingle@nutanix.com>
Diffstat (limited to 'samples/gpio-pci-idio-16.c')
-rw-r--r--samples/gpio-pci-idio-16.c9
1 files changed, 5 insertions, 4 deletions
diff --git a/samples/gpio-pci-idio-16.c b/samples/gpio-pci-idio-16.c
index c549017..9a79d0c 100644
--- a/samples/gpio-pci-idio-16.c
+++ b/samples/gpio-pci-idio-16.c
@@ -42,16 +42,17 @@
#include <errno.h>
#include "../lib/muser.h"
+#include "../lib/muser_priv.h"
static void
-_log(void *pvt, lm_log_lvl_t lvl __attribute__((unused)), char const *msg)
+_log(UNUSED void *pvt, UNUSED lm_log_lvl_t lvl, char const *msg)
{
fprintf(stderr, "gpio: %s\n", msg);
}
ssize_t
-bar2_access(void *pvt, char * const buf, size_t count, loff_t offset,
- const bool is_write)
+bar2_access(UNUSED void *pvt, char * const buf, size_t count, loff_t offset,
+ const bool is_write)
{
static char n;
@@ -61,7 +62,7 @@ bar2_access(void *pvt, char * const buf, size_t count, loff_t offset,
return count;
}
-static void _sa_handler(int signum __attribute__((unused)))
+static void _sa_handler(UNUSED int signum)
{
}