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

2020-09-09 Thread Alex Elder
On 9/9/20 4:14 PM, David Miller wrote: From: Alex Elder 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

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

2020-09-09 Thread David Miller
From: Alex Elder 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.?

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

2020-09-09 Thread Alex Elder
On 9/8/20 10:27 PM, David Miller wrote: > From: Alex Elder > Date: Tue, 8 Sep 2020 19:21:23 -0500 > >> We take a single IPA clock reference to keep the clock running >> until we get a system suspend operation. When a system suspend >> request arrives, we drop that reference, and if that's the l

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

2020-09-08 Thread David Miller
From: Alex Elder Date: Tue, 8 Sep 2020 19:21:23 -0500 > We take a single IPA clock reference to keep the clock running > until we get a system suspend operation. When a system suspend > request arrives, we drop that reference, and if that's the last > reference (likely) we'll proceed with suspe

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

2020-09-08 Thread Alex Elder
We take a single IPA clock reference to keep the clock running until we get a system suspend operation. When a system suspend request arrives, we drop that reference, and if that's the last reference (likely) we'll proceed with suspending endpoints and disabling the IPA core clock and interconnect