[pull] master from linux-nvme:master#204
Merged
Merged
Conversation
added 2 commits
April 30, 2026 18:37
Extend generate-accessors.py to emit three new SWIG fragment files from
the existing !generate-accessors annotations in private.h and
private-fabrics.h:
accessors.i — kernel-object structs (Ctrl, Host, Subsystem,
Namespace, GlobalCtx)
accessors-fabrics.i — fabrics-specific structs
nvme-manual-bridges.i — residual hand-written %rename bridges
A new struct-level annotation !generate-python[:alias=NAME] gates
emission for Python and carries the PascalCase class alias. Remove the
hand-written %rename(ctrl) / %rename(host) / ... lines from nvme.i;
they are now generator-emitted.
Restructure nvme.i so all %typemap directives precede the generated
%include "accessors.i". SWIG freezes type-to-typemap associations when
it first processes a struct body; struct bodies now arrive via the
generated include so typemaps must come first.
A generator-emitted _nvme_guarded_setattr is installed on each class at
import to catch typos and writes to read-only (%immutable) properties.
C-internal iteration helpers are renamed with a leading underscore via
%rename to keep them out of the public API surface.
Update nvme.i docstrings to Pythonic style (Args:/Returns: conventions,
PascalCase class names, module-level usage examples). Update tests and
examples to use the new API.
Verified: meson test -C .build passes (64 OK, 2 expected failures).
Signed-off-by: Martin Belanger <Martin.Belanger@dell.com>
Assisted-by: Claude Sonnet 4.6 <noreply@anthropic.com>
- Convert connected() and is_registration_supported() to read-only Python properties (connected, registration_supported) - Delete set_symname(); host.hostsymname is already writable via the generated SWIG field descriptor - Rename registration_ctrl() to registration_control() to reflect that the method is a multi-action control interface (register, deregister, update via NVMF_DIM_TAS_*), not a single register operation - Update test-objects.py to match the new API Signed-off-by: Martin Belanger <martin.belanger@dell.com> Assisted-by: Claude Sonnet <noreply@anthropic.com>
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 subscribe to this conversation on GitHub.
Already have an account?
Sign in.
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.
See Commits and Changes for more details.
Created by
pull[bot] (v2.0.0-alpha.4)
Can you help keep this open source service alive? 💖 Please sponsor : )