pinctrl: icelake: Replace ICL_COMMUNITY() by INTEL_COMMUNITY_GPPS()
authorAndy Shevchenko <andriy.shevchenko@linux.intel.com>
Mon, 19 Dec 2022 12:26:36 +0000 (14:26 +0200)
committerAndy Shevchenko <andriy.shevchenko@linux.intel.com>
Tue, 27 Dec 2022 19:17:54 +0000 (21:17 +0200)
Use INTEL_COMMUNITY_GPPS() common macro instead custom ICL_COMMUNITY().

Signed-off-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com>
Acked-by: Mika Westerberg <mika.westerberg@linux.intel.com>
drivers/pinctrl/intel/pinctrl-icelake.c

index 84a56d9..1c64b4a 100644 (file)
 
 #include "pinctrl-intel.h"
 
-#define ICL_PAD_OWN    0x020
-#define ICL_PADCFGLOCK 0x080
-#define ICL_HOSTSW_OWN 0x0b0
-#define ICL_GPI_IS     0x100
-#define ICL_LP_GPI_IE  0x110
-#define ICL_N_GPI_IE   0x120
+#define ICL_LP_PAD_OWN         0x020
+#define ICL_LP_PADCFGLOCK      0x080
+#define ICL_LP_HOSTSW_OWN      0x0b0
+#define ICL_LP_GPI_IS          0x100
+#define ICL_LP_GPI_IE          0x110
+
+#define ICL_N_PAD_OWN          0x020
+#define ICL_N_PADCFGLOCK       0x080
+#define ICL_N_HOSTSW_OWN       0x0b0
+#define ICL_N_GPI_IS           0x100
+#define ICL_N_GPI_IE           0x120
 
 #define ICL_GPP(r, s, e, g)                            \
        {                                               \
                .gpio_base = (g),                       \
        }
 
-#define ICL_COMMUNITY(b, s, e, g, v)                   \
-       {                                               \
-               .barno = (b),                           \
-               .padown_offset = ICL_PAD_OWN,           \
-               .padcfglock_offset = ICL_PADCFGLOCK,    \
-               .hostown_offset = ICL_HOSTSW_OWN,       \
-               .is_offset = ICL_GPI_IS,                \
-               .ie_offset = ICL_##v##_GPI_IE,          \
-               .pin_base = (s),                        \
-               .npins = ((e) - (s) + 1),               \
-               .gpps = (g),                            \
-               .ngpps = ARRAY_SIZE(g),                 \
-       }
-
 #define ICL_LP_COMMUNITY(b, s, e, g)                   \
-       ICL_COMMUNITY(b, s, e, g, LP)
+       INTEL_COMMUNITY_GPPS(b, s, e, g, ICL_LP)
 
 #define ICL_N_COMMUNITY(b, s, e, g)                    \
-       ICL_COMMUNITY(b, s, e, g, N)
+       INTEL_COMMUNITY_GPPS(b, s, e, g, ICL_N)
 
 /* Ice Lake-LP */
 static const struct pinctrl_pin_desc icllp_pins[] = {