diff options
Diffstat (limited to 'drivers')
-rw-r--r-- | drivers/pinctrl/sh-pfc/sh_pfc.h | 15 |
1 files changed, 8 insertions, 7 deletions
diff --git a/drivers/pinctrl/sh-pfc/sh_pfc.h b/drivers/pinctrl/sh-pfc/sh_pfc.h index 1fc13366869a..4ef485cfe08d 100644 --- a/drivers/pinctrl/sh-pfc/sh_pfc.h +++ b/drivers/pinctrl/sh-pfc/sh_pfc.h @@ -55,14 +55,15 @@ struct sh_pfc_pin_group { /* * Using union vin_data{,12,16} saves memory occupied by the VIN data pins. * VIN_DATA_PIN_GROUP() is a macro used to describe the VIN pin groups - * in this case. + * in this case. It accepts an optional 'version' argument used when the + * same group can appear on a different set of pins. */ -#define VIN_DATA_PIN_GROUP(n, s) \ - { \ - .name = #n#s, \ - .pins = n##_pins.data##s, \ - .mux = n##_mux.data##s, \ - .nr_pins = ARRAY_SIZE(n##_pins.data##s), \ +#define VIN_DATA_PIN_GROUP(n, s, ...) \ + { \ + .name = #n#s#__VA_ARGS__, \ + .pins = n##__VA_ARGS__##_pins.data##s, \ + .mux = n##__VA_ARGS__##_mux.data##s, \ + .nr_pins = ARRAY_SIZE(n##__VA_ARGS__##_pins.data##s), \ } union vin_data12 { |