Re: [RFC PATCH] ALSA: pci: add PreSonus Quantum PCI driver

Markus Elfring <[email protected]>
Newsgroups org.kernel.vger.linux-doc,org.kernel.vger.linux-kernel,org.kernel.vger.linux-sound
Message-ID <[email protected]>
…
> +++ b/sound/pci/quantum/quantum_dma.c
> @@ -0,0 +1,853 @@
…
> +static ssize_t cpu_latency_us_store(struct device *dev,
> +				    struct device_attribute *attr,
> +				    const char *buf, size_t count)
> +{
…
> +	mutex_lock(&chip->dma_mutex);
> +	chip->cpu_latency_us = value;
> +	if (READ_ONCE(chip->stream_active))
> +		quantum_cpu_latency_qos_apply(chip);
> +	mutex_unlock(&chip->dma_mutex);
> +
> +	return count;
> +}
…

Under which circumstances would you become interested to apply a statement
like “guard(mutex)(&chip->dma_mutex);”?
https://elixir.bootlin.com/linux/v7.2/source/include/linux/mutex.h#L253

Regards,
Markus
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.