summaryrefslogtreecommitdiffstats
path: root/drivers/pinctrl/freescale/pinctrl-imx.h
diff options
context:
space:
mode:
authorGary Bisson <gary.bisson@boundarydevices.com>2017-01-02 19:20:21 +0100
committerLinus Walleij <linus.walleij@linaro.org>2017-01-03 09:26:20 +0100
commite566fc11ea76ec10a42fc92c5561ace4479770dd (patch)
tree5af613dce04fdc8537a686c808aab9f8c29587dd /drivers/pinctrl/freescale/pinctrl-imx.h
parent824e4d954dfbf7ccb22340d4b56db64f9378d846 (diff)
downloadlinux-e566fc11ea76ec10a42fc92c5561ace4479770dd.tar.bz2
pinctrl: imx: use generic pinctrl helpers for managing groups
Now using group_desc structure instead of imx_pin_group. Also leveraging generic functions to retrieve groups count/name/pins. The imx_free_pingroups function can be removed since it is now handled by the core driver during unregister. Finally the device tree parsing is moved after the pinctrl driver registration since this latter initializes the radix trees. Signed-off-by: Gary Bisson <gary.bisson@boundarydevices.com> Signed-off-by: Linus Walleij <linus.walleij@linaro.org>
Diffstat (limited to 'drivers/pinctrl/freescale/pinctrl-imx.h')
-rw-r--r--drivers/pinctrl/freescale/pinctrl-imx.h19
1 files changed, 1 insertions, 18 deletions
diff --git a/drivers/pinctrl/freescale/pinctrl-imx.h b/drivers/pinctrl/freescale/pinctrl-imx.h
index 62aa8f8f57e9..3c51db15223b 100644
--- a/drivers/pinctrl/freescale/pinctrl-imx.h
+++ b/drivers/pinctrl/freescale/pinctrl-imx.h
@@ -18,7 +18,7 @@
struct platform_device;
/**
- * struct imx_pin_group - describes a single i.MX pin
+ * struct imx_pin - describes a single i.MX pin
* @pin: the pin_id of this pin
* @mux_mode: the mux mode for this pin.
* @input_reg: the select input register offset for this pin if any
@@ -35,21 +35,6 @@ struct imx_pin {
};
/**
- * struct imx_pin_group - describes an IMX pin group
- * @name: the name of this specific pin group
- * @npins: the number of pins in this group array, i.e. the number of
- * elements in .pins so we can iterate over that array
- * @pin_ids: array of pin_ids. pinctrl forces us to maintain such an array
- * @pins: array of pins
- */
-struct imx_pin_group {
- const char *name;
- unsigned npins;
- unsigned int *pin_ids;
- struct imx_pin *pins;
-};
-
-/**
* struct imx_pmx_func - describes IMX pinmux functions
* @name: the name of this specific function
* @groups: corresponding pin groups
@@ -76,13 +61,11 @@ struct imx_pinctrl_soc_info {
const struct pinctrl_pin_desc *pins;
unsigned int npins;
struct imx_pin_reg *pin_regs;
- unsigned int ngroups;
unsigned int group_index;
unsigned int nfunctions;
unsigned int flags;
const char *gpr_compatible;
struct radix_tree_root ftree;
- struct radix_tree_root pgtree;
struct mutex mutex;
};