[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Message-ID: <728a26f7-a396-41a2-8d1f-7fa39c8f10b3@kernel.org>
Date: Tue, 11 Feb 2025 18:40:18 +0100
From: Jiri Slaby <jirislaby@...nel.org>
To: Stuart <stuart.a.hayhurst@...il.com>
Cc: linux-input@...r.kernel.org, Jiri Kosina <jikos@...nel.org>,
Benjamin Tissoires <bentiss@...nel.org>,
Christophe JAILLET <christophe.jaillet@...adoo.fr>,
linux-kernel@...r.kernel.org
Subject: Re: [PATCH v5] HID: corsair-void: Add Corsair Void headset family
driver
On 11. 02. 25, 13:44, Stuart wrote:
>> E.g. set_bit() (one bit per OP) to something like 'unsigned long flags'
>> in 'struct corsair_void_drvdata'. But it depends if you want to preserve
>> order of actions... (Which was not guaranteed with separate queues
>> anyway, so I assume not?)
>
> Wouldn't using one variable for the flags risk overwriting each other, unless
> it was atomic? I might be misunderstanding, I haven't played with the kernel's
> work much.
set/clear/test/test_and_clear/..._bit() are guaranteed to be atomic.
--
js
suse labs
Powered by blists - more mailing lists