Re: [PATCH V7 02/16] rv: Add runtime reactors interface

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

 



On Mon, 25 Jul 2022 22:11:14 +0200
Daniel Bristot de Oliveira <bristot@xxxxxxxxxx> wrote:

> +/**
> + * reactor_cleanup_monitor - cleanup a monitor reference
> + * @mdef:       monitor's definition.
> + */
> +void reactor_cleanup_monitor(struct rv_monitor_def *mdef)
> +{
> +	mdef->rdef->counter--;
> +}
> +

Doesn't this require a lock? Also you might want to add a WARN_ONCE() if it
goes below zero.

-- Steve



[Index of Archives]     [Linux USB Development]     [Linux USB Development]     [Linux Audio Users]     [Yosemite Hiking]     [Linux Kernel]     [Linux SCSI]

  Powered by Linux