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

switch_tplg: Implement tool for switching topologies #9525

Draft
wants to merge 1 commit into
base: main
Choose a base branch
from

Conversation

AnneOnciulescu
Copy link
Contributor

Implements a tool for switching between audio topologies without the need for rebooting.

After selecting the target topology, certain kernel modules are removed and reloaded, allowing the new topology to take effect.

Implements a tool for switching between audio topologies
without the need for rebooting.

Signed-off-by: Anne Onciulescu <[email protected]>
@sofci
Copy link
Collaborator

sofci commented Sep 29, 2024

Can one of the admins verify this patch?

reply test this please to run this test once

@iuliana-prodan
Copy link
Contributor

test this please

@iuliana-prodan
Copy link
Contributor

@AnneOnciulescu can you please add a screenshot and/or a demo.
Thanks!

@@ -0,0 +1,12 @@
## Topology Switch Tool

Copy link
Collaborator

@dbaluta dbaluta Sep 30, 2024

Choose a reason for hiding this comment

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

Please add a prefix to the commit subject like tools: . Also add some implementations detail in the commit message.

Like for example: we remove and then insert back all SOF related modules thus triggering topology reload.

As a development tool I think this is super useful. On the longer term I wonder if we can have this functionality in the SOF Linux driver.

Cc: @lgirdwood @ranj063

Copy link
Collaborator

@ranj063 ranj063 Sep 30, 2024

Choose a reason for hiding this comment

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

@dbaluta @AnneOnciulescu would it make sense to update the sof-insert/sof-remove scripts in the sof-test repo to do what you're suggesting? https://github.com/thesofproject/sof-test/tree/main/tools/kmod

And as for choosing a different topology should be just a simple command to se the kernel module params to choose the new topology isnt it? Can you please elaborate the need of the python tool for choosing a different topology?

Copy link
Collaborator

@dbaluta dbaluta Oct 1, 2024

Choose a reason for hiding this comment

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

Could be yes, but then the user needs to run 3 scripts instead of selecting the topology from a GUI. On the other hand we can create a wrapper over existing sof-insert / sof-remove scripts.

Let me talk to @AnneOnciulescu and get back with a imporved solution.

The GUI offers you a list of topology to use. That is the nicest part. Lets see though if it worth the effort.

Copy link
Member

@lgirdwood lgirdwood left a comment

Choose a reason for hiding this comment

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

@AnneOnciulescu we also want to namespace all tools with a sof- prefix so that they can be eventually be deployed via a make install or a apt-get install sof-dev

@dbaluta
Copy link
Collaborator

dbaluta commented Oct 2, 2024

@lgirdwood @ranj063 will suspend this PR for a moment so that we can investigate sof_insert.sh and sof_remove.sh

@dbaluta dbaluta marked this pull request as draft October 2, 2024 16:10
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.

6 participants