linux-brain/drivers/opp
Walter Lozano 4d8d6f71b6 opp: Increase parsed_static_opps in _of_add_opp_table_v1()
[ Upstream commit 6544abc520f0fff701e9da382110dc29676c683a ]

Currently, when using _of_add_opp_table_v2 parsed_static_opps is
increased and this value is used in _opp_remove_all_static() to
check if there are static opp entries that need to be freed.
Unfortunately this does not happen when using _of_add_opp_table_v1(),
which leads to warnings.

This patch increases parsed_static_opps in _of_add_opp_table_v1() in a
similar way as in _of_add_opp_table_v2().

Fixes: 03758d60265c ("opp: Replace list_kref with a local counter")
Cc: v5.6+ <stable@vger.kernel.org> # v5.6+
Signed-off-by: Walter Lozano <walter.lozano@collabora.com>
[ Viresh: Do the operation with lock held and set the value to 1 instead
	  of incrementing it ]
Signed-off-by: Viresh Kumar <viresh.kumar@linaro.org>
Signed-off-by: Sasha Levin <sashal@kernel.org>
2020-10-01 13:18:11 +02:00
..
Kconfig pci-v5.3-changes 2019-07-15 20:44:49 -07:00
Makefile treewide: Add SPDX license identifier - Makefile/Kconfig 2019-05-21 10:50:46 +02:00
core.c opp: Replace list_kref with a local counter 2020-10-01 13:17:26 +02:00
cpu.c treewide: Replace GPLv2 boilerplate/reference with SPDX - rule 500 2019-06-19 17:09:55 +02:00
debugfs.c treewide: Replace GPLv2 boilerplate/reference with SPDX - rule 500 2019-06-19 17:09:55 +02:00
of.c opp: Increase parsed_static_opps in _of_add_opp_table_v1() 2020-10-01 13:18:11 +02:00
opp.h opp: Replace list_kref with a local counter 2020-10-01 13:17:26 +02:00
ti-opp-supply.c opp: ti-opp-supply: Fix platform_no_drv_owner.cocci warnings 2018-11-22 11:46:02 +05:30