alsa-devel.alsa-project.org archive mirror
 help / color / mirror / Atom feed
* [PATCH v1 0/2] ALSA: cs35l41: prevent old firmwares using unsupported commands
@ 2023-09-22 14:28 Stefan Binding
  2023-09-22 14:28 ` [PATCH v1 1/2] ALSA: hda: cs35l41: Remove unnecessary boolean state variable firmware_running Stefan Binding
                   ` (2 more replies)
  0 siblings, 3 replies; 10+ messages in thread
From: Stefan Binding @ 2023-09-22 14:28 UTC (permalink / raw)
  To: Mark Brown, Jaroslav Kysela, Takashi Iwai
  Cc: alsa-devel, linux-kernel, patches, Stefan Binding

Some systems use older firmware which does not support newer commands
which are used to enable external boost. For those systems, we can
workaround this by writing the registers directly.

We can use the firmware version, stored inside cs_dsp, to determine
whether or not the command is supported.
To achieve this, it requires a cleanup in the api, to pass the cs_dsp
struct into the function.

We can also remove the redundant boolean firmware_running from the HDA
driver, and use the equivalent state inside cs_dsp.

This chain is based on Mark's branch, since the api change was made to
the function in sound/soc/codecs/cs35l41-lib.c.

Stefan Binding (2):
  ALSA: hda: cs35l41: Remove unnecessary boolean state variable
    firmware_running
  ALSA: cs35l41: Fix for old systems which do not support command

 include/sound/cs35l41.h        |  2 +-
 sound/pci/hda/cs35l41_hda.c    | 28 ++++++++++++----------------
 sound/pci/hda/cs35l41_hda.h    |  1 -
 sound/soc/codecs/cs35l41-lib.c |  6 ++++--
 sound/soc/codecs/cs35l41.c     |  4 ++--
 5 files changed, 19 insertions(+), 22 deletions(-)

-- 
2.34.1


^ permalink raw reply	[flat|nested] 10+ messages in thread

end of thread, other threads:[~2023-09-22 14:55 UTC | newest]

Thread overview: 10+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2023-09-22 14:28 [PATCH v1 0/2] ALSA: cs35l41: prevent old firmwares using unsupported commands Stefan Binding
2023-09-22 14:28 ` [PATCH v1 1/2] ALSA: hda: cs35l41: Remove unnecessary boolean state variable firmware_running Stefan Binding
2023-09-22 14:28 ` [PATCH v1 2/2] ALSA: cs35l41: Fix for old systems which do not support command Stefan Binding
2023-09-22 14:30   ` Mark Brown
2023-09-22 14:35 ` [PATCH v1 0/2] ALSA: cs35l41: prevent old firmwares using unsupported commands Takashi Iwai
2023-09-22 14:38   ` Mark Brown
2023-09-22 14:42     ` Takashi Iwai
2023-09-22 14:44   ` Stefan Binding
2023-09-22 14:48     ` Mark Brown
2023-09-22 14:53       ` Takashi Iwai

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).