Re: [PATCH v8] ALSA: hda/tas2781: Add tas2781 hda SPI driver

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



…
> 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




[Index of Archives]     [ALSA User]     [Linux Audio Users]     [Pulse Audio]     [Kernel Archive]     [Asterisk PBX]     [Photo Sharing]     [Linux Sound]     [Video 4 Linux]     [Gimp]     [Yosemite News]

  Powered by Linux