Skip to content
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

intel_adsp20: Enable LNL (ACE 2.0) platform in sof #7479

Merged
merged 3 commits into from
May 24, 2023

Conversation

jxstelter
Copy link
Contributor

@jxstelter jxstelter commented Apr 20, 2023

This patch contains changes required to enable LNL (ACE 2.0) platform in SOF
and bring-up basic interfaces and features.

Required zephyr change:

Signed-off-by: Jaroslaw Stelter [email protected]

@jxstelter jxstelter force-pushed the lnl-enable-in-sof branch 4 times, most recently from eab1abd to 7f4e774 Compare April 20, 2023 14:20
src/include/sof/lib/dai-zephyr.h Show resolved Hide resolved
src/ipc/ipc4/dai.c Outdated Show resolved Hide resolved
src/ipc/ipc4/dai.c Outdated Show resolved Hide resolved
src/ipc/ipc4/helper.c Outdated Show resolved Hide resolved
Copy link
Member

@plbossart plbossart left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

ok for SSP/DMIC, NAK on SoundWire/ALH

src/audio/copier/copier.c Outdated Show resolved Hide resolved
Copy link
Member

@plbossart plbossart left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

couple of misses in the LNL definitions @jxstelter

app/boards/intel_adsp_ace20_lnl.conf Outdated Show resolved Hide resolved
app/boards/intel_adsp_ace20_lnl.conf Outdated Show resolved Hide resolved
app/boards/intel_adsp_ace20_lnl.conf Show resolved Hide resolved
src/platform/Kconfig Outdated Show resolved Hide resolved
src/platform/lunarlake/include/platform/lib/dai.h Outdated Show resolved Hide resolved
src/platform/lunarlake/include/platform/lib/dma.h Outdated Show resolved Hide resolved
src/platform/lunarlake/lib/clk.c Show resolved Hide resolved
src/include/sof/audio/ipc-config.h Outdated Show resolved Hide resolved
src/include/sof/audio/ipc-config.h Outdated Show resolved Hide resolved
Copy link
Collaborator

@kv2019i kv2019i left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think this looks good to go (no blocking issues aside the ones already pointed out by other reviewers). In general, the src/platform part could be slimmed down further, but I'd not start doing this work in this LNL PR as the actions need to be done on MTL as well (relates to #7248 ).

app/boards/intel_adsp_ace20_lnl.conf Outdated Show resolved Hide resolved
app/boards/intel_adsp_ace20_lnl.conf Show resolved Hide resolved
app/boards/intel_adsp_ace20_lnl.conf Outdated Show resolved Hide resolved
src/include/sof/audio/ipc-config.h Outdated Show resolved Hide resolved
zephyr/CMakeLists.txt Outdated Show resolved Hide resolved
app/boards/intel_adsp_ace20_lnl.conf Show resolved Hide resolved
@jxstelter jxstelter force-pushed the lnl-enable-in-sof branch 2 times, most recently from be8fef4 to 78b4659 Compare April 28, 2023 13:24
@jxstelter jxstelter force-pushed the lnl-enable-in-sof branch from 32b358e to 5306b2b Compare May 15, 2023 10:10
jxstelter added 2 commits May 15, 2023 14:20
Add initial LNL configuration.
Enable building for xt-clang.

Signed-off-by: Jaroslaw Stelter <[email protected]>
The LNL platform added to RI_INFO_FIXME
list in build script.

Signed-off-by: Jaroslaw Stelter <[email protected]>
@jxstelter jxstelter force-pushed the lnl-enable-in-sof branch 2 times, most recently from 211b10b to 3a578c4 Compare May 15, 2023 12:26
src/include/sof/audio/ipc-config.h Outdated Show resolved Hide resolved
src/ipc/ipc4/dai.c Outdated Show resolved Hide resolved
Copy link
Collaborator

@lyakh lyakh left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

the only remaining request from me is that dai_set_link_hda_config() should be implemented in the HDA driver

@jxstelter
Copy link
Contributor Author

jxstelter commented May 17, 2023

The problem with this is that depending on interface (DMIC vs SSP) different fields of IPC4 (Init Instance) needs to be used to calculate the link config value. If moved to zephyr driver, we need to pass there several parameters instead of single uint16_t value. Therefore I prepare it here and pass to driver which programs HW register. Drivers do not understand IPC4 payload structure so anyway we needs to parse it in SOF.

src/ipc/ipc4/helper.c Outdated Show resolved Hide resolved
@jxstelter
Copy link
Contributor Author

@plbossart Pierre, is your change request resolved?

@wszypelt
Copy link

SOFCI TEST

@kv2019i
Copy link
Collaborator

kv2019i commented May 23, 2023

@lyakh Ok with the response on link_config? This is anyways the current DAI interface in Zephyr, so I'd say even if we'd change it, this would have to be in different pr.

@plbossart Ping?

src/audio/copier/copier.c Show resolved Hide resolved
src/audio/copier/copier.c Show resolved Hide resolved
src/audio/copier/copier.c Show resolved Hide resolved
src/ipc/ipc4/dai.c Outdated Show resolved Hide resolved
src/audio/dai-zephyr.c Outdated Show resolved Hide resolved
src/include/sof/audio/ipc-config.h Outdated Show resolved Hide resolved
src/ipc/ipc4/helper.c Outdated Show resolved Hide resolved
src/ipc/ipc4/helper.c Outdated Show resolved Hide resolved
@lyakh
Copy link
Collaborator

lyakh commented May 24, 2023

@lyakh Ok with the response on link_config? This is anyways the current DAI interface in Zephyr, so I'd say even if we'd change it, this would have to be in different pr.

@kv2019i yep, just let's address comments from @ujfalusi

@jxstelter jxstelter force-pushed the lnl-enable-in-sof branch from de2a84c to 8b71fab Compare May 24, 2023 10:35
src/audio/copier/copier.c Outdated Show resolved Hide resolved
src/audio/copier/copier.c Outdated Show resolved Hide resolved
In LNL the GPDMA engine was removed. Instead HD Audio
Link DMA is used to transport data over audio interfaces.
Since HD Audio is a Host managed engine, the link configuration
is passed through IPCv4.
The configuration must be forwarded to appropriate interface driver
to configure HW.

Signed-off-by: Jaroslaw Stelter <[email protected]>
@jxstelter jxstelter force-pushed the lnl-enable-in-sof branch from 8b71fab to ab41814 Compare May 24, 2023 12:42
Copy link
Contributor

@ujfalusi ujfalusi left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Only couple of 'I prefer to write code in a different way' type of things, but those are subjective I guess as no one pointed out those.

I don't have further comments.

@kv2019i kv2019i dismissed plbossart’s stale review May 24, 2023 15:51

No re-review in a week

@kv2019i
Copy link
Collaborator

kv2019i commented May 24, 2023

@kv2019i kv2019i merged commit 22ad526 into thesofproject:main May 24, 2023
@marc-hb
Copy link
Collaborator

marc-hb commented May 25, 2023

This unused variable 'copier_config' warning looks trivial after all. I suspected some hard to fix, platform-dependent macrobatics but I found none, this local variable is just unused always.

fixed

Somehow it came back. Fixed (again?) in

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.