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-variable post-increments found by new Clang trunk (number 3 will shock you!) #13304

Conversation

nabijaczleweli
Copy link
Contributor

@nabijaczleweli nabijaczleweli commented Apr 7, 2022

Description

We provide no API for draid, it did nothing, and was undocumented.

num_indirect is a left-over from the original a1d477c; it's unused there as well.

zpool_clear_label() contains a bug-fix (since I assume failing to clear the L2ARC label should be an error) an optimisation, and a clean-up to match the bug-fix. The bug-fix is separate for backports.

How Has This Been Tested?

Builds.

Types of changes

  • Bug fix (non-breaking change which fixes an issue)
  • New feature (non-breaking change which adds functionality)
  • Performance enhancement (non-breaking change which improves efficiency)
  • Code cleanup (non-breaking change which makes code smaller or more readable)
  • Breaking change (fix or feature that would cause existing functionality to change)
  • Library ABI change (libzfs, libzfs_core, libnvpair, libuutil and libzfsbootenv)
  • Documentation (a change to man pages or other documentation)

Checklist:

  • My code follows the OpenZFS code style requirements.
  • I have updated the documentation accordingly.
  • I have read the contributing document.
  • I have added tests to cover my changes. – none apply
  • I have run the ZFS Test Suite with this change applied. – CI take my hand
  • All commit messages are properly formatted and contain Signed-off-by.

Found with -Wunused-but-set-variable on Clang trunk

Signed-off-by: Ahelenia Ziemiańska <nabijaczleweli@nabijaczleweli.xyz>
Found with -Wunused-but-set-variable on Clang trunk

Fixes: a1d477c ("OpenZFS 7614, 9064 - zfs device evacuation/removal")
Signed-off-by: Ahelenia Ziemiańska <nabijaczleweli@nabijaczleweli.xyz>
…ader fails

Found with -Wunused-but-set-variable on Clang trunk

Signed-off-by: Ahelenia Ziemiańska <nabijaczleweli@nabijaczleweli.xyz>
@nabijaczleweli nabijaczleweli force-pushed the why-does-mom-let-you-play-with-new-clang branch from 158d8d0 to 741925e Compare April 11, 2022 13:33
Copy link
Contributor

@behlendorf behlendorf left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks good, just a trivial nit. It wouldn't hurt to rebase this too before merging.

lib/libzfs/libzfs_import.c Show resolved Hide resolved
@behlendorf behlendorf added the Status: Accepted Ready to integrate (reviewed, tested) label Apr 11, 2022
…ARC header

Signed-off-by: Ahelenia Ziemiańska <nabijaczleweli@nabijaczleweli.xyz>
Signed-off-by: Ahelenia Ziemiańska <nabijaczleweli@nabijaczleweli.xyz>
@nabijaczleweli nabijaczleweli force-pushed the why-does-mom-let-you-play-with-new-clang branch from 741925e to d1bc3c6 Compare April 11, 2022 22:53
behlendorf pushed a commit that referenced this pull request Apr 13, 2022
Found with -Wunused-but-set-variable on Clang trunk

Fixes: a1d477c ("OpenZFS 7614, 9064 - zfs device evacuation/removal")
Reviewed-by: Brian Behlendorf <behlendorf1@llnl.gov>
Signed-off-by: Ahelenia Ziemiańska <nabijaczleweli@nabijaczleweli.xyz>
Closes #13304
behlendorf pushed a commit that referenced this pull request Apr 13, 2022
…ader fails

Found with -Wunused-but-set-variable on Clang trunk

Reviewed-by: Brian Behlendorf <behlendorf1@llnl.gov>
Signed-off-by: Ahelenia Ziemiańska <nabijaczleweli@nabijaczleweli.xyz>
Closes #13304
behlendorf pushed a commit that referenced this pull request Apr 13, 2022
…ARC header

Reviewed-by: Brian Behlendorf <behlendorf1@llnl.gov>
Signed-off-by: Ahelenia Ziemiańska <nabijaczleweli@nabijaczleweli.xyz>
Closes #13304
behlendorf pushed a commit that referenced this pull request Apr 13, 2022
Reviewed-by: Brian Behlendorf <behlendorf1@llnl.gov>
Signed-off-by: Ahelenia Ziemiańska <nabijaczleweli@nabijaczleweli.xyz>
Closes #13304
nabijaczleweli added a commit to nabijaczleweli/zfs that referenced this pull request Apr 13, 2022
…ader fails

Found with -Wunused-but-set-variable on Clang trunk

Upstream-commit: a4e0cee
Reviewed-by: Brian Behlendorf <behlendorf1@llnl.gov>
Signed-off-by: Ahelenia Ziemiańska <nabijaczleweli@nabijaczleweli.xyz>
Closes openzfs#13304
nabijaczleweli added a commit to nabijaczleweli/zfs that referenced this pull request Apr 13, 2022
…ader fails

Found with -Wunused-but-set-variable on Clang trunk

Upstream-commit: a4e0cee
Reviewed-by: Brian Behlendorf <behlendorf1@llnl.gov>
Signed-off-by: Ahelenia Ziemiańska <nabijaczleweli@nabijaczleweli.xyz>
Closes openzfs#13304
behlendorf pushed a commit that referenced this pull request Apr 15, 2022
…ader fails

Found with -Wunused-but-set-variable on Clang trunk

Upstream-commit: a4e0cee
Reviewed-by: Brian Behlendorf <behlendorf1@llnl.gov>
Signed-off-by: Ahelenia Ziemiańska <nabijaczleweli@nabijaczleweli.xyz>
Closes #13304
nicman23 pushed a commit to nicman23/zfs that referenced this pull request Aug 22, 2022
Found with -Wunused-but-set-variable on Clang trunk

Reviewed-by: Brian Behlendorf <behlendorf1@llnl.gov>
Signed-off-by: Ahelenia Ziemiańska <nabijaczleweli@nabijaczleweli.xyz>
Closes openzfs#13304
nicman23 pushed a commit to nicman23/zfs that referenced this pull request Aug 22, 2022
Found with -Wunused-but-set-variable on Clang trunk

Fixes: a1d477c ("OpenZFS 7614, 9064 - zfs device evacuation/removal")
Reviewed-by: Brian Behlendorf <behlendorf1@llnl.gov>
Signed-off-by: Ahelenia Ziemiańska <nabijaczleweli@nabijaczleweli.xyz>
Closes openzfs#13304
nicman23 pushed a commit to nicman23/zfs that referenced this pull request Aug 22, 2022
…ader fails

Found with -Wunused-but-set-variable on Clang trunk

Reviewed-by: Brian Behlendorf <behlendorf1@llnl.gov>
Signed-off-by: Ahelenia Ziemiańska <nabijaczleweli@nabijaczleweli.xyz>
Closes openzfs#13304
nicman23 pushed a commit to nicman23/zfs that referenced this pull request Aug 22, 2022
…ARC header

Reviewed-by: Brian Behlendorf <behlendorf1@llnl.gov>
Signed-off-by: Ahelenia Ziemiańska <nabijaczleweli@nabijaczleweli.xyz>
Closes openzfs#13304
nicman23 pushed a commit to nicman23/zfs that referenced this pull request Aug 22, 2022
Reviewed-by: Brian Behlendorf <behlendorf1@llnl.gov>
Signed-off-by: Ahelenia Ziemiańska <nabijaczleweli@nabijaczleweli.xyz>
Closes openzfs#13304
nicman23 pushed a commit to nicman23/zfs that referenced this pull request Aug 22, 2022
Found with -Wunused-but-set-variable on Clang trunk

Reviewed-by: Brian Behlendorf <behlendorf1@llnl.gov>
Signed-off-by: Ahelenia Ziemiańska <nabijaczleweli@nabijaczleweli.xyz>
Closes openzfs#13304
nicman23 pushed a commit to nicman23/zfs that referenced this pull request Aug 22, 2022
Found with -Wunused-but-set-variable on Clang trunk

Fixes: a1d477c ("OpenZFS 7614, 9064 - zfs device evacuation/removal")
Reviewed-by: Brian Behlendorf <behlendorf1@llnl.gov>
Signed-off-by: Ahelenia Ziemiańska <nabijaczleweli@nabijaczleweli.xyz>
Closes openzfs#13304
nicman23 pushed a commit to nicman23/zfs that referenced this pull request Aug 22, 2022
…ader fails

Found with -Wunused-but-set-variable on Clang trunk

Reviewed-by: Brian Behlendorf <behlendorf1@llnl.gov>
Signed-off-by: Ahelenia Ziemiańska <nabijaczleweli@nabijaczleweli.xyz>
Closes openzfs#13304
nicman23 pushed a commit to nicman23/zfs that referenced this pull request Aug 22, 2022
…ARC header

Reviewed-by: Brian Behlendorf <behlendorf1@llnl.gov>
Signed-off-by: Ahelenia Ziemiańska <nabijaczleweli@nabijaczleweli.xyz>
Closes openzfs#13304
nicman23 pushed a commit to nicman23/zfs that referenced this pull request Aug 22, 2022
Reviewed-by: Brian Behlendorf <behlendorf1@llnl.gov>
Signed-off-by: Ahelenia Ziemiańska <nabijaczleweli@nabijaczleweli.xyz>
Closes openzfs#13304
lundman pushed a commit to openzfsonwindows/openzfs that referenced this pull request Sep 2, 2022
Found with -Wunused-but-set-variable on Clang trunk

Reviewed-by: Brian Behlendorf <behlendorf1@llnl.gov>
Signed-off-by: Ahelenia Ziemiańska <nabijaczleweli@nabijaczleweli.xyz>
Closes openzfs#13304
lundman pushed a commit to openzfsonwindows/openzfs that referenced this pull request Sep 2, 2022
Found with -Wunused-but-set-variable on Clang trunk

Fixes: a1d477c ("OpenZFS 7614, 9064 - zfs device evacuation/removal")
Reviewed-by: Brian Behlendorf <behlendorf1@llnl.gov>
Signed-off-by: Ahelenia Ziemiańska <nabijaczleweli@nabijaczleweli.xyz>
Closes openzfs#13304
andrewc12 pushed a commit to andrewc12/openzfs that referenced this pull request Sep 23, 2022
Found with -Wunused-but-set-variable on Clang trunk

Reviewed-by: Brian Behlendorf <behlendorf1@llnl.gov>
Signed-off-by: Ahelenia Ziemiańska <nabijaczleweli@nabijaczleweli.xyz>
Closes openzfs#13304
andrewc12 pushed a commit to andrewc12/openzfs that referenced this pull request Sep 23, 2022
Found with -Wunused-but-set-variable on Clang trunk

Fixes: a1d477c ("OpenZFS 7614, 9064 - zfs device evacuation/removal")
Reviewed-by: Brian Behlendorf <behlendorf1@llnl.gov>
Signed-off-by: Ahelenia Ziemiańska <nabijaczleweli@nabijaczleweli.xyz>
Closes openzfs#13304
andrewc12 pushed a commit to andrewc12/openzfs that referenced this pull request Sep 23, 2022
…ader fails

Found with -Wunused-but-set-variable on Clang trunk

Reviewed-by: Brian Behlendorf <behlendorf1@llnl.gov>
Signed-off-by: Ahelenia Ziemiańska <nabijaczleweli@nabijaczleweli.xyz>
Closes openzfs#13304
andrewc12 pushed a commit to andrewc12/openzfs that referenced this pull request Sep 23, 2022
…ARC header

Reviewed-by: Brian Behlendorf <behlendorf1@llnl.gov>
Signed-off-by: Ahelenia Ziemiańska <nabijaczleweli@nabijaczleweli.xyz>
Closes openzfs#13304
andrewc12 pushed a commit to andrewc12/openzfs that referenced this pull request Sep 23, 2022
Reviewed-by: Brian Behlendorf <behlendorf1@llnl.gov>
Signed-off-by: Ahelenia Ziemiańska <nabijaczleweli@nabijaczleweli.xyz>
Closes openzfs#13304
andrewc12 pushed a commit to andrewc12/openzfs that referenced this pull request Sep 23, 2022
Found with -Wunused-but-set-variable on Clang trunk

Reviewed-by: Brian Behlendorf <behlendorf1@llnl.gov>
Signed-off-by: Ahelenia Ziemiańska <nabijaczleweli@nabijaczleweli.xyz>
Closes openzfs#13304
andrewc12 pushed a commit to andrewc12/openzfs that referenced this pull request Sep 23, 2022
Found with -Wunused-but-set-variable on Clang trunk

Fixes: a1d477c ("OpenZFS 7614, 9064 - zfs device evacuation/removal")
Reviewed-by: Brian Behlendorf <behlendorf1@llnl.gov>
Signed-off-by: Ahelenia Ziemiańska <nabijaczleweli@nabijaczleweli.xyz>
Closes openzfs#13304
andrewc12 pushed a commit to andrewc12/openzfs that referenced this pull request Sep 23, 2022
…ader fails

Found with -Wunused-but-set-variable on Clang trunk

Reviewed-by: Brian Behlendorf <behlendorf1@llnl.gov>
Signed-off-by: Ahelenia Ziemiańska <nabijaczleweli@nabijaczleweli.xyz>
Closes openzfs#13304
andrewc12 pushed a commit to andrewc12/openzfs that referenced this pull request Sep 23, 2022
…ARC header

Reviewed-by: Brian Behlendorf <behlendorf1@llnl.gov>
Signed-off-by: Ahelenia Ziemiańska <nabijaczleweli@nabijaczleweli.xyz>
Closes openzfs#13304
andrewc12 pushed a commit to andrewc12/openzfs that referenced this pull request Sep 23, 2022
Reviewed-by: Brian Behlendorf <behlendorf1@llnl.gov>
Signed-off-by: Ahelenia Ziemiańska <nabijaczleweli@nabijaczleweli.xyz>
Closes openzfs#13304
andrewc12 pushed a commit to andrewc12/openzfs that referenced this pull request Sep 23, 2022
Found with -Wunused-but-set-variable on Clang trunk

Reviewed-by: Brian Behlendorf <behlendorf1@llnl.gov>
Signed-off-by: Ahelenia Ziemiańska <nabijaczleweli@nabijaczleweli.xyz>
Closes openzfs#13304
andrewc12 pushed a commit to andrewc12/openzfs that referenced this pull request Sep 23, 2022
Found with -Wunused-but-set-variable on Clang trunk

Fixes: a1d477c ("OpenZFS 7614, 9064 - zfs device evacuation/removal")
Reviewed-by: Brian Behlendorf <behlendorf1@llnl.gov>
Signed-off-by: Ahelenia Ziemiańska <nabijaczleweli@nabijaczleweli.xyz>
Closes openzfs#13304
andrewc12 pushed a commit to andrewc12/openzfs that referenced this pull request Sep 23, 2022
…ader fails

Found with -Wunused-but-set-variable on Clang trunk

Reviewed-by: Brian Behlendorf <behlendorf1@llnl.gov>
Signed-off-by: Ahelenia Ziemiańska <nabijaczleweli@nabijaczleweli.xyz>
Closes openzfs#13304
andrewc12 pushed a commit to andrewc12/openzfs that referenced this pull request Sep 23, 2022
…ARC header

Reviewed-by: Brian Behlendorf <behlendorf1@llnl.gov>
Signed-off-by: Ahelenia Ziemiańska <nabijaczleweli@nabijaczleweli.xyz>
Closes openzfs#13304
andrewc12 pushed a commit to andrewc12/openzfs that referenced this pull request Sep 23, 2022
Reviewed-by: Brian Behlendorf <behlendorf1@llnl.gov>
Signed-off-by: Ahelenia Ziemiańska <nabijaczleweli@nabijaczleweli.xyz>
Closes openzfs#13304
andrewc12 pushed a commit to andrewc12/openzfs that referenced this pull request Sep 23, 2022
Found with -Wunused-but-set-variable on Clang trunk

Reviewed-by: Brian Behlendorf <behlendorf1@llnl.gov>
Signed-off-by: Ahelenia Ziemiańska <nabijaczleweli@nabijaczleweli.xyz>
Closes openzfs#13304
andrewc12 pushed a commit to andrewc12/openzfs that referenced this pull request Sep 23, 2022
Found with -Wunused-but-set-variable on Clang trunk

Fixes: a1d477c ("OpenZFS 7614, 9064 - zfs device evacuation/removal")
Reviewed-by: Brian Behlendorf <behlendorf1@llnl.gov>
Signed-off-by: Ahelenia Ziemiańska <nabijaczleweli@nabijaczleweli.xyz>
Closes openzfs#13304
andrewc12 pushed a commit to andrewc12/openzfs that referenced this pull request Sep 23, 2022
…ader fails

Found with -Wunused-but-set-variable on Clang trunk

Reviewed-by: Brian Behlendorf <behlendorf1@llnl.gov>
Signed-off-by: Ahelenia Ziemiańska <nabijaczleweli@nabijaczleweli.xyz>
Closes openzfs#13304
andrewc12 pushed a commit to andrewc12/openzfs that referenced this pull request Sep 23, 2022
…ARC header

Reviewed-by: Brian Behlendorf <behlendorf1@llnl.gov>
Signed-off-by: Ahelenia Ziemiańska <nabijaczleweli@nabijaczleweli.xyz>
Closes openzfs#13304
andrewc12 pushed a commit to andrewc12/openzfs that referenced this pull request Sep 23, 2022
Reviewed-by: Brian Behlendorf <behlendorf1@llnl.gov>
Signed-off-by: Ahelenia Ziemiańska <nabijaczleweli@nabijaczleweli.xyz>
Closes openzfs#13304
szubersk pushed a commit to szubersk/zfs that referenced this pull request Nov 16, 2022
Found with -Wunused-but-set-variable on Clang trunk

Reviewed-by: Brian Behlendorf <behlendorf1@llnl.gov>
Signed-off-by: Ahelenia Ziemiańska <nabijaczleweli@nabijaczleweli.xyz>
Closes openzfs#13304
(cherry picked from commit 63cb341)
szubersk pushed a commit to szubersk/zfs that referenced this pull request Nov 16, 2022
Found with -Wunused-but-set-variable on Clang trunk

Fixes: a1d477c ("OpenZFS 7614, 9064 - zfs device evacuation/removal")
Reviewed-by: Brian Behlendorf <behlendorf1@llnl.gov>
Signed-off-by: Ahelenia Ziemiańska <nabijaczleweli@nabijaczleweli.xyz>
Closes openzfs#13304
(cherry picked from commit 16c3290)
tonyhutter pushed a commit to tonyhutter/zfs that referenced this pull request Nov 29, 2022
Found with -Wunused-but-set-variable on Clang trunk

Reviewed-by: Brian Behlendorf <behlendorf1@llnl.gov>
Signed-off-by: Ahelenia Ziemiańska <nabijaczleweli@nabijaczleweli.xyz>
Closes openzfs#13304
tonyhutter pushed a commit to tonyhutter/zfs that referenced this pull request Nov 29, 2022
Found with -Wunused-but-set-variable on Clang trunk

Fixes: a1d477c ("OpenZFS 7614, 9064 - zfs device evacuation/removal")
Reviewed-by: Brian Behlendorf <behlendorf1@llnl.gov>
Signed-off-by: Ahelenia Ziemiańska <nabijaczleweli@nabijaczleweli.xyz>
Closes openzfs#13304
tonyhutter pushed a commit to tonyhutter/zfs that referenced this pull request Nov 30, 2022
Found with -Wunused-but-set-variable on Clang trunk

Reviewed-by: Brian Behlendorf <behlendorf1@llnl.gov>
Signed-off-by: Ahelenia Ziemiańska <nabijaczleweli@nabijaczleweli.xyz>
Closes openzfs#13304
tonyhutter pushed a commit to tonyhutter/zfs that referenced this pull request Nov 30, 2022
Found with -Wunused-but-set-variable on Clang trunk

Fixes: a1d477c ("OpenZFS 7614, 9064 - zfs device evacuation/removal")
Reviewed-by: Brian Behlendorf <behlendorf1@llnl.gov>
Signed-off-by: Ahelenia Ziemiańska <nabijaczleweli@nabijaczleweli.xyz>
Closes openzfs#13304
tonyhutter pushed a commit to tonyhutter/zfs that referenced this pull request Dec 1, 2022
Found with -Wunused-but-set-variable on Clang trunk

Reviewed-by: Brian Behlendorf <behlendorf1@llnl.gov>
Signed-off-by: Ahelenia Ziemiańska <nabijaczleweli@nabijaczleweli.xyz>
Closes openzfs#13304
tonyhutter pushed a commit to tonyhutter/zfs that referenced this pull request Dec 1, 2022
Found with -Wunused-but-set-variable on Clang trunk

Fixes: a1d477c ("OpenZFS 7614, 9064 - zfs device evacuation/removal")
Reviewed-by: Brian Behlendorf <behlendorf1@llnl.gov>
Signed-off-by: Ahelenia Ziemiańska <nabijaczleweli@nabijaczleweli.xyz>
Closes openzfs#13304
szubersk pushed a commit to szubersk/zfs that referenced this pull request Dec 7, 2022
Found with -Wunused-but-set-variable on Clang trunk

Reviewed-by: Brian Behlendorf <behlendorf1@llnl.gov>
Signed-off-by: Ahelenia Ziemiańska <nabijaczleweli@nabijaczleweli.xyz>
Closes openzfs#13304
(cherry picked from commit 63cb341)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Status: Accepted Ready to integrate (reviewed, tested)
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants