-
Notifications
You must be signed in to change notification settings - Fork 349
topology: sof-glk-cs42l42: add topology for cs42l42 #4121
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
|
The machine driver is here: thesofproject/linux#2884 |
plbossart
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.
see question below @brentlu
tools/topology/CMakeLists.txt
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.
looking at the commit message, could we use just one fine with two macros for the dailink and bitclock delay? Topologies are hard to maintain, and if we can factor it's best.
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.
sure, will avoid adding new topology file.
|
Implement cs42l42 support in sof-glk-da7219.m4 file. Three conf files, sof-glk-da7219.conf, sof-glk-cs42l42.conf, and sof-glk-eq-da7219.conf are checked to make sure the topology files are generated correctly. |
plbossart
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.
We can simplify further by modifying the machine driver and using SSPs first, then DMIC and last HDMI.
tools/topology/sof-glk-da7219.m4
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.
this is too complicated, there is no reason to reorder the BE dailinks, we can change the machine driver and first add the two SSP links, then DMIC and last HDMI. that way only the SSP number and configuration will change, and dmic/HDMI can be moved out of the conditional part.
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.
got it. will update the commits.
Add support for cs42l42 running on GLK boards. We add a 10 ms BCLK delay to the SSP_CONFIG_DATA of SSP2 since the codec PLL is locking on BCLK. Without the delay, there could be noise on TX path. Signed-off-by: Brent Lu <brent.lu@intel.com>
plbossart
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.
Looks good @brentlu
See below suggested change if you want to improve further with more than 16-bit data.
| SSP_CLOCK(bclk, 3072000, codec_slave), | ||
| SSP_CLOCK(fsync, 48000, codec_slave), | ||
| SSP_TDM(2, 32, 3, 3), | ||
| SSP_CONFIG_DATA(SSP, 2, 16, 1, 0, 10))) |
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.
one last question: is the 16 here required? You are using 32 bits so you could send 24-bit data without issues. I don't know why the da7219 used 16 bits, but for cs42l42 you may want to revisit this.
This could be improved in a follow-up patch
Add a topogy file for cs42l42 running on GLK boards. It's similar to da7219's
topology but we rearrange the id of backend DAI Links by moving speaker amp's
id (SSP1) to the end of links to reflect the machine driver changes from CML
platform.
We also add a 10 ms BCLK delay in this topology since the codec PLL is locking
on BCLK or there will be noise on TX path.
Signed-off-by: Brent Lu brent.lu@intel.com