forked from torvalds/linux
-
Notifications
You must be signed in to change notification settings - Fork 133
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
SoundWire: use HDAudio registers for LunarLake #4471
Merged
plbossart
merged 5 commits into
thesofproject:topic/sof-dev
from
plbossart:sdw/wake-en-sts
Jul 28, 2023
Merged
SoundWire: use HDAudio registers for LunarLake #4471
plbossart
merged 5 commits into
thesofproject:topic/sof-dev
from
plbossart:sdw/wake-en-sts
Jul 28, 2023
Conversation
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
RanderWang
reviewed
Jul 12, 2023
bardliao
reviewed
Jul 12, 2023
plbossart
force-pushed
the
sdw/wake-en-sts
branch
2 times, most recently
from
July 12, 2023 05:44
0990a2c
to
5107b14
Compare
bardliao
previously approved these changes
Jul 12, 2023
RanderWang
previously approved these changes
Jul 12, 2023
This needs to be rebased once #4440 is merged. |
Likely a combination of copy-paste and test coverage problem. Oops. Fixes: 87a6ddc ("ASoC: SOF: Intel: hda-mlink: program SoundWire LSDIID registers") Signed-off-by: Pierre-Louis Bossart <[email protected]>
The existing code cannot work for LunarLake, let's add a layer of abstraction. No functional change in this patch. Signed-off-by: Pierre-Louis Bossart <[email protected]>
We need to retrieve the current value to deal with the HDAudio WAKEEN/WAKESTS setup. Signed-off-by: Pierre-Louis Bossart <[email protected]>
The initial programming sequence only worked in the case where the OFLEN bit is set, i.e. the DSP handles the SoundWire interface. In the Linux integration, the interface is owned by the host. This disconnect leads to wake-ups being routed to the DSP and not to the host. The suggested update is to rely on the global HDAudio WAKEEN/STATESTS registers, with the SDI bits used to program the wakeups and check the status. Note that there is no way to know which peripheral generated a wake-up. When the hardware detects a change, it sets all the bits corresponding to LSDIIDx. The LSDIIDx information can be used to figure out on which link the wakeup happened, but for further details the software will have to check the status of each peripheral. Signed-off-by: Pierre-Louis Bossart <[email protected]>
The global STATESTS register will provide information on all links. Rather than iterate on all possible links, the helpers only filters the range of possible bits for a quick lookup. The process_wakeen() helper will walk through all the links and deal with wakes. Signed-off-by: Pierre-Louis Bossart <[email protected]>
plbossart
force-pushed
the
sdw/wake-en-sts
branch
from
July 13, 2023 11:10
5107b14
to
f497c1a
Compare
plbossart
requested review from
shumingfan,
oder-chiou,
jack-cy-yu,
ryans-lee,
vijendarmukunda,
libinyang,
lyakh,
juimonen,
lgirdwood,
ranj063,
kv2019i,
dbaluta,
ujfalusi and
kuanhsuncheng
as code owners
July 13, 2023 11:11
bardliao
approved these changes
Jul 13, 2023
RanderWang
approved these changes
Jul 17, 2023
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
important update reflecting updated programming flows, the use of SDWWAKEEN is reserved to the DSP and the global HDAudio registers must be used to detect wakes from low-power modes.
@bardliao @RanderWang comments welcome.