Re: [PATCH V3 2/2] Add support for Awinic proximity sensor

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

 



Please add a subsystem specification to the message subject.


…
> +++ b/drivers/iio/proximity/aw_sar.c
> @@ -0,0 +1,1850 @@
…
> +static ssize_t
> +update_reg_store(struct device *dev, struct device_attribute *attr, const char *buf, size_t count)
> +{
…
> +	if (flag == AW_TRUE) {
> +		mutex_lock(&aw_sar_lock);
> +		aw_sar_soft_reset(p_sar);
> +		aw_sar_update_reg_set_func(p_sar);
> +		mutex_unlock(&aw_sar_lock);
> +	}
> +
> +	return count;
> +}
…

Under which circumstances would you become interested to apply a statement
like “guard(mutex)(&aw_sar_lock);”?
https://elixir.bootlin.com/linux/v6.10-rc7/source/include/linux/mutex.h#L196

Regards,
Markus





[Index of Archives]     [Linux USB Devel]     [Video for Linux]     [Linux Audio Users]     [Yosemite News]     [Linux Input]     [Linux Kernel]     [Linux SCSI]     [X.org]

  Powered by Linux