From: Pali Rohár Date: Sun, 10 Sep 2023 16:48:16 +0000 (+0200) Subject: Fix compile warnings about unused variables X-Git-Tag: v3.11.0~79^2 X-Git-Url: http://mj.ucw.cz/gitweb/?a=commitdiff_plain;h=878fea5235a68342dc8327ba4d28acbcc580dc74;p=pciutils.git Fix compile warnings about unused variables sysfs.c: In function 'sysfs_read_vpd': sysfs.c:569:43: warning: unused parameter 'd' [-Wunused-parameter] static int sysfs_read_vpd(struct pci_dev *d, int pos, byte *buf, int len) ^ sysfs.c:569:50: warning: unused parameter 'pos' [-Wunused-parameter] static int sysfs_read_vpd(struct pci_dev *d, int pos, byte *buf, int len) ^~~ sysfs.c:569:61: warning: unused parameter 'buf' [-Wunused-parameter] static int sysfs_read_vpd(struct pci_dev *d, int pos, byte *buf, int len) ^~~ sysfs.c:569:70: warning: unused parameter 'len' [-Wunused-parameter] static int sysfs_read_vpd(struct pci_dev *d, int pos, byte *buf, int len) ^~~ --- diff --git a/lib/sysfs.c b/lib/sysfs.c index 8cab869..1bb4ae9 100644 --- a/lib/sysfs.c +++ b/lib/sysfs.c @@ -566,7 +566,7 @@ static int sysfs_write(struct pci_dev *d, int pos, byte *buf, int len) /* pread() is not available and do_read() only works for a single fd, so we * cannot implement read_vpd properly. */ -static int sysfs_read_vpd(struct pci_dev *d, int pos, byte *buf, int len) +static int sysfs_read_vpd(struct pci_dev *d UNUSED, int pos UNUSED, byte *buf UNUSED, int len UNUSED) { return 0; }