2 * IMX pinmux core definitions
4 * Copyright (C) 2012 Freescale Semiconductor, Inc.
5 * Copyright (C) 2012 Linaro Ltd.
7 * Author: Dong Aisheng <dong.aisheng@linaro.org>
9 * This program is free software; you can redistribute it and/or modify
10 * it under the terms of the GNU General Public License as published by
11 * the Free Software Foundation; either version 2 of the License, or
12 * (at your option) any later version.
15 #ifndef __DRIVERS_PINCTRL_IMX1_H
16 #define __DRIVERS_PINCTRL_IMX1_H
18 struct platform_device
;
21 * struct imx1_pin - describes an IMX1/21/27 pin.
22 * @pin_id: ID of the described pin.
23 * @mux_id: ID of the mux setup.
24 * @config: Configuration of the pin (currently only pullup-enable).
33 * struct imx1_pin_group - describes an IMX pin group
34 * @name: the name of this specific pin group
35 * @pins: an array of imx1_pin structs used in this group
36 * @npins: the number of pins in this group array, i.e. the number of
37 * elements in .pins so we can iterate over that array
39 struct imx1_pin_group
{
41 unsigned int *pin_ids
;
42 struct imx1_pin
*pins
;
47 * struct imx1_pmx_func - describes IMX pinmux functions
48 * @name: the name of this specific function
49 * @groups: corresponding pin groups
50 * @num_groups: the number of groups
52 struct imx1_pmx_func
{
58 struct imx1_pinctrl_soc_info
{
60 const struct pinctrl_pin_desc
*pins
;
62 struct imx1_pin_group
*groups
;
64 struct imx1_pmx_func
*functions
;
65 unsigned int nfunctions
;
68 #define IMX_PINCTRL_PIN(pin) PINCTRL_PIN(pin, #pin)
70 int imx1_pinctrl_core_probe(struct platform_device
*pdev
,
71 struct imx1_pinctrl_soc_info
*info
);
72 int imx1_pinctrl_core_remove(struct platform_device
*pdev
);
73 #endif /* __DRIVERS_PINCTRL_IMX1_H */