[PATCH 0/2] pinctrl: Use FIELD_MODIFY() to simplify bit manipulation

Hans Zhang posted 2 patches 1 month, 2 weeks ago
drivers/pinctrl/sophgo/pinctrl-cv18xx.c | 18 ++++++------------
drivers/pinctrl/spacemit/pinctrl-k1.c   |  3 +--
2 files changed, 7 insertions(+), 14 deletions(-)
[PATCH 0/2] pinctrl: Use FIELD_MODIFY() to simplify bit manipulation
Posted by Hans Zhang 1 month, 2 weeks ago
This series replaces open-coded bitfield clear-and-set sequences with the
FIELD_MODIFY() macro in two pinctrl drivers. No functional change is
intended. The resulting code is shorter and easier to read, and it avoids
potential mistakes when adjusting bitmask definitions in the future.

---
Hi, If the Maintainers think it's not necessary, please ignore it.
---

Hans Zhang (2):
  pinctrl: sophgo: Use FIELD_MODIFY()
  pinctrl: spacemit: Use FIELD_MODIFY()

 drivers/pinctrl/sophgo/pinctrl-cv18xx.c | 18 ++++++------------
 drivers/pinctrl/spacemit/pinctrl-k1.c   |  3 +--
 2 files changed, 7 insertions(+), 14 deletions(-)


base-commit: 3b3bea6d4b9c162f9e555905d96b8c1da67ecd5b
-- 
2.34.1
Re: [PATCH 0/2] pinctrl: Use FIELD_MODIFY() to simplify bit manipulation
Posted by Linus Walleij 3 weeks, 3 days ago
On Thu, Apr 30, 2026 at 7:01 PM Hans Zhang <18255117159@163.com> wrote:

> This series replaces open-coded bitfield clear-and-set sequences with the
> FIELD_MODIFY() macro in two pinctrl drivers. No functional change is
> intended. The resulting code is shorter and easier to read, and it avoids
> potential mistakes when adjusting bitmask definitions in the future.
>
> ---
> Hi, If the Maintainers think it's not necessary, please ignore it.

Maintainers said nothing so patches applied!

Sorry for stalling so long.

Yours,
Linus Walleij