From 9ca8dbcc65cfc63d6f5ef3312a33184e1d726e00 Mon Sep 17 00:00:00 2001 From: Yunhong Jiang Date: Tue, 4 Aug 2015 12:17:53 -0700 Subject: Add the rt linux 4.1.3-rt3 as base Import the rt linux 4.1.3-rt3 as OPNFV kvm base. It's from git://git.kernel.org/pub/scm/linux/kernel/git/rt/linux-rt-devel.git linux-4.1.y-rt and the base is: commit 0917f823c59692d751951bf5ea699a2d1e2f26a2 Author: Sebastian Andrzej Siewior Date: Sat Jul 25 12:13:34 2015 +0200 Prepare v4.1.3-rt3 Signed-off-by: Sebastian Andrzej Siewior We lose all the git history this way and it's not good. We should apply another opnfv project repo in future. Change-Id: I87543d81c9df70d99c5001fbdf646b202c19f423 Signed-off-by: Yunhong Jiang --- kernel/drivers/pinctrl/pinctrl-adi2.h | 75 +++++++++++++++++++++++++++++++++++ 1 file changed, 75 insertions(+) create mode 100644 kernel/drivers/pinctrl/pinctrl-adi2.h (limited to 'kernel/drivers/pinctrl/pinctrl-adi2.h') diff --git a/kernel/drivers/pinctrl/pinctrl-adi2.h b/kernel/drivers/pinctrl/pinctrl-adi2.h new file mode 100644 index 000000000..3ca297382 --- /dev/null +++ b/kernel/drivers/pinctrl/pinctrl-adi2.h @@ -0,0 +1,75 @@ +/* + * Pinctrl Driver for ADI GPIO2 controller + * + * Copyright 2007-2013 Analog Devices Inc. + * + * Licensed under the GPLv2 or later + */ + +#ifndef PINCTRL_PINCTRL_ADI2_H +#define PINCTRL_PINCTRL_ADI2_H + +#include + + /** + * struct adi_pin_group - describes a pin group + * @name: the name of this pin group + * @pins: an array of pins + * @num: the number of pins in this array + */ +struct adi_pin_group { + const char *name; + const unsigned *pins; + const unsigned num; + const unsigned short *mux; +}; + +#define ADI_PIN_GROUP(n, p, m) \ + { \ + .name = n, \ + .pins = p, \ + .num = ARRAY_SIZE(p), \ + .mux = m, \ + } + + /** + * struct adi_pmx_func - describes function mux setting of pin groups + * @name: the name of this function mux setting + * @groups: an array of pin groups + * @num_groups: the number of pin groups in this array + * @mux: the function mux setting array, end by zero + */ +struct adi_pmx_func { + const char *name; + const char * const *groups; + const unsigned num_groups; +}; + +#define ADI_PMX_FUNCTION(n, g) \ + { \ + .name = n, \ + .groups = g, \ + .num_groups = ARRAY_SIZE(g), \ + } + +/** + * struct adi_pinctrl_soc_data - ADI pin controller per-SoC configuration + * @functions: The functions supported on this SoC. + * @nfunction: The number of entries in @functions. + * @groups: An array describing all pin groups the pin SoC supports. + * @ngroups: The number of entries in @groups. + * @pins: An array describing all pins the pin controller affects. + * @npins: The number of entries in @pins. + */ +struct adi_pinctrl_soc_data { + const struct adi_pmx_func *functions; + int nfunctions; + const struct adi_pin_group *groups; + int ngroups; + const struct pinctrl_pin_desc *pins; + int npins; +}; + +void adi_pinctrl_soc_init(const struct adi_pinctrl_soc_data **soc); + +#endif /* PINCTRL_PINCTRL_ADI2_H */ -- cgit 1.2.3-korg