Re: [PATCH net-next 1/5] net: ipa: use atomic exchange for suspend reference

Alex Elder
2020-09-09T21:23:35Z

On 9/9/20 4:14 PM, David Miller wrote:
> From: Alex Elder <elder@linaro.org>
> Date: Wed, 9 Sep 2020 08:43:44 -0500
>
>> There is exactly one reference here; the "reference" is
>> essentially a Boolean flag. So the value is always either
>> 0 or 1.
>
> Aha, then why not use a bitmask and test_and_set_bit() et al.?

OK I'll go take a look at that option. It's overkill for
bits used but it makes it more obvious it's a single bit,
so it's probably a better idea.

I'll try to turn this around again by tomorrow. Thank you.

-Alex