linux-arm-kernel.lists.infradead.org archive mirror
 help / color / mirror / Atom feed
From: darkstar6262@gmail.com (Cory Maccarrone)
To: linux-arm-kernel@lists.infradead.org
Subject: [PATCH 5/5] [htcherald] Add board support for UARTs, bluetooth
Date: Mon,  2 Aug 2010 08:29:36 -0700	[thread overview]
Message-ID: <1280762976-17284-6-git-send-email-darkstar6262@gmail.com> (raw)
In-Reply-To: <1280762976-17284-1-git-send-email-darkstar6262@gmail.com>

This change adds bluetooth and UART initialization support to the
HTC Herald board driver.  This allows use of the serial bluetooth
adapter attached to UART1 using hciattach.

Signed-off-by: Cory Maccarrone <darkstar6262@gmail.com>
---
 arch/arm/mach-omap1/Makefile          |    2 +-
 arch/arm/mach-omap1/board-htcherald.c |   23 +++++++++++++++++++++++
 2 files changed, 24 insertions(+), 1 deletions(-)

diff --git a/arch/arm/mach-omap1/Makefile b/arch/arm/mach-omap1/Makefile
index facfaeb..0b8cb18 100644
--- a/arch/arm/mach-omap1/Makefile
+++ b/arch/arm/mach-omap1/Makefile
@@ -42,7 +42,7 @@ obj-$(CONFIG_MACH_NOKIA770)		+= board-nokia770.o
 obj-$(CONFIG_MACH_AMS_DELTA)		+= board-ams-delta.o
 obj-$(CONFIG_AMS_DELTA_FIQ)		+= ams-delta-fiq.o ams-delta-fiq-handler.o
 obj-$(CONFIG_MACH_SX1)			+= board-sx1.o board-sx1-mmc.o
-obj-$(CONFIG_MACH_HERALD)		+= board-htcherald.o
+obj-$(CONFIG_MACH_HERALD)		+= board-htcherald.o htc-bt.o
 
 ifeq ($(CONFIG_ARCH_OMAP15XX),y)
 # Innovator-1510 FPGA
diff --git a/arch/arm/mach-omap1/board-htcherald.c b/arch/arm/mach-omap1/board-htcherald.c
index 1b12b75..cf4b908 100644
--- a/arch/arm/mach-omap1/board-htcherald.c
+++ b/arch/arm/mach-omap1/board-htcherald.c
@@ -47,8 +47,10 @@
 #include <plat/keypad.h>
 #include <plat/usb.h>
 #include <plat/mmc.h>
+#include <plat/mux.h>
 
 #include <mach/irqs.h>
+#include <mach/htc-bt.h>
 
 #include <linux/delay.h>
 
@@ -138,6 +140,7 @@ Happy Times         0 1 0 x  x x 0 x
 
 #define HTCPLD_GPIO_LED_DPAD		HTCPLD_BASE(0, 0)
 #define HTCPLD_GPIO_LED_KBD		HTCPLD_BASE(1, 0)
+#define HTCPLD_GPIO_BT_POWER		HTCPLD_BASE(1, 4)
 #define HTCPLD_GPIO_LED_CAPS		HTCPLD_BASE(1, 5)
 #define HTCPLD_GPIO_LED_RED_FLASH	HTCPLD_BASE(2, 1)
 #define HTCPLD_GPIO_LED_RED_SOLID	HTCPLD_BASE(2, 2)
@@ -423,6 +426,22 @@ static struct omap_mmc_platform_data htc_mmc1_data = {
 static struct omap_mmc_platform_data *htc_mmc_data[1];
 #endif
 
+/* Bluetooth */
+#define HTCHERALD_GPIO_BT_ENABLE 125
+
+static struct htc_bt_data htcherald_bt_data = {
+	.uart_clock	= "uart1_ck",
+	.gpio_pwr	= HTCPLD_GPIO_BT_POWER,
+	.gpio_enable	= HTCHERALD_GPIO_BT_ENABLE,
+};
+
+static struct platform_device bt_device = {
+	.name		= "htc-bt",
+	.id		= -1,
+	.dev = {
+		.platform_data = &htcherald_bt_data,
+	},
+};
 
 /* Platform devices for the Herald */
 static struct platform_device *devices[] __initdata = {
@@ -431,6 +450,7 @@ static struct platform_device *devices[] __initdata = {
 	&htcpld_device,
 	&gpio_leds_device,
 	&herald_gpiokeys_device,
+	&bt_device,
 };
 
 /*
@@ -574,6 +594,7 @@ done:
 	printk(KERN_INFO "USB setup complete.\n");
 }
 
+
 static void __init htcherald_init(void)
 {
 	printk(KERN_INFO "HTC Herald init.\n");
@@ -595,6 +616,8 @@ static void __init htcherald_init(void)
 
 	omap_register_i2c_bus(1, 100, NULL, 0);
 
+	omap_serial_init();
+
 #if defined(CONFIG_MMC_OMAP) || defined(CONFIG_MMC_OMAP_MODULE)
 	htc_mmc_data[0] = &htc_mmc1_data;
 	omap1_init_mmc(htc_mmc_data, 1);
-- 
1.6.0.4

  parent reply	other threads:[~2010-08-02 15:29 UTC|newest]

Thread overview: 16+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2010-08-02 15:29 [PATCH 0/5] HTC Herald various device support Cory Maccarrone
2010-08-02 15:29 ` [PATCH 1/5] [OMAP] HTCHERALD: MMC, I2C, HTCPLD and related devices Cory Maccarrone
2010-08-04 10:10   ` Tony Lindgren
2010-08-08 17:39     ` [PATCH 1/5 v2] " Cory Maccarrone
2010-08-02 15:29 ` [PATCH 2/5] [OMAP] htcherald: SPI register config, TSC2046 touchscreen Cory Maccarrone
2010-08-04 10:12   ` Tony Lindgren
2010-08-02 15:29 ` [PATCH 3/5] [omap1] omap7xx clocks, mux, serial fixes Cory Maccarrone
2010-08-04 10:13   ` Tony Lindgren
2010-08-02 15:29 ` [PATCH 4/5] [omap1] Bluetooth device code common to HTC smartphones Cory Maccarrone
2010-08-04 10:15   ` Tony Lindgren
2010-08-08 17:28     ` Cory Maccarrone
2018-06-19 20:24       ` Tony Lindgren
2010-08-09 17:28         ` Cory Maccarrone
2010-08-10  6:36           ` Tony Lindgren
2010-08-02 15:29 ` Cory Maccarrone [this message]
2010-08-04 10:16   ` [PATCH 5/5] [htcherald] Add board support for UARTs, bluetooth Tony Lindgren

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=1280762976-17284-6-git-send-email-darkstar6262@gmail.com \
    --to=darkstar6262@gmail.com \
    --cc=linux-arm-kernel@lists.infradead.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: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).