Jay Chokshi | ea67c62 | 2011-07-29 17:12:26 -0700 | [diff] [blame] | 1 | /* Copyright (c) 2011, Code Aurora Forum. All rights reserved. |
| 2 | * |
| 3 | * This program is free software; you can redistribute it and/or modify |
| 4 | * it under the terms of the GNU General Public License version 2 and |
| 5 | * only version 2 as published by the Free Software Foundation. |
| 6 | * |
| 7 | * This program is distributed in the hope that it will be useful, |
| 8 | * but WITHOUT ANY WARRANTY; without even the implied warranty of |
| 9 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the |
| 10 | * GNU General Public License for more details. |
| 11 | */ |
| 12 | |
| 13 | #ifndef __ARCH_ARM_MACH_MSM_BOARD_APQ8064_H |
| 14 | #define __ARCH_ARM_MACH_MSM_BOARD_APQ8064_H |
| 15 | |
| 16 | #include <linux/mfd/pm8xxx/pm8921.h> |
Jay Chokshi | 44873f7 | 2011-08-30 17:24:26 -0700 | [diff] [blame] | 17 | #include <linux/mfd/pm8xxx/pm8821.h> |
Jay Chokshi | ea67c62 | 2011-07-29 17:12:26 -0700 | [diff] [blame] | 18 | |
Jay Chokshi | bc3d98d | 2011-08-10 17:14:23 -0700 | [diff] [blame] | 19 | /* Macros assume PMIC GPIOs and MPPs start at 1 */ |
| 20 | #define PM8921_GPIO_BASE NR_GPIO_IRQS |
| 21 | #define PM8921_GPIO_PM_TO_SYS(pm_gpio) (pm_gpio - 1 + PM8921_GPIO_BASE) |
| 22 | #define PM8921_MPP_BASE (PM8921_GPIO_BASE + PM8921_NR_GPIOS) |
| 23 | #define PM8921_MPP_PM_TO_SYS(pm_mpp) (pm_mpp - 1 + PM8921_MPP_BASE) |
| 24 | #define PM8921_IRQ_BASE (NR_MSM_IRQS + NR_GPIO_IRQS) |
| 25 | |
Jay Chokshi | 44873f7 | 2011-08-30 17:24:26 -0700 | [diff] [blame] | 26 | #define PM8821_MPP_BASE (PM8921_MPP_BASE + PM8921_NR_MPPS) |
| 27 | #define PM8821_MPP_PM_TO_SYS(pm_mpp) (pm_mpp - 1 + PM8821_MPP_BASE) |
| 28 | #define PM8821_IRQ_BASE (PM8921_IRQ_BASE + PM8921_NR_IRQS) |
| 29 | |
Jay Chokshi | ea67c62 | 2011-07-29 17:12:26 -0700 | [diff] [blame] | 30 | extern struct pm8921_regulator_platform_data |
| 31 | msm8064_pm8921_regulator_pdata[] __devinitdata; |
| 32 | |
| 33 | extern int msm8064_pm8921_regulator_pdata_len __devinitdata; |
Sahitya Tummala | 3586ed9 | 2011-08-03 09:13:23 +0530 | [diff] [blame] | 34 | |
| 35 | struct mmc_platform_data; |
| 36 | int __init apq8064_add_sdcc(unsigned int controller, |
| 37 | struct mmc_platform_data *plat); |
| 38 | |
Jay Chokshi | ea67c62 | 2011-07-29 17:12:26 -0700 | [diff] [blame] | 39 | #endif |