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

tree: do not issue an error when subsys lookup fails during scanning #778

Merged
merged 1 commit into from
Feb 7, 2024

Conversation

igaw
Copy link
Collaborator

@igaw igaw commented Feb 6, 2024

The scan operation is not atomically done and the sysfs might change while we are iterating over it. Thus, it's possible that we find a controller but when we try to lookup the corresponding subsystem it might already destroyed and removed.

This error makes blktests fail because it finds controllers controller which are not under control of blktests, instead they are created and destroyed by the udev auto connect rules.

These resources appear and disappear while the test runs but when we scan sysfs we issue errors for unrelated resources. Thus just do not issue a error, turn this into debug log message.

Anyway, we already do just return error codes for other reason in this function anyway without logging.

The scan operation is not atomically done and the sysfs might change
while we are iterating over it. Thus, it's possible that we find a
controller but when we try to lookup the corresponding subsystem it might
already destroyed and removed.

This error makes blktests fail because it finds controllers controller
which are not under control of blktests, instead they are created and
destroyed by the udev auto connect rules.

These resources appear and disappear while the test runs but when we
scan sysfs we issue errors for unrelated resources. Thus just do not
issue a error, turn this into debug log message.

Anyway, we already do just return error codes for other reason in this
function anyway without logging.

Signed-off-by: Daniel Wagner <[email protected]>
@igaw igaw merged commit 3f89041 into linux-nvme:master Feb 7, 2024
14 checks passed
@igaw igaw deleted the fix-scan branch February 7, 2024 11:27
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant