-
Notifications
You must be signed in to change notification settings - Fork 350
audio: module-adapter: fix a print and a comment #10531
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
base: main
Are you sure you want to change the base?
Conversation
Simplify a warning message and fix a typo in a comment. Signed-off-by: Guennadi Liakhovetski <guennadi.liakhovetski@linux.intel.com>
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.
Pull request overview
This PR updates logging and comments in the audio module adapter, aiming to simplify an error message and correct a typo in an explanatory comment.
Changes:
- Simplified the NULL-config error log in
module_adapter_new_ext(). - Fixed a typo in the
dst->ext_datalifetime comment.
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
| if (!config) { | ||
| comp_cl_err(drv, "wrong input params! drv = %zx config = %zx", | ||
| (size_t)drv, (size_t)config); | ||
| comp_cl_err(drv, "NULL config! drv = %p", drv); |
Copilot
AI
Feb 9, 2026
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.
Using %p requires a void* argument; passing drv (const struct comp_driver*) can trigger -Wformat under -Werror builds. Cast drv to (const void*) (or (void*)) when logging it, or switch back to an integer format with an explicit cast.
| comp_cl_err(drv, "NULL config! drv = %p", drv); | |
| comp_cl_err(drv, "NULL config! drv = %p", (const void *)drv); |
| @@ -248,8 +247,7 @@ struct comp_dev *module_adapter_new_ext(const struct comp_driver *drv, | |||
| * NOTE: dst->ext_data points to stack variable and contains | |||
| * pointers to IPC payload mailbox, so its only valid in | |||
Copilot
AI
Feb 9, 2026
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.
Grammar: "its" should be "it's" (contraction for "it is") in this comment.
| * pointers to IPC payload mailbox, so its only valid in | |
| * pointers to IPC payload mailbox, so it's only valid in |
| @@ -248,8 +247,7 @@ struct comp_dev *module_adapter_new_ext(const struct comp_driver *drv, | |||
| * NOTE: dst->ext_data points to stack variable and contains | |||
| * pointers to IPC payload mailbox, so its only valid in | |||
| * functions that called from this function. This why | |||
Copilot
AI
Feb 9, 2026
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.
Grammar: "This why" should be "This is why" in this comment.
| * functions that called from this function. This why | |
| * functions that called from this function. This is why |
| @@ -248,8 +247,7 @@ struct comp_dev *module_adapter_new_ext(const struct comp_driver *drv, | |||
| * NOTE: dst->ext_data points to stack variable and contains | |||
| * pointers to IPC payload mailbox, so its only valid in | |||
| * functions that called from this function. This why | |||
Copilot
AI
Feb 9, 2026
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.
Grammar: "functions that called" should be "functions that are called" in this comment.
| * functions that called from this function. This why | |
| * functions that are called from this function. That is why |
Simplify an error message and fix a typo in a comment.