Linux Kernel  3.7.1
 All Data Structures Namespaces Files Functions Variables Typedefs Enumerations Enumerator Macros Groups Pages
pinctrl-tegra.h
Go to the documentation of this file.
1 /*
2  * Driver for the NVIDIA Tegra pinmux
3  *
4  * Copyright (c) 2011, NVIDIA CORPORATION. All rights reserved.
5  *
6  * This program is free software; you can redistribute it and/or modify it
7  * under the terms and conditions of the GNU General Public License,
8  * version 2, as published by the Free Software Foundation.
9  *
10  * This program is distributed in the hope it will be useful, but WITHOUT
11  * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
12  * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for
13  * more details.
14  */
15 
16 #ifndef __PINMUX_TEGRA_H__
17 #define __PINMUX_TEGRA_H__
18 
20  /* argument: tegra_pinconf_pull */
22  /* argument: tegra_pinconf_tristate */
24  /* argument: Boolean */
26  /* argument: Boolean */
28  /* argument: Boolean */
30  /* argument: Boolean */
32  /* argument: Boolean */
34  /* argument: Boolean */
36  /* argument: Boolean */
38  /* argument: Integer, range is HW-dependant */
40  /* argument: Integer, range is HW-dependant */
42  /* argument: Integer, range is HW-dependant */
44  /* argument: Integer, range is HW-dependant */
46 };
47 
52 };
53 
57 };
58 
59 #define TEGRA_PINCONF_PACK(_param_, _arg_) ((_param_) << 16 | (_arg_))
60 #define TEGRA_PINCONF_UNPACK_PARAM(_conf_) ((_conf_) >> 16)
61 #define TEGRA_PINCONF_UNPACK_ARG(_conf_) ((_conf_) & 0xffff)
62 
70  const char *name;
71  const char * const *groups;
72  unsigned ngroups;
73 };
74 
122  const char *name;
123  const unsigned *pins;
124  unsigned npins;
125  unsigned funcs[4];
126  unsigned func_safe;
161 };
162 
177  unsigned ngpios;
178  const struct pinctrl_pin_desc *pins;
179  unsigned npins;
180  const struct tegra_function *functions;
181  unsigned nfunctions;
182  const struct tegra_pingroup *groups;
183  unsigned ngroups;
184 };
185 
186 int tegra_pinctrl_probe(struct platform_device *pdev,
187  const struct tegra_pinctrl_soc_data *soc_data);
188 int tegra_pinctrl_remove(struct platform_device *pdev);
189 
190 #endif