diff options
author | Yury Norov <yury.norov@gmail.com> | 2021-08-14 23:17:11 +0200 |
---|---|---|
committer | Yury Norov <yury.norov@gmail.com> | 2022-01-15 17:47:31 +0100 |
commit | ec288a2cf7ca40a939316b6df206ab845bb112d1 (patch) | |
tree | 8f9805242155d8f5decc0e4a06ea3397c13db835 /drivers | |
parent | mm/percpu: micro-optimize pcpu_is_populated() (diff) | |
download | linux-ec288a2cf7ca40a939316b6df206ab845bb112d1.tar.xz linux-ec288a2cf7ca40a939316b6df206ab845bb112d1.zip |
bitmap: unify find_bit operations
bitmap_for_each_{set,clear}_region() are similar to for_each_bit()
macros in include/linux/find.h, but interface and implementation
of them are different.
This patch adds for_each_bitrange() macros and drops unused
bitmap_*_region() API in sake of unification.
Signed-off-by: Yury Norov <yury.norov@gmail.com>
Tested-by: Wolfram Sang <wsa+renesas@sang-engineering.com>
Acked-by: Dennis Zhou <dennis@kernel.org>
Acked-by: Ulf Hansson <ulf.hansson@linaro.org> # For MMC
Diffstat (limited to 'drivers')
-rw-r--r-- | drivers/mmc/host/renesas_sdhi_core.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/mmc/host/renesas_sdhi_core.c b/drivers/mmc/host/renesas_sdhi_core.c index f5b2684ad805..6de30a2719a3 100644 --- a/drivers/mmc/host/renesas_sdhi_core.c +++ b/drivers/mmc/host/renesas_sdhi_core.c @@ -628,7 +628,7 @@ static int renesas_sdhi_select_tuning(struct tmio_mmc_host *host) * is at least SH_MOBILE_SDHI_MIN_TAP_ROW probes long then use the * center index as the tap, otherwise bail out. */ - bitmap_for_each_set_region(bitmap, rs, re, 0, taps_size) { + for_each_set_bitrange(rs, re, bitmap, taps_size) { if (re - rs > tap_cnt) { tap_end = re; tap_start = rs; |