-
Notifications
You must be signed in to change notification settings - Fork 438
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
rust/kernel: chrdev: remove unnecessary pinning #304
Conversation
`chrdev`'s `Registration` and `RegistrationInner` do not contain any self-referential or borrowed-with-kernel structures. Therefore they do not require pinning. Remove all pinning. This simplifies the code greatly, and eliminates an unsafe block, and a fallible `Box` allocation. As part of this commit, also update `chrdev` client drivers. Signed-off-by: Sven Van Asbroeck <[email protected]>
Review of
|
I think we should keep the pinning, and use |
I'm in the process of learning about pinning. Can folks confirm that the pinning is indeed redundant here? I'm not 100% sure myself. If so, then pinning can be removed. Next, the question arises whether it should be removed. That's a different question altogether :) |
Pinning essentially means that a stable address is wanted and the object cannot be freely moved. So But I think we probably want to remove this indirection, and let |
Very simple to do - just revert #207 |
Ah, sorry, I am not aware of the PR. We could make |
@ojeda How can I assign a "Prio: low" label to this PR? |
Let me give you Triage permissions :) |
No consensus that this is worthwhile. |
chrdev
'sRegistration
andRegistrationInner
do not contain anyself-referential or borrowed-with-kernel structures. Therefore they
do not require pinning.
Remove all pinning. This simplifies the code greatly, and eliminates
an unsafe block, and a fallible
Box
allocation.As part of this commit, also update
chrdev
client drivers.Signed-off-by: Sven Van Asbroeck [email protected]