]> git.baikalelectronics.ru Git - kernel.git/commit
Merge series "regmap: provide simple bitops and use them in a driver" from Bartosz...
authorMark Brown <broonie@kernel.org>
Fri, 29 May 2020 13:00:44 +0000 (14:00 +0100)
committerMark Brown <broonie@kernel.org>
Fri, 29 May 2020 13:00:44 +0000 (14:00 +0100)
commitbac97f083d6e0ef7a8bea2cef9ea8102caa02dd2
tree9dad597bad82db028a62c35df3938056619c7b6a
parente5e7bf68592076b4950f28207bc2451e64b90088
parentf624c76750d8f1be8486c3224d2b7696ec9117ff
Merge series "regmap: provide simple bitops and use them in a driver" from Bartosz Golaszewski <brgl@bgdev.pl>
Bartosz Golaszewski <bgolaszewski@baylibre.com>:

From: Bartosz Golaszewski <bgolaszewski@baylibre.com>

I noticed that oftentimes I use regmap_update_bits() for simple bit
setting or clearing. In this case the fourth argument is superfluous as
it's always 0 or equal to the mask argument.

This series proposes to add simple bit operations for setting, clearing
and testing specific bits with regmap.

The second patch uses all three in a driver that got recently picked into
the net-next tree.

The patches obviously target different trees so - if you're ok with
the change itself - I propose you pick the first one into your regmap
tree for v5.8 and then I'll resend the second patch to add the first
user for these macros for v5.9.

v1 -> v2:
- convert the new macros to static inline functions

v2 -> v3:
- drop unneeded ternary operator

Bartosz Golaszewski (2):
  regmap: provide helpers for simple bit operations
  net: ethernet: mtk-star-emac: use regmap bitops

 drivers/base/regmap/regmap.c                  | 22 +++++
 drivers/net/ethernet/mediatek/mtk_star_emac.c | 80 ++++++++-----------
 include/linux/regmap.h                        | 36 +++++++++
 3 files changed, 93 insertions(+), 45 deletions(-)

base-commit: 9b8057e7f937f20763a90a8fc2333168af101732

--
2.26.1

_______________________________________________
linux-arm-kernel mailing list
linux-arm-kernel@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/linux-arm-kernel
drivers/base/regmap/regmap.c
include/linux/regmap.h