From: Marc Dietrich <marvin24-Mmb7MZpHnFY@public.gmane.org> To: Colin Cross <ccross-z5hGa2qSFaRBDgjK7y7TUQ@public.gmane.org> Cc: linux-tegra-u79uwXL29TY76Z2rM5mHXA@public.gmane.org, Olof Johansson <olof-nZhT3qVonbNeoWH0uzbU5w@public.gmane.org>, linux-arm-kernel-IAPFreCvJWM7uuMidbF8XUB+6BGkLq7r@public.gmane.org Subject: [PATCH 3/4] ARM: tegra: paz00: enable usb ports Date: Mon, 16 May 2011 20:10:57 +0200 [thread overview] Message-ID: <1305569458-4821-4-git-send-email-marvin24@gmx.de> (raw) In-Reply-To: <1305569458-4821-1-git-send-email-marvin24-Mmb7MZpHnFY@public.gmane.org> Signed-off-by: Marc Dietrich <marvin24-Mmb7MZpHnFY@public.gmane.org> --- arch/arm/mach-tegra/board-paz00-pinmux.c | 1 + arch/arm/mach-tegra/board-paz00.c | 35 +++++++++++++++++++++++++++++- arch/arm/mach-tegra/board-paz00.h | 1 + 3 files changed, 36 insertions(+), 1 deletions(-) diff --git a/arch/arm/mach-tegra/board-paz00-pinmux.c b/arch/arm/mach-tegra/board-paz00-pinmux.c index d2faa50..acee62e 100644 --- a/arch/arm/mach-tegra/board-paz00-pinmux.c +++ b/arch/arm/mach-tegra/board-paz00-pinmux.c @@ -147,6 +147,7 @@ static struct tegra_gpio_table gpio_table[] = { { .gpio = TEGRA_GPIO_SD4_CD, .enable = true }, { .gpio = TEGRA_GPIO_SD4_WP, .enable = true }, { .gpio = TEGRA_GPIO_SD4_POWER, .enable = true }, + { .gpio = TEGRA_ULPI_RST, .enable = true }, }; void paz00_pinmux_init(void) diff --git a/arch/arm/mach-tegra/board-paz00.c b/arch/arm/mach-tegra/board-paz00.c index 5f1c110..e1e1959 100644 --- a/arch/arm/mach-tegra/board-paz00.c +++ b/arch/arm/mach-tegra/board-paz00.c @@ -27,6 +27,7 @@ #include <linux/io.h> #include <linux/i2c.h> #include <linux/i2c-tegra.h> +#include <linux/platform_data/tegra_usb.h> #include <asm/mach-types.h> #include <asm/mach/arch.h> @@ -36,6 +37,8 @@ #include <mach/iomap.h> #include <mach/irqs.h> #include <mach/sdhci.h> +#include <mach/usb_phy.h> +#include <mach/gpio.h> #include "board.h" #include "board-paz00.h" @@ -95,6 +98,36 @@ static void paz00_i2c_init(void) platform_device_register(&tegra_i2c_device4); } +static struct tegra_ulpi_config ulpi_phy_config = { + .reset_gpio = TEGRA_ULPI_RST, + .clk = "cdev2", +}; + +static struct tegra_ehci_platform_data tegra_ehci_pdata[] = { + [0] = { + .operating_mode = TEGRA_USB_OTG, + .power_down_on_bus_suspend = 1, + }, + [1] = { + .phy_config = &ulpi_phy_config, + .operating_mode = TEGRA_USB_HOST, + .power_down_on_bus_suspend = 1, + }, + [2] = { + .operating_mode = TEGRA_USB_HOST, + .power_down_on_bus_suspend = 1, + }, +}; + +static void paz00_usb_init(void) +{ + tegra_ehci2_device.dev.platform_data = &tegra_ehci_pdata[1]; + tegra_ehci3_device.dev.platform_data = &tegra_ehci_pdata[2]; + + platform_device_register(&tegra_ehci2_device); + platform_device_register(&tegra_ehci3_device); +} + static void __init tegra_paz00_fixup(struct machine_desc *desc, struct tag *tags, char **cmdline, struct meminfo *mi) { @@ -109,7 +142,6 @@ static __initdata struct tegra_clk_init_table paz00_clk_init_table[] = { { NULL, NULL, 0, 0}, }; - static struct tegra_sdhci_platform_data sdhci_pdata1 = { .cd_gpio = TEGRA_GPIO_SD1_CD, .wp_gpio = TEGRA_GPIO_SD1_WP, @@ -142,6 +174,7 @@ static void __init tegra_paz00_init(void) platform_add_devices(paz00_devices, ARRAY_SIZE(paz00_devices)); paz00_i2c_init(); + paz00_usb_init(); } MACHINE_START(PAZ00, "paz00") diff --git a/arch/arm/mach-tegra/board-paz00.h b/arch/arm/mach-tegra/board-paz00.h index 221ce9c..6b0b733 100644 --- a/arch/arm/mach-tegra/board-paz00.h +++ b/arch/arm/mach-tegra/board-paz00.h @@ -23,6 +23,7 @@ #define TEGRA_GPIO_SD4_CD TEGRA_GPIO_PH2 #define TEGRA_GPIO_SD4_WP TEGRA_GPIO_PH3 #define TEGRA_GPIO_SD4_POWER TEGRA_GPIO_PI6 +#define TEGRA_ULPI_RST TEGRA_GPIO_PV0 void paz00_pinmux_init(void); -- 1.7.4.2
WARNING: multiple messages have this Message-ID (diff)
From: marvin24@gmx.de (Marc Dietrich) To: linux-arm-kernel@lists.infradead.org Subject: [PATCH 3/4] ARM: tegra: paz00: enable usb ports Date: Mon, 16 May 2011 20:10:57 +0200 [thread overview] Message-ID: <1305569458-4821-4-git-send-email-marvin24@gmx.de> (raw) In-Reply-To: <1305569458-4821-1-git-send-email-marvin24@gmx.de> Signed-off-by: Marc Dietrich <marvin24@gmx.de> --- arch/arm/mach-tegra/board-paz00-pinmux.c | 1 + arch/arm/mach-tegra/board-paz00.c | 35 +++++++++++++++++++++++++++++- arch/arm/mach-tegra/board-paz00.h | 1 + 3 files changed, 36 insertions(+), 1 deletions(-) diff --git a/arch/arm/mach-tegra/board-paz00-pinmux.c b/arch/arm/mach-tegra/board-paz00-pinmux.c index d2faa50..acee62e 100644 --- a/arch/arm/mach-tegra/board-paz00-pinmux.c +++ b/arch/arm/mach-tegra/board-paz00-pinmux.c @@ -147,6 +147,7 @@ static struct tegra_gpio_table gpio_table[] = { { .gpio = TEGRA_GPIO_SD4_CD, .enable = true }, { .gpio = TEGRA_GPIO_SD4_WP, .enable = true }, { .gpio = TEGRA_GPIO_SD4_POWER, .enable = true }, + { .gpio = TEGRA_ULPI_RST, .enable = true }, }; void paz00_pinmux_init(void) diff --git a/arch/arm/mach-tegra/board-paz00.c b/arch/arm/mach-tegra/board-paz00.c index 5f1c110..e1e1959 100644 --- a/arch/arm/mach-tegra/board-paz00.c +++ b/arch/arm/mach-tegra/board-paz00.c @@ -27,6 +27,7 @@ #include <linux/io.h> #include <linux/i2c.h> #include <linux/i2c-tegra.h> +#include <linux/platform_data/tegra_usb.h> #include <asm/mach-types.h> #include <asm/mach/arch.h> @@ -36,6 +37,8 @@ #include <mach/iomap.h> #include <mach/irqs.h> #include <mach/sdhci.h> +#include <mach/usb_phy.h> +#include <mach/gpio.h> #include "board.h" #include "board-paz00.h" @@ -95,6 +98,36 @@ static void paz00_i2c_init(void) platform_device_register(&tegra_i2c_device4); } +static struct tegra_ulpi_config ulpi_phy_config = { + .reset_gpio = TEGRA_ULPI_RST, + .clk = "cdev2", +}; + +static struct tegra_ehci_platform_data tegra_ehci_pdata[] = { + [0] = { + .operating_mode = TEGRA_USB_OTG, + .power_down_on_bus_suspend = 1, + }, + [1] = { + .phy_config = &ulpi_phy_config, + .operating_mode = TEGRA_USB_HOST, + .power_down_on_bus_suspend = 1, + }, + [2] = { + .operating_mode = TEGRA_USB_HOST, + .power_down_on_bus_suspend = 1, + }, +}; + +static void paz00_usb_init(void) +{ + tegra_ehci2_device.dev.platform_data = &tegra_ehci_pdata[1]; + tegra_ehci3_device.dev.platform_data = &tegra_ehci_pdata[2]; + + platform_device_register(&tegra_ehci2_device); + platform_device_register(&tegra_ehci3_device); +} + static void __init tegra_paz00_fixup(struct machine_desc *desc, struct tag *tags, char **cmdline, struct meminfo *mi) { @@ -109,7 +142,6 @@ static __initdata struct tegra_clk_init_table paz00_clk_init_table[] = { { NULL, NULL, 0, 0}, }; - static struct tegra_sdhci_platform_data sdhci_pdata1 = { .cd_gpio = TEGRA_GPIO_SD1_CD, .wp_gpio = TEGRA_GPIO_SD1_WP, @@ -142,6 +174,7 @@ static void __init tegra_paz00_init(void) platform_add_devices(paz00_devices, ARRAY_SIZE(paz00_devices)); paz00_i2c_init(); + paz00_usb_init(); } MACHINE_START(PAZ00, "paz00") diff --git a/arch/arm/mach-tegra/board-paz00.h b/arch/arm/mach-tegra/board-paz00.h index 221ce9c..6b0b733 100644 --- a/arch/arm/mach-tegra/board-paz00.h +++ b/arch/arm/mach-tegra/board-paz00.h @@ -23,6 +23,7 @@ #define TEGRA_GPIO_SD4_CD TEGRA_GPIO_PH2 #define TEGRA_GPIO_SD4_WP TEGRA_GPIO_PH3 #define TEGRA_GPIO_SD4_POWER TEGRA_GPIO_PI6 +#define TEGRA_ULPI_RST TEGRA_GPIO_PV0 void paz00_pinmux_init(void); -- 1.7.4.2
next prev parent reply other threads:[~2011-05-16 18:10 UTC|newest] Thread overview: 14+ messages / expand[flat|nested] mbox.gz Atom feed top 2011-05-16 18:10 [PATCH 0/4] ARM: tegra: paz00 patches for 2.6.40 Marc Dietrich 2011-05-16 18:10 ` Marc Dietrich [not found] ` <1305569458-4821-1-git-send-email-marvin24-Mmb7MZpHnFY@public.gmane.org> 2011-05-16 18:10 ` [PATCH 1/4] ARM: tegra: paz00: whitespace cleanup Marc Dietrich 2011-05-16 18:10 ` Marc Dietrich [not found] ` <1305569458-4821-2-git-send-email-marvin24-Mmb7MZpHnFY@public.gmane.org> 2011-05-19 5:05 ` Olof Johansson 2011-05-19 5:05 ` Olof Johansson [not found] ` <20110519050544.GA5495-O5ziIzlqnXUVNXGz7ipsyg@public.gmane.org> 2011-05-19 10:48 ` Marvin 2011-05-19 10:48 ` Marvin 2011-05-16 18:10 ` [PATCH 2/4] ARM: tegra: paz00: register i2c busses Marc Dietrich 2011-05-16 18:10 ` Marc Dietrich 2011-05-16 18:10 ` Marc Dietrich [this message] 2011-05-16 18:10 ` [PATCH 3/4] ARM: tegra: paz00: enable usb ports Marc Dietrich 2011-05-16 18:10 ` [PATCH 4/4] ARM: tegra: paz00: cleanup sdhci ports Marc Dietrich 2011-05-16 18:10 ` Marc Dietrich
Reply instructions: You may reply publicly to this message via plain-text email using any one of the following methods: * Save the following mbox file, import it into your mail client, and reply-to-all from there: mbox Avoid top-posting and favor interleaved quoting: https://en.wikipedia.org/wiki/Posting_style#Interleaved_style * Reply using the --to, --cc, and --in-reply-to switches of git-send-email(1): git send-email \ --in-reply-to=1305569458-4821-4-git-send-email-marvin24@gmx.de \ --to=marvin24-mmb7mzphnfy@public.gmane.org \ --cc=ccross-z5hGa2qSFaRBDgjK7y7TUQ@public.gmane.org \ --cc=linux-arm-kernel-IAPFreCvJWM7uuMidbF8XUB+6BGkLq7r@public.gmane.org \ --cc=linux-tegra-u79uwXL29TY76Z2rM5mHXA@public.gmane.org \ --cc=olof-nZhT3qVonbNeoWH0uzbU5w@public.gmane.org \ /path/to/YOUR_REPLY https://kernel.org/pub/software/scm/git/docs/git-send-email.html * If your mail client supports setting the In-Reply-To header via mailto: links, try the mailto: linkBe sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes, see mirroring instructions on how to clone and mirror all data and code used by this external index.