Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

-Wunused-but-set-variables caught by CI #12917

Closed
wants to merge 3 commits into from
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 1 addition & 2 deletions module/os/freebsd/zfs/zvol_os.c
Original file line number Diff line number Diff line change
Expand Up @@ -1035,7 +1035,7 @@ zvol_cdev_ioctl(struct cdev *dev, ulong_t cmd, caddr_t data,
zvol_state_t *zv;
zfs_locked_range_t *lr;
off_t offset, length;
int i, error;
int error;
boolean_t sync;

zv = dev->si_drv2;
Expand All @@ -1044,7 +1044,6 @@ zvol_cdev_ioctl(struct cdev *dev, ulong_t cmd, caddr_t data,
KASSERT(zv->zv_open_count > 0,
("Device with zero access count in %s", __func__));

i = IOCPARM_LEN(cmd);
switch (cmd) {
case DIOCGSECTORSIZE:
*(uint32_t *)data = DEV_BSIZE;
Expand Down
6 changes: 0 additions & 6 deletions module/zfs/zfs_fm.c
Original file line number Diff line number Diff line change
Expand Up @@ -825,9 +825,6 @@ annotate_ecksum(nvlist_t *ereport, zio_bad_cksum_t *info,
const uint64_t *good;
const uint64_t *bad;

uint64_t allset = 0;
uint64_t allcleared = 0;

size_t nui64s = size / sizeof (uint64_t);

size_t inline_size;
Expand Down Expand Up @@ -929,9 +926,6 @@ annotate_ecksum(nvlist_t *ereport, zio_bad_cksum_t *info,
// bits set in good, but not in bad
cleared = (good[idx] & (~bad[idx]));

allset |= set;
allcleared |= cleared;

if (!no_inline) {
ASSERT3U(offset, <, inline_size);
eip->zei_bits_set[offset] = set;
Expand Down
3 changes: 1 addition & 2 deletions module/zfs/zvol.c
Original file line number Diff line number Diff line change
Expand Up @@ -1311,13 +1311,12 @@ static void
zvol_rename_minors_impl(const char *oldname, const char *newname)
{
zvol_state_t *zv, *zv_next;
int oldnamelen, newnamelen;
int oldnamelen;

if (zvol_inhibit_dev)
return;

oldnamelen = strlen(oldname);
newnamelen = strlen(newname);

rw_enter(&zvol_state_lock, RW_READER);

Expand Down