-
Notifications
You must be signed in to change notification settings - Fork 349
audio: igo_nr: added igo_nr component #4017
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
Conversation
src/audio/igo_nr/igo_nr.c
Outdated
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.
please show me where the wrapper would reject, i don't seen anything in the params or prepare callbacks that would reject s24/s32/float or other channel counts or rates
src/audio/igo_nr/igo_nr.c
Outdated
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.
yes, that is fine, but SOF can try and open the component with an invalid format/channels/rate, even if your topology specifies certain config, do not assume that the next configuration engineer will make the same wise decisions. The code should defend against invalid configs.
5dea5af to
b018cac
Compare
cujomalainey
left a comment
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.
getting better, but you are still missing your checks in either prepare or params to verify the current hardware params are valid for your capabilities.
Inside |
Maybe I'm missing something, but I don't see where do you check for sample rate? |
cujomalainey
left a comment
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.
component looks good, Intel please verify you are ok with topology changes. Thanks for keeping with this.
@cujomalainey thanks! Just updated the copyright. |
|
I would ideally like to get one more review, @ranj063 mind doing a review? |
|
Seems like the reviewer has not responded yet. Is there anything I can do? I just check the CI messages again and fix most of the complains. (The remaining complains have been discussed before.) Please let me know if there is any PR blocker other than this one. |
|
@fuyuntsuo I will ping @ranj063 to take a look. |
ranj063
left a comment
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.
I would ideally like to get one more review, @ranj063 mind doing a review?
@cujomalainey working on it now.
src/audio/igo_nr/igo_nr.c
Outdated
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.
NULL assignemtn not necessary
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.
With this NULL assignment, the memory allocations afterwards can share the same error handler.
That is, when if (!cd) holds (L243:igo_nr.c), then it goes to the last and rfree(NULL) becomes nop.
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.
sorry not getting this point. Is (!cd) is true, that mean cd is NULL anyway
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.
@fuyuntsuo none of the error paths before your alloc for cd jump to err so this NULL doesn't make a difference
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.
Lets fix this incrementally.
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.
Get it @ranj063 @cujomalainey. This issue has been resolved in #4152.
src/audio/igo_nr/igo_nr.c
Outdated
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.
looks like we dont need ret at all. just remoe it and return 0?
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.
the ret was missing. I add it back. thanks!
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.
sorry not getting it. I meant just return 0 here and remove the declaration for "ret". You're not using it at all other than initializing it to 0
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.
Yes you are right. Return 0 here is just fine. Thanks!
@lgirdwood the dynamic pipeline PR is merged to sof-dev. Switching just the pipelines for IGO to dynamic is also supprted in topology. But like we discussed, the dynamic pipelines patches are not upstream yet and also not part of the 5.4 kernel. |
cujomalainey
left a comment
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.
@ranj063 thanks for catching that, I really need to get cppcheck into the CI for those kind of errors.
This commit added IGO_NR component into sof-tgl-max98373-rt5682.m4 as DMIC capture PCM99 pipeline. Signed-off-by: fy.tsuo <fy.tsuo@intelli-go.com>
|
Despite the changes above, I also moved a struct (L32:igo_nr.c) and a macro (L30:igo_nr.c) from |
src/audio/igo_nr/igo_nr.c
Outdated
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.
return err so you dont lose the original error?
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.
Done. Thanks!
src/audio/igo_nr/igo_nr.c
Outdated
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.
remove newline
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.
done.
src/audio/igo_nr/igo_nr.c
Outdated
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.
sorry not getting it. I meant just return 0 here and remove the declaration for "ret". You're not using it at all other than initializing it to 0
src/audio/igo_nr/igo_nr.c
Outdated
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.
remove new line
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.
done.
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.
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.
@fuyuntsuo this can be fixed incrementally as I'm going to tag v1.8-rc1 today. The newline needs to go after the variable declarations i.e. after line 601 and before 602.
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.
Thanks! This issue has been resolved in #4152.
Thanks for the update @fuyuntsuo. Just a few more minor comments |
This commit consists of files for adding IGO_NR component in arbitrary topology. The proprietary static library shall be released by intelliGo via private channel upon request. Signed-off-by: fy.tsuo <fy.tsuo@intelli-go.com>
NP. Thanks for reviewing the PR as well. All the issues have been addressed. Please review again. Thanks! |
src/audio/igo_nr/igo_nr.c
Outdated
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.
Lets fix this incrementally.
src/audio/igo_nr/igo_nr.c
Outdated
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.
Lets remove the enum since ALSA will map the switch as an ON/OFF type control. @fuyuntsuo this can be done as an update.
src/audio/igo_nr/igo_nr.c
Outdated
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.
@fuyuntsuo this can be fixed incrementally as I'm going to tag v1.8-rc1 today. The newline needs to go after the variable declarations i.e. after line 601 and before 602.
|
@fuyuntsuo please fix the comments above in a new PR - we can merge this fix PR for v1.8-rc2 |
No problem. We will address the remaining issues in the new PR. Thanks! |
The new PR is #4152. |

Added intelliGo noise reduction wrapper codes and topology.
The proprietary static library shall be released by intelliGo via private channel upon request.