mbox series

[v2,0/2] gpiolib: Make code more robust by using for_each_if()

Message ID 20250213182527.3092371-1-andriy.shevchenko@linux.intel.com
Headers show
Series gpiolib: Make code more robust by using for_each_if() | expand

Message

Andy Shevchenko Feb. 13, 2025, 6:23 p.m. UTC
Instead of opencoding with long lines, use for_each_if() macro
which makes intention clearer and less error prone.

In v2:
- moved original for_each_if() implementation to the global header (Bart)

Andy Shevchenko (2):
  drm: Move for_each_if() to util_macros.h for wider use
  gpiolib: Switch to use for_each_if() helper

 include/drm/drm_util.h      | 16 +---------------
 include/linux/gpio/driver.h |  7 ++++---
 include/linux/util_macros.h | 15 +++++++++++++++
 3 files changed, 20 insertions(+), 18 deletions(-)

Comments

Bartosz Golaszewski Feb. 17, 2025, 9:14 a.m. UTC | #1
From: Bartosz Golaszewski <bartosz.golaszewski@linaro.org>


On Thu, 13 Feb 2025 20:23:59 +0200, Andy Shevchenko wrote:
> Instead of opencoding with long lines, use for_each_if() macro
> which makes intention clearer and less error prone.
> 
> In v2:
> - moved original for_each_if() implementation to the global header (Bart)
> 
> Andy Shevchenko (2):
>   drm: Move for_each_if() to util_macros.h for wider use
>   gpiolib: Switch to use for_each_if() helper
> 
> [...]

Applied, thanks!

[1/2] drm: Move for_each_if() to util_macros.h for wider use
      commit: b82e90c6f987e8f930523313eb803209cf9c6c97
[2/2] gpiolib: Switch to use for_each_if() helper
      commit: c60fa3ba030a4d95b55fcca8945dacac89c542a6

Best regards,