]> git.ipfire.org Git - thirdparty/kernel/stable.git/commitdiff
pinctrl: intel: Introduce INTEL_GPP() macro
authorAndy Shevchenko <andriy.shevchenko@linux.intel.com>
Tue, 4 Nov 2025 14:56:35 +0000 (15:56 +0100)
committerAndy Shevchenko <andriy.shevchenko@linux.intel.com>
Wed, 5 Nov 2025 17:14:36 +0000 (18:14 +0100)
A new macro will be used for the further refactoring of the drivers.

Signed-off-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com>
drivers/pinctrl/intel/pinctrl-intel.h

index 4d4e1257afdf75d63575829b83251f5107b2b251..654af5977603d555c7de8d48febb3a53bcc71c19 100644 (file)
@@ -76,6 +76,15 @@ enum {
        INTEL_GPIO_BASE_MATCH   = 0,
 };
 
+/* Initialise struct intel_padgroup */
+#define INTEL_GPP(r, s, e, g)                          \
+       {                                               \
+               .reg_num = (r),                         \
+               .base = (s),                            \
+               .size = ((e) - (s) + 1),                \
+               .gpio_base = (g),                       \
+       }
+
 /**
  * struct intel_community - Intel pin community description
  * @barno: MMIO BAR number where registers for this community reside