From acac8ed5e2aa2c0d364d06f364fd9ed0dc27d28a Mon Sep 17 00:00:00 2001 From: Laurent Pinchart Date: Mon, 15 Jul 2013 18:38:30 +0200 Subject: sh-pfc: Compute pin ranges automatically Remove the manually specified ranges from PFC SoC data and compute the ranges automatically. This prevents ranges from being out-of-sync with pins definitions. Signed-off-by: Laurent Pinchart Tested-by: Yusuke Goda --- drivers/pinctrl/sh-pfc/core.h | 8 ++++++++ 1 file changed, 8 insertions(+) (limited to 'drivers/pinctrl/sh-pfc/core.h') diff --git a/drivers/pinctrl/sh-pfc/core.h b/drivers/pinctrl/sh-pfc/core.h index 93963a19b340..a1b23762ac90 100644 --- a/drivers/pinctrl/sh-pfc/core.h +++ b/drivers/pinctrl/sh-pfc/core.h @@ -25,6 +25,11 @@ struct sh_pfc_window { struct sh_pfc_chip; struct sh_pfc_pinctrl; +struct sh_pfc_pin_range { + u16 start; + u16 end; +}; + struct sh_pfc { struct device *dev; const struct sh_pfc_soc_info *info; @@ -34,6 +39,9 @@ struct sh_pfc { unsigned int num_windows; struct sh_pfc_window *window; + struct sh_pfc_pin_range *ranges; + unsigned int nr_ranges; + unsigned int nr_gpio_pins; struct sh_pfc_chip *gpio; -- cgit v1.2.3