1
0
Fork 0

pinctrl: sh-pfc: Add SH_PFC_PIN_GROUP_ALIAS()

Add a macro to refer to another pin group with a different name.

This will be used to rename wrongly-named pin groups, while retaining
backwards compatibility with old DTBs.

Signed-off-by: Geert Uytterhoeven <geert+renesas@glider.be>
Reviewed-by: Niklas Söderlund <niklas.soderlund+renesas@ragnatech.se>
hifive-unleashed-5.1
Geert Uytterhoeven 2018-03-12 14:42:09 +01:00
parent 66e9fe1ec7
commit 43a51cd5d6
1 changed files with 3 additions and 2 deletions

View File

@ -39,13 +39,14 @@ struct sh_pfc_pin {
unsigned int configs;
};
#define SH_PFC_PIN_GROUP(n) \
#define SH_PFC_PIN_GROUP_ALIAS(alias, n) \
{ \
.name = #n, \
.name = #alias, \
.pins = n##_pins, \
.mux = n##_mux, \
.nr_pins = ARRAY_SIZE(n##_pins), \
}
#define SH_PFC_PIN_GROUP(n) SH_PFC_PIN_GROUP_ALIAS(n, n)
struct sh_pfc_pin_group {
const char *name;