aboutsummaryrefslogtreecommitdiffstats
path: root/arch/arm/mach-tegra/board-p1852.h
diff options
context:
space:
mode:
authorJonathan Herman <hermanjl@cs.unc.edu>2013-01-22 10:38:37 -0500
committerJonathan Herman <hermanjl@cs.unc.edu>2013-01-22 10:38:37 -0500
commitfcc9d2e5a6c89d22b8b773a64fb4ad21ac318446 (patch)
treea57612d1888735a2ec7972891b68c1ac5ec8faea /arch/arm/mach-tegra/board-p1852.h
parent8dea78da5cee153b8af9c07a2745f6c55057fe12 (diff)
Added missing tegra files.HEADmaster
Diffstat (limited to 'arch/arm/mach-tegra/board-p1852.h')
-rw-r--r--arch/arm/mach-tegra/board-p1852.h99
1 files changed, 99 insertions, 0 deletions
diff --git a/arch/arm/mach-tegra/board-p1852.h b/arch/arm/mach-tegra/board-p1852.h
new file mode 100644
index 00000000000..f146f30ed2c
--- /dev/null
+++ b/arch/arm/mach-tegra/board-p1852.h
@@ -0,0 +1,99 @@
1/*
2 * arch/arm/mach-tegra/board-p1852.h
3 *
4 * Copyright (c) 2012, 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 * You should have received a copy of the GNU General Public License
16 * along with this program. If not, see <http://www.gnu.org/licenses/>.
17 */
18
19#ifndef _MACH_TEGRA_BOARD_P1852_H
20#define _MACH_TEGRA_BOARD_P1852_H
21
22#include <mach/gpio.h>
23#include <mach/irqs.h>
24#include <linux/gpio.h>
25#include <linux/mfd/tps6591x.h>
26
27
28/* External peripheral act as gpio */
29/* TPS6591x GPIOs */
30#define TPS6591X_GPIO_BASE TEGRA_NR_GPIOS
31#define TPS6591X_GPIO_GP0 (TPS6591X_GPIO_BASE + 0)
32#define TPS6591X_GPIO_GP1 (TPS6591X_GPIO_BASE + 1)
33#define TPS6591X_GPIO_GP2 (TPS6591X_GPIO_BASE + 2)
34#define TPS6591X_GPIO_GP3 (TPS6591X_GPIO_BASE + 3)
35#define TPS6591X_GPIO_GP4 (TPS6591X_GPIO_BASE + 4)
36#define TPS6591X_GPIO_GP5 (TPS6591X_GPIO_BASE + 5)
37#define TPS6591X_GPIO_GP6 (TPS6591X_GPIO_BASE + 6)
38#define TPS6591X_GPIO_GP7 (TPS6591X_GPIO_BASE + 7)
39#define TPS6591X_GPIO_GP8 (TPS6591X_GPIO_BASE + 8)
40#define TPS6591X_GPIO_END TPS6591X_GPIO_GP8
41
42/* CAM_TCA6416 GPIOs */
43#define CAM_TCA6416_GPIO_BASE (TPS6591X_GPIO_END + 1)
44#define CAM1_PWR_DN_GPIO (CAM_TCA6416_GPIO_BASE + 0)
45#define CAM1_RST_L_GPIO (CAM_TCA6416_GPIO_BASE + 1)
46#define CAM1_AF_PWR_DN_L_GPIO (CAM_TCA6416_GPIO_BASE + 2)
47#define CAM1_LDO_SHUTDN_L_GPIO (CAM_TCA6416_GPIO_BASE + 3)
48#define CAM2_PWR_DN_GPIO (CAM_TCA6416_GPIO_BASE + 4)
49#define CAM2_RST_L_GPIO (CAM_TCA6416_GPIO_BASE + 5)
50#define CAM2_AF_PWR_DN_L_GPIO (CAM_TCA6416_GPIO_BASE + 6)
51#define CAM2_LDO_SHUTDN_L_GPIO (CAM_TCA6416_GPIO_BASE + 7)
52#define CAM_FRONT_PWR_DN_GPIO (CAM_TCA6416_GPIO_BASE + 8)
53#define CAM_FRONT_RST_L_GPIO (CAM_TCA6416_GPIO_BASE + 9)
54#define CAM_FRONT_AF_PWR_DN_L_GPIO (CAM_TCA6416_GPIO_BASE + 10)
55#define CAM_FRONT_LDO_SHUTDN_L_GPIO (CAM_TCA6416_GPIO_BASE + 11)
56#define CAM_FRONT_LED_EXP (CAM_TCA6416_GPIO_BASE + 12)
57#define CAM_SNN_LED_REAR_EXP (CAM_TCA6416_GPIO_BASE + 13)
58/* PIN 19 NOT USED and is reserved */
59#define CAM_NOT_USED (CAM_TCA6416_GPIO_BASE + 14)
60#define CAM_I2C_MUX_RST_EXP (CAM_TCA6416_GPIO_BASE + 15)
61#define CAM_TCA6416_GPIO_END CAM_I2C_MUX_RST_EXP
62
63/* WM8903 gpios */
64#define WM8903_GPIO_BASE (CAM_TCA6416_GPIO_END + 1)
65#define WM8903_GP1 (WM8903_GPIO_BASE + 0)
66#define WM8903_GP2 (WM8903_GPIO_BASE + 1)
67#define WM8903_GP3 (WM8903_GPIO_BASE + 2)
68#define WM8903_GP4 (WM8903_GPIO_BASE + 3)
69#define WM8903_GP5 (WM8903_GPIO_BASE + 4)
70#define WM8903_GPIO_END WM8903_GP5
71
72/* CAMERA RELATED GPIOs on p1852 */
73#define OV5650_RESETN_GPIO TEGRA_GPIO_PBB0
74#define CAM1_POWER_DWN_GPIO TEGRA_GPIO_PBB5
75#define CAM2_POWER_DWN_GPIO TEGRA_GPIO_PBB6
76#define CAM3_POWER_DWN_GPIO TEGRA_GPIO_PBB7
77#define CAMERA_CSI_CAM_SEL_GPIO TEGRA_GPIO_PBB4
78#define CAMERA_CSI_MUX_SEL_GPIO TEGRA_GPIO_PCC1
79#define CAM1_LDO_EN_GPIO TEGRA_GPIO_PR6
80#define CAM2_LDO_EN_GPIO TEGRA_GPIO_PR7
81#define CAM3_LDO_EN_GPIO TEGRA_GPIO_PS0
82
83
84#define AC_PRESENT_GPIO TPS6591X_GPIO_GP4
85/*****************Interrupt tables ******************/
86/* External peripheral act as interrupt controller */
87/* TPS6591x IRQs */
88#define TPS6591X_IRQ_BASE TEGRA_NR_IRQS
89#define TPS6591X_IRQ_END (TPS6591X_IRQ_BASE + 18)
90
91#define AC_PRESENT_INT (TPS6591X_INT_GPIO4 + TPS6591X_IRQ_BASE)
92
93int p1852_sdhci_init(void);
94int p1852_pinmux_init(void);
95int p1852_panel_init(void);
96int p1852_gpio_init(void);
97int p1852_pins_state_init(void);
98
99#endif