[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <942b8957-03ce-4dc1-9b90-880b2d3b4c8b@web.de>
Date: Fri, 14 Jun 2024 16:38:42 +0200
From: Markus Elfring <Markus.Elfring@....de>
To: Baojun Xu <baojun.xu@...com>, alsa-devel@...a-project.org,
Takashi Iwai <tiwai@...e.de>, Shenghao Ding <shenghao-ding@...com>
Cc: LKML <linux-kernel@...r.kernel.org>,
Andy Shevchenko <andriy.shevchenko@...ux.intel.com>,
Bard Liao <yung-chuan.liao@...ux.intel.com>, Gergo Koteles <soyer@....hu>,
Jaroslav Kysela <perex@...ex.cz>, Kevin Lu <kevin-lu@...com>,
Liam Girdwood <lgirdwood@...il.com>, Mark Brown <broonie@...nel.org>,
Mukund Navada Kanyana <navada@...com>, niranjan.hy@...com,
Pierre-Louis Bossart <pierre-louis.bossart@...ux.intel.com>,
Rob Herring <robh+dt@...nel.org>, Shenghao Ding <13916275206@....com>,
v-hampiholi@...com, Vijeth P O <v-po@...com>
Subject: Re: [PATCH v8] ALSA: hda/tas2781: Add tas2781 hda SPI driver
…
> It use ACPI node descript about parameters of TAS2781 on SPI, it like:
…
> probe twice for every single SPI device. And driver will also parser
> mono DSP firmware binary and RCA binary for itself.
> The code support Realtek as the primary codec.
* Would you like to avoid typos in such a change description?
* Please improve the changelog with imperative wordings.
https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git/tree/Documentation/process/submitting-patches.rst?h=v6.10-rc3#n94
…
> +++ b/sound/pci/hda/tas2781_hda_spi.c
> @@ -0,0 +1,1266 @@
…
> +static int tas2781_hda_spi_probe(struct spi_device *spi)
> +{
…
> + ret = component_add(tas_priv->dev, &tas2781_hda_comp_ops);
> + if (ret) {
> + dev_err(tas_priv->dev, "Register component failed: %d\n", ret);
> + pm_runtime_disable(tas_priv->dev);
> + }
> +
> +err:
> + if (ret)
> + tas2781_hda_remove(&spi->dev);
> +
> + return ret;
> +}
…
How do you think about to adjust the control flow another bit for this function implementation?
…
> +++ b/sound/pci/hda/tas2781_spi_fwlib.c
> @@ -0,0 +1,2101 @@
…
> +static struct tasdevice_config_info *tasdevice_add_config(
> + struct tasdevice_priv *tas_priv, unsigned char *config_data,
> + unsigned int config_size, int *status)
> +{
…
> + return cfg_info;
> +out1:
> + for (int j = 0; j < i; j++)
> + kfree(bk_da[j]);
> + kfree(bk_da);
> +out:
> + kfree(cfg_info);
> + return NULL;
> +}
* Please improve your label selection.
https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git/tree/Documentation/process/coding-style.rst?h=v6.10-rc3#n536
* Will development interests grow according to the application of scope-based resource management
also for this function implementation?
https://elixir.bootlin.com/linux/v6.10-rc3/source/include/linux/cleanup.h#L8
Regards,
Markus
Powered by blists - more mailing lists