-
Notifications
You must be signed in to change notification settings - Fork 293
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
remoteproc: Fix the NULL vs RPROC_IS_ERR() bug for remoteproc_get_rsc_table() #571
Conversation
mengtanhzc
commented
Mar 16, 2024
- Since remoteproc_get_rsc_table() returns RPROC_ERR_PTR and never NULL, use RPROC_IS_ERR() to check the return value.
|
I'll update remoteproc_get_rsc_table() later. Thanks for the review! |
The rsc_table is checked against NULL in remoteproc_load(). But remoteproc_get_rsc_table() returns ERR_PTR after an error. The error return value is unnecessary, just return NULL for failure. Signed-off-by: Zongcheng Han <[email protected]>
I have updated the commit, please review it again. Thanks a lot. |
I'd say yes. All these custom error codes are only used internally by the remoteproc framework, not sure why they exist at all. Everywhere else we just use the standard |
Agree. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Good to merge.