public inbox for linux-kernel@vger.kernel.org
 help / color / mirror / Atom feed
* [PATCH 00/16] ALSA: hda/tas2781: Add tas2563 support
@ 2023-12-06 23:59 Gergo Koteles
  0 siblings, 0 replies; 4+ messages in thread
From: Gergo Koteles @ 2023-12-06 23:59 UTC (permalink / raw)
  To: Shenghao Ding, Kevin Lu, Baojun Xu, Jaroslav Kysela, Takashi Iwai,
	Liam Girdwood, Mark Brown
  Cc: linux-kernel, alsa-devel, Gergo Koteles

The tas2781-hda driver can be modified to support tas2563 as well.
Before knowing this information, I created another series for a
new driver.
https://lore.kernel.org/lkml/cover.1701733441.git.soyer@irl.hu/

This series now extends tas2781-hda, addresses differences and
fixes various bugs.

The tas2563 is a smart amplifier. Similar to tas2562 but with DSP. Some
Lenovo laptops have it to drive the bass speakers. By default, it is in
software shutdown state.

To make the DSP work it needs a firmware and some calibration data.
The latter can be read from the EFI in Lenovo laptops.

For the correct configuration it needs additional register data.
It captured after running the Windows driver.

The firmware can be extracted as TAS2563Firmware.bin from the Windows
driver with innoextract.
https://download.lenovo.com/consumer/mobiles/h5yd037fbfyy7kd0.exe

The driver will search for it as TAS2XXX3870.bin with the 14ARB7.
The captured registers extracted with TI's regtool:
https://github.com/soyersoyer/tas2563rca/raw/main/INT8866RCA2.bin


Gergo Koteles (16):
  ASoC: tas2781: add support for fw version 0x0503
  ALSA: hda/tas2781: leave hda_component in usable state
  ASoC: tas2781: disable regmap regcache
  ALSA: hda/tas2781: handle missing calibration data
  ALSA: hda/tas2781: fix typos in comment
  ASoC: tas2781: add ptrs to calibration functions
  ALSA: hda/tas2781: load_calibration just load
  ASoC: tas2781: add configurable global_addr
  ALSA: hda/tas2781: add TAS2563 support for 14ARB7
  ASoC: tas2781: check negative indexes
  ASoC: tas2781: use 0 as default prog/conf index
  ASoC: tas2781: move set_drv_data outside tasdevice_init
  ALSA: hda/tas2781: remove sound controls in unbind
  ALSA: hda/tas2781: call cleaner functions only once
  ALSA: hda/tas2781: reset the amp before component_add
  ALSA: hda/tas2781: configure the amp after firmware load

 include/sound/tas2781.h           |   8 +
 sound/pci/hda/tas2781_hda_i2c.c   | 364 +++++++++++++++++++-----------
 sound/soc/codecs/tas2781-comlib.c |  23 +-
 sound/soc/codecs/tas2781-fmwlib.c |  11 +-
 sound/soc/codecs/tas2781-i2c.c    |   2 +
 5 files changed, 270 insertions(+), 138 deletions(-)


base-commit: ffc253263a1375a65fa6c9f62a893e9767fbebfa
-- 
2.43.0


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

* [PATCH 00/16] ALSA: hda/tas2781: Add tas2563 support
@ 2023-12-07  0:58 Gergo Koteles
  2023-12-07 13:55 ` Mark Brown
  0 siblings, 1 reply; 4+ messages in thread
From: Gergo Koteles @ 2023-12-07  0:58 UTC (permalink / raw)
  To: Shenghao Ding, Kevin Lu, Baojun Xu, Jaroslav Kysela, Takashi Iwai,
	Liam Girdwood, Mark Brown
  Cc: linux-kernel, alsa-devel, Gergo Koteles

The tas2781-hda driver can be modified to support tas2563 as well.
Before knowing this information, I created another series for a
new driver.
https://lore.kernel.org/lkml/cover.1701733441.git.soyer@irl.hu/

This series now extends tas2781-hda, addresses differences and
fixes various bugs.

The tas2563 is a smart amplifier. Similar to tas2562 but with DSP. Some
Lenovo laptops have it to drive the bass speakers. By default, it is in
software shutdown state.

To make the DSP work it needs a firmware and some calibration data.
The latter can be read from the EFI in Lenovo laptops.

For the correct configuration it needs additional register data.
It captured after running the Windows driver.

The firmware can be extracted as TAS2563Firmware.bin from the Windows
driver with innoextract.
https://download.lenovo.com/consumer/mobiles/h5yd037fbfyy7kd0.exe

The driver will search for it as TAS2XXX3870.bin with the 14ARB7.
The captured registers extracted with TI's regtool:
https://github.com/soyersoyer/tas2563rca/raw/main/INT8866RCA2.bin


Gergo Koteles (16):
  ASoC: tas2781: add support for fw version 0x0503
  ALSA: hda/tas2781: leave hda_component in usable state
  ASoC: tas2781: disable regmap regcache
  ALSA: hda/tas2781: handle missing calibration data
  ALSA: hda/tas2781: fix typos in comment
  ASoC: tas2781: add ptrs to calibration functions
  ALSA: hda/tas2781: load_calibration just load
  ASoC: tas2781: add configurable global_addr
  ALSA: hda/tas2781: add TAS2563 support for 14ARB7
  ASoC: tas2781: check negative indexes
  ASoC: tas2781: use 0 as default prog/conf index
  ASoC: tas2781: move set_drv_data outside tasdevice_init
  ALSA: hda/tas2781: remove sound controls in unbind
  ALSA: hda/tas2781: call cleaner functions only once
  ALSA: hda/tas2781: reset the amp before component_add
  ALSA: hda/tas2781: configure the amp after firmware load

 include/sound/tas2781.h           |   8 +
 sound/pci/hda/tas2781_hda_i2c.c   | 364 +++++++++++++++++++-----------
 sound/soc/codecs/tas2781-comlib.c |  23 +-
 sound/soc/codecs/tas2781-fmwlib.c |  11 +-
 sound/soc/codecs/tas2781-i2c.c    |   2 +
 5 files changed, 270 insertions(+), 138 deletions(-)


base-commit: ffc253263a1375a65fa6c9f62a893e9767fbebfa
-- 
2.43.0


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

* Re: [PATCH 00/16] ALSA: hda/tas2781: Add tas2563 support
  2023-12-07  0:58 Gergo Koteles
@ 2023-12-07 13:55 ` Mark Brown
  2023-12-07 14:38   ` Takashi Iwai
  0 siblings, 1 reply; 4+ messages in thread
From: Mark Brown @ 2023-12-07 13:55 UTC (permalink / raw)
  To: Gergo Koteles
  Cc: Shenghao Ding, Kevin Lu, Baojun Xu, Jaroslav Kysela, Takashi Iwai,
	Liam Girdwood, linux-kernel, alsa-devel

[-- Attachment #1: Type: text/plain, Size: 1064 bytes --]

On Thu, Dec 07, 2023 at 01:58:22AM +0100, Gergo Koteles wrote:

> Gergo Koteles (16):
>   ASoC: tas2781: add support for fw version 0x0503
>   ALSA: hda/tas2781: leave hda_component in usable state
>   ASoC: tas2781: disable regmap regcache
>   ALSA: hda/tas2781: handle missing calibration data
>   ALSA: hda/tas2781: fix typos in comment
>   ASoC: tas2781: add ptrs to calibration functions
>   ALSA: hda/tas2781: load_calibration just load
>   ASoC: tas2781: add configurable global_addr
>   ALSA: hda/tas2781: add TAS2563 support for 14ARB7
>   ASoC: tas2781: check negative indexes
>   ASoC: tas2781: use 0 as default prog/conf index
>   ASoC: tas2781: move set_drv_data outside tasdevice_init
>   ALSA: hda/tas2781: remove sound controls in unbind
>   ALSA: hda/tas2781: call cleaner functions only once
>   ALSA: hda/tas2781: reset the amp before component_add
>   ALSA: hda/tas2781: configure the amp after firmware load

Please don't randomly interleave ASoC and ALSA patches like this without
some strong need, it just makes everything harder to manage.

[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 488 bytes --]

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

* Re: [PATCH 00/16] ALSA: hda/tas2781: Add tas2563 support
  2023-12-07 13:55 ` Mark Brown
@ 2023-12-07 14:38   ` Takashi Iwai
  0 siblings, 0 replies; 4+ messages in thread
From: Takashi Iwai @ 2023-12-07 14:38 UTC (permalink / raw)
  To: Mark Brown
  Cc: Gergo Koteles, Shenghao Ding, Kevin Lu, Baojun Xu,
	Jaroslav Kysela, Takashi Iwai, Liam Girdwood, linux-kernel,
	alsa-devel

On Thu, 07 Dec 2023 14:55:25 +0100,
Mark Brown wrote:
> 
> On Thu, Dec 07, 2023 at 01:58:22AM +0100, Gergo Koteles wrote:
> 
> > Gergo Koteles (16):
> >   ASoC: tas2781: add support for fw version 0x0503
> >   ALSA: hda/tas2781: leave hda_component in usable state
> >   ASoC: tas2781: disable regmap regcache
> >   ALSA: hda/tas2781: handle missing calibration data
> >   ALSA: hda/tas2781: fix typos in comment
> >   ASoC: tas2781: add ptrs to calibration functions
> >   ALSA: hda/tas2781: load_calibration just load
> >   ASoC: tas2781: add configurable global_addr
> >   ALSA: hda/tas2781: add TAS2563 support for 14ARB7
> >   ASoC: tas2781: check negative indexes
> >   ASoC: tas2781: use 0 as default prog/conf index
> >   ASoC: tas2781: move set_drv_data outside tasdevice_init
> >   ALSA: hda/tas2781: remove sound controls in unbind
> >   ALSA: hda/tas2781: call cleaner functions only once
> >   ALSA: hda/tas2781: reset the amp before component_add
> >   ALSA: hda/tas2781: configure the amp after firmware load
> 
> Please don't randomly interleave ASoC and ALSA patches like this without
> some strong need, it just makes everything harder to manage.

And, some look really like rather individual fixes; they deserve for
Fixes tag and Cc-to-stable, at least.


thanks,

Takashi

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

end of thread, other threads:[~2023-12-07 14:38 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2023-12-06 23:59 [PATCH 00/16] ALSA: hda/tas2781: Add tas2563 support Gergo Koteles
  -- strict thread matches above, loose matches on Subject: below --
2023-12-07  0:58 Gergo Koteles
2023-12-07 13:55 ` Mark Brown
2023-12-07 14:38   ` Takashi Iwai

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox