Re: [PATCH v1] ALSA: hda/tas2781: Update tas2781 HDA driver

From: Andy Shevchenko
Date: Mon Sep 04 2023 - 06:32:27 EST


On Mon, Sep 04, 2023 at 05:07:24PM +0800, Shenghao Ding wrote:
> Revert structure cs35l41_dev_name and redefine tas2781_generic_fixup.

...

> /* check the bus name */
> - if (strncmp(d, p->bus, n))
> + if (strncmp(d, bus, n))
> return 0;
> /* skip the bus number */
> if (isdigit(d[n]))
> n++;
> /* the rest must be exact matching */
> - snprintf(tmp, sizeof(tmp), "-%s:00", p->hid);
> + snprintf(tmp, sizeof(tmp), "-%s:00", "TIAS2781");
>
> return !strcmp(d + n, tmp);

Try to use one of the respectve acpi_*_match*() APIs.

--
With Best Regards,
Andy Shevchenko