Merged
Conversation
Replace the outdated dbhi/qus/action@mainwith a more current alternative for QEMU user-mode emulation setup. Signed-off-by: Daniel Wagner <[email protected]>
459574e to
dd5b97e
Compare
blktests nvme/039 is assuming that the first ioctl issued is the expected IO passthru. Though the recent introduce ioctl probing breaks the tests. One could argue that the test should be made more robust but it's probably a good idea to have a way to disable this feature anyway. The obvious to way to implement this feature is to add a flag argument to nvme_open. This works for all nvme commands but not for the nvmf because under the hood new transport handles are created when necessary. Since this is a global flag anyway, add it to the global context. Signed-off-by: Daniel Wagner <[email protected]>
Use the nvmf prefix for the common fabrics command line arguments, instead the fabrics prefix. Signed-off-by: Daniel Wagner <[email protected]>
Use the same naming scheme as in fabrics, where the common command line argumnent struct is called nvmf_args. Signed-off-by: Daniel Wagner <[email protected]>
Let NVMF_ARGS use NVME_ARGS, so that the common default comamnd line arguments are also present for the fabrics commands. Signed-off-by: Daniel Wagner <[email protected]>
995cb12 to
c748875
Compare
There was a problem hiding this comment.
Pull request overview
This PR refactors the nvme-cli codebase to consolidate global command-line options (verbose, output-format, timeout, etc.) into a unified NVME_ARGS macro and nvme_args global structure. The change introduces the --no-ioctl-probing option to control 64-bit IOCTL support probing and replaces OPT_ARGS with NVME_ARGS across most plugin commands.
Changes:
- Renamed
nvme_configstruct tonvme_argsand addedno_ioctl_probingfield - Replaced
OPT_ARGSwithNVME_ARGSmacro across all plugin commands that useparse_and_open() - Removed local
output_format,verbose, andtimeoutfields from command-specific config structs - Added
nvme_set_ioctl_probing()function to libnvme to control IOCTL probing behavior - Updated
parse_and_open()to handle the new --no-ioctl-probing option
Reviewed changes
Copilot reviewed 54 out of 54 changed files in this pull request and generated 2 comments.
Show a summary per file
| File | Description |
|---|---|
| nvme.h | Renamed nvme_config to nvme_args, added no_ioctl_probing field, updated NVME_ARGS macro |
| nvme.c | Updated all references from nvme_cfg to nvme_args, added ioctl probing logic |
| nvme-print.c | Updated dry_run reference to use nvme_args |
| nvme-print-json.c | Updated output_format_ver references to use nvme_args |
| nvme-rpmb.c | Replaced OPT_ARGS with NVME_ARGS |
| logging.c | Updated references to use nvme_args |
| fabrics.c | Renamed fabric_args to nvmf_args, replaced OPT_ARGS with NVME_ARGS, removed local verbose fields |
| libnvme/src/nvme/tree.c | Initialize ioctl_probing to true in nvme_create_global_ctx |
| libnvme/src/nvme/private.h | Added ioctl_probing field to nvme_global_ctx |
| libnvme/src/nvme/linux.h | Added nvme_set_ioctl_probing() function declaration |
| libnvme/src/nvme/linux.c | Implemented nvme_set_ioctl_probing() and conditional probing logic |
| libnvme/src/libnvme.ld | Exported nvme_set_ioctl_probing symbol |
| plugins//.c | Replaced OPT_ARGS with NVME_ARGS, removed local output_format/verbose/timeout fields, updated to use nvme_args.* |
| .github/workflows/build.yml | Updated QEMU action from dbhi/qus to docker/setup-qemu-action@v3 |
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
c748875 to
5385b8b
Compare
The global command lines arguments should be used for every command, so that we have a consistent user experience. Signed-off-by: Daniel Wagner <[email protected]>
5385b8b to
8c54b55
Compare
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
We have defined a set of global command options but not all commands us it. Make
NVME_OPTSa bit more unusable and replace OPT_ARGS with it.This change is based after realizing that the global command options are not so global after all, when introducing the
--no-ioctl-probingknob.See also: linux-blktests/blktests#224 (comment)