Skip to content

Commit 5a0e698

Browse files
Sergei Shtylyovgeertu
authored andcommitted
pinctrl: sh-pfc: Add PORT_GP_CFG_{6|22}() helper macros
They follow the style of the existing PORT_GP_CFG_<n>() macros and will be used by a follow-up patch for the R8A77970 SoC. Based on the original (and large) patch by Daisuke Matsushita <[email protected]>. Signed-off-by: Vladimir Barinov <[email protected]> Signed-off-by: Sergei Shtylyov <[email protected]> Signed-off-by: Geert Uytterhoeven <[email protected]>
1 parent 0e1c7a9 commit 5a0e698

File tree

1 file changed

+12
-4
lines changed

1 file changed

+12
-4
lines changed

drivers/pinctrl/sh-pfc/sh_pfc.h

Lines changed: 12 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -389,10 +389,14 @@ extern const struct sh_pfc_soc_info shx3_pinmux_info;
389389
PORT_GP_CFG_1(bank, 3, fn, sfx, cfg)
390390
#define PORT_GP_4(bank, fn, sfx) PORT_GP_CFG_4(bank, fn, sfx, 0)
391391

392-
#define PORT_GP_CFG_8(bank, fn, sfx, cfg) \
392+
#define PORT_GP_CFG_6(bank, fn, sfx, cfg) \
393393
PORT_GP_CFG_4(bank, fn, sfx, cfg), \
394394
PORT_GP_CFG_1(bank, 4, fn, sfx, cfg), \
395-
PORT_GP_CFG_1(bank, 5, fn, sfx, cfg), \
395+
PORT_GP_CFG_1(bank, 5, fn, sfx, cfg)
396+
#define PORT_GP_6(bank, fn, sfx) PORT_GP_CFG_6(bank, fn, sfx, 0)
397+
398+
#define PORT_GP_CFG_8(bank, fn, sfx, cfg) \
399+
PORT_GP_CFG_6(bank, fn, sfx, cfg), \
396400
PORT_GP_CFG_1(bank, 6, fn, sfx, cfg), \
397401
PORT_GP_CFG_1(bank, 7, fn, sfx, cfg)
398402
#define PORT_GP_8(bank, fn, sfx) PORT_GP_CFG_8(bank, fn, sfx, 0)
@@ -450,9 +454,13 @@ extern const struct sh_pfc_soc_info shx3_pinmux_info;
450454
PORT_GP_CFG_1(bank, 20, fn, sfx, cfg)
451455
#define PORT_GP_21(bank, fn, sfx) PORT_GP_CFG_21(bank, fn, sfx, 0)
452456

453-
#define PORT_GP_CFG_23(bank, fn, sfx, cfg) \
457+
#define PORT_GP_CFG_22(bank, fn, sfx, cfg) \
454458
PORT_GP_CFG_21(bank, fn, sfx, cfg), \
455-
PORT_GP_CFG_1(bank, 21, fn, sfx, cfg), \
459+
PORT_GP_CFG_1(bank, 21, fn, sfx, cfg)
460+
#define PORT_GP_22(bank, fn, sfx) PORT_GP_CFG_22(bank, fn, sfx, 0)
461+
462+
#define PORT_GP_CFG_23(bank, fn, sfx, cfg) \
463+
PORT_GP_CFG_22(bank, fn, sfx, cfg), \
456464
PORT_GP_CFG_1(bank, 22, fn, sfx, cfg)
457465
#define PORT_GP_23(bank, fn, sfx) PORT_GP_CFG_23(bank, fn, sfx, 0)
458466

0 commit comments

Comments
 (0)