ACPI: platform_profile: Optimize _aggregate_choices()
authorKurt Borja <kuurtb@gmail.com>
Tue, 25 Mar 2025 20:39:53 +0000 (17:39 -0300)
committerRafael J. Wysocki <rafael.j.wysocki@intel.com>
Thu, 27 Mar 2025 19:44:29 +0000 (20:44 +0100)
commit3035a6dd2d4736738949600b8abebbdb181e86ef
tree10d1e3c4d22311c59b372dedbce24d1fa06158bc
parent21e0ff5b10ec1b61fda435d42db4ba80d0cdfded
ACPI: platform_profile: Optimize _aggregate_choices()

Choices aggregates passed to _aggregate_choices() are already filled
with ones, therefore we can avoid copying a new bitmap on the first
iteration.

This makes setting the PLATFORM_PROFILE_LAST bit on aggregates
unnecessary, so drop it as well.

While at it, add a couple empty lines to improve style.

Reviewed-by: Armin Wolf <W_Armin@gmx.de>
Reviewed-by: Mario Limonciello <mario.limonciello@amd.com>
Signed-off-by: Kurt Borja <kuurtb@gmail.com>
Link: https://patch.msgid.link/20250325-pprof-opt-v2-1-736291e6e66b@gmail.com
Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com>
drivers/acpi/platform_profile.c