]> git.baikalelectronics.ru Git - kernel.git/commit
net: ipa: replace ipa->suspend_ref with a flag bit
authorAlex Elder <elder@linaro.org>
Thu, 17 Sep 2020 17:39:21 +0000 (12:39 -0500)
committerDavid S. Miller <davem@davemloft.net>
Sat, 19 Sep 2020 00:47:07 +0000 (17:47 -0700)
commit2b80c30c1eabd52375ed05e735b20deba8b70aab
tree75b48478ea5f59fdcc3a9ee3abd48ff5f787ad39
parent5fe49ec537a79f1ea3364ffc9b1dc7eed1042a64
net: ipa: replace ipa->suspend_ref with a flag bit

We take a clock reference in ipa_config() in order to prevent the
the IPA clock from being shutdown until a power management suspend
request arrives.  An atomic field in the IPA structure records
whether that extra reference had been taken.

Rather than using an atomic to represent a Boolean value, define
a new flags bitmap, and define a "clock held" flag to represent
whether the extra clock reference has been taken.

Signed-off-by: Alex Elder <elder@linaro.org>
Signed-off-by: David S. Miller <davem@davemloft.net>
drivers/net/ipa/ipa.h
drivers/net/ipa/ipa_main.c