diff options
author | Ashwin Joshi <asjoshi@nvidia.com> | 2012-07-27 15:54:22 +0530 |
---|---|---|
committer | Simone Willett <swillett@nvidia.com> | 2012-08-08 14:03:51 -0700 |
commit | 39f69f846f7dec18b920a48eb8bd1de6d291dd6e (patch) | |
tree | 01c32a228b5df44952463e63e89a0821aca2a83a /arch/arm/mach-tegra/board-e1853-sdhci.c | |
parent | 42910ff9b782d27629c038c4d2f6e0024ee205f1 (diff) |
ARM: tegra: e1853: Add board support for e1853
E1853 is T30 based Automotive platform.
Changes done:
1. New board specific files added
2. Added new machine number for E1853
3. Added pinmux configuration for E1853
Bug 966833
Bug 1018258
Signed-off-by: Ashwin Joshi <asjoshi@nvidia.com>
Change-Id: Ibf1093f59e10a0a5cfa42a177c21c0db01983196
Reviewed-on: http://git-master/r/118000
Tested-by: Ashwin Joshi <asjoshi@nvidia.com>
Reviewed-by: Sandeep Trasi <strasi@nvidia.com>
(cherry picked from commit ad9dd1b3242f23c0f46eaf92ab49f495c06f330f)
Reviewed-on: http://git-master/r/119580
Reviewed-by: Simone Willett <swillett@nvidia.com>
Tested-by: Simone Willett <swillett@nvidia.com>
Diffstat (limited to 'arch/arm/mach-tegra/board-e1853-sdhci.c')
-rw-r--r-- | arch/arm/mach-tegra/board-e1853-sdhci.c | 83 |
1 files changed, 83 insertions, 0 deletions
diff --git a/arch/arm/mach-tegra/board-e1853-sdhci.c b/arch/arm/mach-tegra/board-e1853-sdhci.c new file mode 100644 index 000000000000..5446bb46df15 --- /dev/null +++ b/arch/arm/mach-tegra/board-e1853-sdhci.c @@ -0,0 +1,83 @@ +/* + * arch/arm/mach-tegra/board-e1853-sdhci.c + * + * Copyright (c) 2012, NVIDIA CORPORATION. All rights reserved. + * + * This program is free software; you can redistribute it and/or modify it + * under the terms and conditions of the GNU General Public License, + * version 2, as published by the Free Software Foundation. + * + * This program is distributed in the hope it will be useful, but WITHOUT + * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or + * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for + * more details. + * + * You should have received a copy of the GNU General Public License + * along with this program. If not, see <http://www.gnu.org/licenses/>. + * + */ + +#include <linux/resource.h> +#include <linux/platform_device.h> +#include <linux/wlan_plat.h> +#include <linux/delay.h> +#include <linux/gpio.h> +#include <linux/clk.h> +#include <linux/err.h> +#include <linux/mmc/host.h> + +#include <asm/mach-types.h> +#include <mach/irqs.h> +#include <mach/iomap.h> +#include <mach/sdhci.h> + +#include "gpio-names.h" +#include "board.h" +#include "board-e1853.h" +#include "devices.h" + +static struct tegra_sdhci_platform_data tegra_sdhci_platform_data1 = { + .cd_gpio = -1, + .wp_gpio = -1, + .power_gpio = -1, + .is_8bit = false, +}; + +static struct tegra_sdhci_platform_data tegra_sdhci_platform_data2 = { + .cd_gpio = -1, + .wp_gpio = -1, + .power_gpio = -1, + .is_8bit = 1, + .mmc_data = { + .built_in = 1, + } +}; + +static struct tegra_sdhci_platform_data tegra_sdhci_platform_data3 = { + .cd_gpio = TEGRA_GPIO_PN6, + .wp_gpio = TEGRA_GPIO_PD4, + .power_gpio = TEGRA_GPIO_PN7, + .is_8bit = false, +}; + +static struct tegra_sdhci_platform_data tegra_sdhci_platform_data4 = { + .cd_gpio = -1, + .wp_gpio = -1, + .power_gpio = -1, + .is_8bit = true, +}; + +int __init e1853_sdhci_init(void) +{ + tegra_sdhci_device1.dev.platform_data = &tegra_sdhci_platform_data1; + tegra_sdhci_device2.dev.platform_data = &tegra_sdhci_platform_data2; + tegra_sdhci_device3.dev.platform_data = &tegra_sdhci_platform_data3; + tegra_sdhci_device4.dev.platform_data = &tegra_sdhci_platform_data4; + + platform_device_register(&tegra_sdhci_device1); + platform_device_register(&tegra_sdhci_device2); + platform_device_register(&tegra_sdhci_device3); + platform_device_register(&tegra_sdhci_device4); + + return 0; +} |