]> git.ipfire.org Git - thirdparty/kernel/linux.git/commit
lib/linear_ranges: Add linear_range_get_selector_high_array
authorAmit Sunil Dhamne <amitsd@google.com>
Wed, 25 Mar 2026 22:22:25 +0000 (22:22 +0000)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Mon, 30 Mar 2026 14:58:33 +0000 (16:58 +0200)
commitf23388d0f6523cc3a72edf6e78cb11931a07da10
treec148e9dfcd69f7c93578c808dcad065868f5328f
parentb422f7c072ac8d9b83c3d22e03709b92626ca88a
lib/linear_ranges: Add linear_range_get_selector_high_array

Add a helper function to find the selector for a given value in a linear
range array. The selector should be such that the value it represents
should be higher or equal to the given value.

Signed-off-by: Amit Sunil Dhamne <amitsd@google.com>
Reviewed-by: Matti Vaittinen <mazziesaccount@gmail.com>
Acked-by: Mark Brown <broonie@kernel.org>
Link: https://patch.msgid.link/20260325-max77759-charger-v9-4-4486dd297adc@google.com
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
include/linux/linear_range.h
lib/linear_ranges.c