-
Notifications
You must be signed in to change notification settings - Fork 163
udiskslinuxprovider: Track NVMe subsystems #1435
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
Open
tbzatek
wants to merge
9
commits into
storaged-project:master
Choose a base branch
from
tbzatek:uevent-pre-post
base: master
Could not load branches
Branch not found: {{ refName }}
Loading
Could not load tags
Nothing to show
Loading
Are you sure you want to change the base?
Some commits from the old base branch may be removed from the timeline,
and old review comments may become outdated.
Open
Conversation
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
c336aaf to
00a1118
Compare
This comment was marked as duplicate.
This comment was marked as duplicate.
1 similar comment
This comment was marked as duplicate.
This comment was marked as duplicate.
This comment was marked as outdated.
This comment was marked as outdated.
00a1118 to
2dc7e18
Compare
This comment was marked as outdated.
This comment was marked as outdated.
1 similar comment
This comment was marked as outdated.
This comment was marked as outdated.
With the planned uevent action extension of pre-/post- actions the string comparison gets quite heavy. Better to use numeric constants to spare some CPU cycles.
This lays down a foundation for tracking NVMe subsystems, effectively creating uevent broadcast groups. This allows drive and block objects to receive uevents targeted for other devices in the subsystem.
In certain situations, e.g. when the kernel host nvme driver failed to probe the device or when the controller was not in a 'live' state, an invalid Subsystem NQN values may appear in sysfs. In such a case subsystem tracking should be skipped with an expectation of another uevent once the controller recovers or becomes live. The commonly seen values are '(efault)' and '(null)'. See also https://www.kernel.org/doc/Documentation/core-api/printk-formats.rst
2dc7e18 to
0aa10fa
Compare
Member
Author
|
This still seems to fail in a few percent of cases in |
This comment was marked as outdated.
This comment was marked as outdated.
…vent Update block and drive object interfaces on an incoming NVMe subsystem uevent. This allows to properly reflect the state of a NVMe subsystem native multipath where one path disappears and uevents are sent only to a limited number of devices. This allows e.g. to update Drive property references once the primary/active path/controller disappears and another one in the subsystem takes over.
Despite that UDisksLinuxProvider should register and process incoming uevent for the newly connected controller(s), the purpose of triggering additional subsystem uevent is to ensure all objects are up to date upon the Connect() method call return.
Trigger a synchronous subsystem uevent so that all objects in the subsystem are fully updated upon the method call return.
fb021e3 to
c7911bb
Compare
Member
Author
|
Tests seem to be stable for the past couple of runs, ready for review. |
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.
This lays down a foundation for tracking NVMe subsystems, effectively creating uevent broadcast groups. This allows drive and block objects to receive uevents targeted for other devices in the subsystem.