File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -1345,7 +1345,16 @@ static int intel_gpio_irq_init_hw(struct gpio_chip *gc)
13451345 return 0 ;
13461346}
13471347
1348- static int intel_gpio_add_pin_ranges (struct gpio_chip * gc )
1348+ /**
1349+ * intel_gpio_add_pin_ranges - add GPIO pin ranges for all groups in all communities
1350+ * @gc: GPIO chip structure
1351+ *
1352+ * This function iterates over all communities and all groups and adds the respective
1353+ * GPIO pin ranges, so the GPIO library will correctly map a GPIO offset to a pin number.
1354+ *
1355+ * Return: 0, or negative error code if range can't be added.
1356+ */
1357+ int intel_gpio_add_pin_ranges (struct gpio_chip * gc )
13491358{
13501359 struct intel_pinctrl * pctrl = gpiochip_get_data (gc );
13511360 const struct intel_community * community ;
@@ -1362,6 +1371,7 @@ static int intel_gpio_add_pin_ranges(struct gpio_chip *gc)
13621371
13631372 return 0 ;
13641373}
1374+ EXPORT_SYMBOL_NS_GPL (intel_gpio_add_pin_ranges , "PINCTRL_INTEL" );
13651375
13661376static unsigned int intel_gpio_ngpio (const struct intel_pinctrl * pctrl )
13671377{
Original file line number Diff line number Diff line change @@ -276,6 +276,8 @@ extern const struct dev_pm_ops intel_pinctrl_pm_ops;
276276const struct intel_community * intel_get_community (const struct intel_pinctrl * pctrl ,
277277 unsigned int pin );
278278
279+ int intel_gpio_add_pin_ranges (struct gpio_chip * gc );
280+
279281int intel_get_groups_count (struct pinctrl_dev * pctldev );
280282const char * intel_get_group_name (struct pinctrl_dev * pctldev , unsigned int group );
281283int intel_get_group_pins (struct pinctrl_dev * pctldev , unsigned int group ,
You can’t perform that action at this time.
0 commit comments