summaryrefslogtreecommitdiff
path: root/packages/linux/linux-h6300-omap1-2.6.12-rc5/h6300_omap1_2612rc5.patch
diff options
context:
space:
mode:
authorKoen Kooi <koen@openembedded.org>2005-08-27 10:45:10 +0000
committerOpenEmbedded Project <openembedded-devel@lists.openembedded.org>2005-08-27 10:45:10 +0000
commit32bb30dcfc8d988c4f4a18c7cfadf2f25695201e (patch)
tree49195e4765479b4bc5c7b939a626f398413127f2 /packages/linux/linux-h6300-omap1-2.6.12-rc5/h6300_omap1_2612rc5.patch
parent0da60af87b7eef345fc4f2ddc03cb7aa15c586d5 (diff)
h6300: add machine description and kernel, courtesy 'lamikr', closes #255
Diffstat (limited to 'packages/linux/linux-h6300-omap1-2.6.12-rc5/h6300_omap1_2612rc5.patch')
-rw-r--r--packages/linux/linux-h6300-omap1-2.6.12-rc5/h6300_omap1_2612rc5.patch1055
1 files changed, 1055 insertions, 0 deletions
diff --git a/packages/linux/linux-h6300-omap1-2.6.12-rc5/h6300_omap1_2612rc5.patch b/packages/linux/linux-h6300-omap1-2.6.12-rc5/h6300_omap1_2612rc5.patch
new file mode 100644
index 0000000000..7e2f452850
--- /dev/null
+++ b/packages/linux/linux-h6300-omap1-2.6.12-rc5/h6300_omap1_2612rc5.patch
@@ -0,0 +1,1055 @@
+diff -Naur linux-2.6.12-rc5_omap1/arch/arm/mach-omap/clock.c linux-2.6.12-rc5_omap1_h6300/arch/arm/mach-omap/clock.c
+--- linux-2.6.12-rc5_omap1/arch/arm/mach-omap/clock.c 2005-08-23 22:36:30.426733413 +0300
++++ linux-2.6.12-rc5_omap1_h6300/arch/arm/mach-omap/clock.c 2005-08-23 22:38:07.446289831 +0300
+@@ -21,6 +21,7 @@
+ #include <asm/arch/usb.h>
+
+ #include "clock.h"
++#include <asm/mach-types.h>
+
+ static LIST_HEAD(clocks);
+ static DECLARE_MUTEX(clocks_sem);
+@@ -447,8 +448,17 @@
+ static struct clk mclk_1510 = {
+ .name = "mclk",
+ /* Direct from ULPD, no parent. May be enabled by ext hardware. */
++#if 0
+ .rate = 12000000,
+ .flags = CLOCK_IN_OMAP1510 | RATE_FIXED,
++#else
++ .flags = CLOCK_IN_OMAP1510,
++ .enable_reg = COM_CLK_DIV_CTRL_SEL,
++ .enable_bit = COM_ULPD_PLL_CLK_REQ,
++ .set_rate = &set_ext_clk_rate,
++ .round_rate = &round_ext_clk_rate,
++ .init = &init_ext_clk,
++#endif
+ };
+
+ static struct clk mclk_16xx = {
+@@ -1247,6 +1257,9 @@
+ clk_use(&armxor_ck);
+ clk_use(&armtim_ck);
+
++ if (machine_is_h6300())
++ clk_enable(&lcd_ck);
++
+ if (cpu_is_omap1510())
+ clk_enable(&arm_gpio_ck);
+
+diff -Naur linux-2.6.12-rc5_omap1/arch/arm/mach-omap/dma.c linux-2.6.12-rc5_omap1_h6300/arch/arm/mach-omap/dma.c
+--- linux-2.6.12-rc5_omap1/arch/arm/mach-omap/dma.c 2005-08-23 22:36:30.615703332 +0300
++++ linux-2.6.12-rc5_omap1_h6300/arch/arm/mach-omap/dma.c 2005-08-23 22:38:07.480284420 +0300
+@@ -671,6 +671,7 @@
+ unsigned long top, bottom;
+ int es;
+ u16 w;
++ u16 l;
+ unsigned long en, fn;
+ long ei, fi;
+ unsigned long vxres;
+@@ -769,6 +770,10 @@
+ }
+
+ if (omap_dma_in_1510_mode()) {
++ l = omap_readw(OMAP1510_DMA_LCD_CTRL);
++ l &= ~(1 << 6);
++ omap_writew (l, OMAP1510_DMA_LCD_CTRL);
++
+ omap_writew(top >> 16, OMAP1510_DMA_LCD_TOP_F1_U);
+ omap_writew(top, OMAP1510_DMA_LCD_TOP_F1_L);
+ omap_writew(bottom >> 16, OMAP1510_DMA_LCD_BOT_F1_U);
+@@ -893,7 +898,6 @@
+ w = omap_readw(OMAP1610_DMA_LCD_CCR);
+ w |= 1 << 7;
+ omap_writew(w, OMAP1610_DMA_LCD_CCR);
+-
+ lcd_dma.active = 1;
+ }
+
+diff -Naur linux-2.6.12-rc5_omap1/arch/arm/mach-omap/mcbsp.c linux-2.6.12-rc5_omap1_h6300/arch/arm/mach-omap/mcbsp.c
+--- linux-2.6.12-rc5_omap1/arch/arm/mach-omap/mcbsp.c 2005-08-23 22:36:31.270599085 +0300
++++ linux-2.6.12-rc5_omap1_h6300/arch/arm/mach-omap/mcbsp.c 2005-08-23 22:38:07.481284261 +0300
+@@ -760,3 +760,4 @@
+ EXPORT_SYMBOL(omap_mcbsp_xmit_buffer);
+ EXPORT_SYMBOL(omap_mcbsp_recv_buffer);
+ EXPORT_SYMBOL(omap_mcbsp_set_spi_mode);
++EXPORT_SYMBOL(omap_mcbsp_pollwrite);
+diff -Naur linux-2.6.12-rc5_omap1/arch/arm/mach-omap/omap1/board-h6300.c linux-2.6.12-rc5_omap1_h6300/arch/arm/mach-omap/omap1/board-h6300.c
+--- linux-2.6.12-rc5_omap1/arch/arm/mach-omap/omap1/board-h6300.c 1970-01-01 02:00:00.000000000 +0200
++++ linux-2.6.12-rc5_omap1_h6300/arch/arm/mach-omap/omap1/board-h6300.c 2005-08-23 22:38:07.482284102 +0300
+@@ -0,0 +1,143 @@
++/*
++ * linux/arch/arm/mach-omap/board-generic.c
++ *
++ * Modified from board-h6300.c
++ *
++ * Code for generic OMAP board. Should work on many OMAP systems where
++ * the device drivers take care of all the necessary hardware initialization.
++ * Do not put any board specific code to this file; create a new machine
++ * type if you need custom low-level initializations.
++ *
++ * This program is free software; you can redistribute it and/or modify
++ * it under the terms of the GNU General Public License version 2 as
++ * published by the Free Software Foundation.
++ */
++
++#include <linux/kernel.h>
++#include <linux/init.h>
++#include <linux/device.h>
++#include <linux/delay.h>
++#include <linux/mtd/mtd.h>
++#include <linux/mtd/partitions.h>
++
++#include <asm/hardware.h>
++#include <asm/mach-types.h>
++#include <asm/mach/arch.h>
++#include <asm/mach/flash.h>
++#include <asm/mach/map.h>
++
++#include <asm/arch/gpio.h>
++#include <asm/arch/tc.h>
++#include <asm/arch/usb.h>
++
++#include "../common.h"
++
++static int __initdata h6300_serial_ports[OMAP_MAX_NR_PORTS] = {1, 1, 1};
++
++static struct mtd_partition h6300_partitions[] = {
++ /* bootloader (U-Boot, etc) in first sector */
++ {
++ .name = "bootloader",
++ .offset = 0,
++ .size = SZ_128K,
++ .mask_flags = MTD_WRITEABLE, /* force read-only */
++ },
++ /* bootloader params in the next sector */
++ {
++ .name = "params",
++ .offset = MTDPART_OFS_APPEND,
++ .size = SZ_128K,
++ .mask_flags = 0,
++ },
++ /* kernel */
++ {
++ .name = "kernel",
++ .offset = MTDPART_OFS_APPEND,
++ .size = SZ_2M,
++ .mask_flags = 0
++ },
++ /* rest of flash1 is a file system */
++ {
++ .name = "rootfs",
++ .offset = MTDPART_OFS_APPEND,
++ .size = SZ_16M - SZ_2M - 2 * SZ_128K,
++ .mask_flags = 0
++ },
++ /* file system */
++ {
++ .name = "filesystem",
++ .offset = MTDPART_OFS_APPEND,
++ .size = MTDPART_SIZ_FULL,
++ .mask_flags = 0
++ }
++};
++
++static struct flash_platform_data h6300_flash_data = {
++ .map_name = "cfi_probe",
++ .width = 2,
++ .parts = h6300_partitions,
++ .nr_parts = ARRAY_SIZE(h6300_partitions),
++};
++
++static struct resource h6300_flash_resource = {
++ .start = OMAP_CS0_PHYS,
++ .end = OMAP_CS0_PHYS + SZ_32M - 1,
++ .flags = IORESOURCE_MEM,
++};
++
++static struct platform_device h6300_flash_device = {
++ .name = "omapflash",
++ .id = 0,
++ .dev = {
++ .platform_data = &h6300_flash_data,
++ },
++ .num_resources = 1,
++ .resource = &h6300_flash_resource,
++};
++
++static struct platform_device *h6300_devices[] __initdata = {
++ &h6300_flash_device,
++};
++
++static void __init h6300_init_irq(void)
++{
++ omap_init_irq();
++ omap_gpio_init();
++}
++
++/* assume no Mini-AB port */
++
++static struct omap_usb_config h6300_usb_config __initdata = {
++ .hmc_mode = 0,
++ .register_dev = 1,
++ .pins[0] = 0,
++};
++
++static struct omap_board_config_kernel h6300_config[] = {
++ { OMAP_TAG_USB, &h6300_usb_config },
++};
++
++static void __init h6300_init(void)
++{
++ platform_add_devices(h6300_devices, ARRAY_SIZE(h6300_devices));
++ h6300_config[0].data = &h6300_usb_config;
++
++ omap_board_config = h6300_config;
++ omap_board_config_size = ARRAY_SIZE(h6300_config);
++}
++
++static void __init h6300_map_io(void)
++{
++ omap_map_common_io();
++ omap_serial_init(h6300_serial_ports);
++}
++
++MACHINE_START(H6300, "HP IPaq H6300")
++ MAINTAINER("Everett Coleman II <gcc80x86@fuzzyneural.net>")
++ BOOT_MEM(0x10000000, 0xfff00000, 0xfef00000)
++ BOOT_PARAMS(0x10000100)
++ MAPIO(h6300_map_io)
++ INITIRQ(h6300_init_irq)
++ INIT_MACHINE(h6300_init)
++ .timer = &omap_timer,
++MACHINE_END
+diff -Naur linux-2.6.12-rc5_omap1/arch/arm/mach-omap/omap1/Kconfig linux-2.6.12-rc5_omap1_h6300/arch/arm/mach-omap/omap1/Kconfig
+--- linux-2.6.12-rc5_omap1/arch/arm/mach-omap/omap1/Kconfig 2005-08-23 22:36:31.495563275 +0300
++++ linux-2.6.12-rc5_omap1_h6300/arch/arm/mach-omap/omap1/Kconfig 2005-08-23 22:38:07.515278850 +0300
+@@ -26,6 +26,12 @@
+ TI OMAP 1510 or 1610 Innovator board support. Say Y here if you
+ have such a board.
+
++config MACH_H6300
++ bool "HP IPaq H6300"
++ depends on ARCH_OMAP1 && ARCH_OMAP1510
++ help
++ HP IPaq H6300 series
++
+ config MACH_OMAP_H2
+ bool "TI H2 Support"
+ depends on ARCH_OMAP1 && ARCH_OMAP16XX
+diff -Naur linux-2.6.12-rc5_omap1/arch/arm/mach-omap/omap1/Makefile linux-2.6.12-rc5_omap1_h6300/arch/arm/mach-omap/omap1/Makefile
+--- linux-2.6.12-rc5_omap1/arch/arm/mach-omap/omap1/Makefile 2005-08-23 22:36:31.564552293 +0300
++++ linux-2.6.12-rc5_omap1_h6300/arch/arm/mach-omap/omap1/Makefile 2005-08-23 22:38:07.516278691 +0300
+@@ -9,6 +9,7 @@
+ # Specific board support
+ obj-$(CONFIG_MACH_OMAP_H2) += board-h2.o
+ obj-$(CONFIG_MACH_OMAP_INNOVATOR) += board-innovator.o
++obj-$(CONFIG_MACH_H6300) += board-h6300.o
+ obj-$(CONFIG_MACH_OMAP_GENERIC) += board-generic.o
+ obj-$(CONFIG_MACH_OMAP_PERSEUS2) += board-perseus2.o
+ obj-$(CONFIG_MACH_OMAP_OSK) += board-osk.o
+diff -Naur linux-2.6.12-rc5_omap1/drivers/input/touchscreen/omap/Makefile linux-2.6.12-rc5_omap1_h6300/drivers/input/touchscreen/omap/Makefile
+--- linux-2.6.12-rc5_omap1/drivers/input/touchscreen/omap/Makefile 2005-08-23 22:36:32.554394729 +0300
++++ linux-2.6.12-rc5_omap1_h6300/drivers/input/touchscreen/omap/Makefile 2005-08-23 22:38:07.550273279 +0300
+@@ -8,5 +8,6 @@
+ objs-$(CONFIG_ARCH_OMAP16XX)$(CONFIG_MACH_OMAP_H3) += ts_hx.o
+ objs-$(CONFIG_ARCH_OMAP1510)$(CONFIG_MACH_OMAP_INNOVATOR) += ts_inn1510.o
+ objs-$(CONFIG_ARCH_OMAP16XX)$(CONFIG_MACH_OMAP_OSK) += ts_osk.o
++objs-$(CONFIG_ARCH_OMAP1510)$(CONFIG_MACH_H6300) += ts_hx.o
+
+ omapts-objs := omap_ts.o $(objs-yy)
+diff -Naur linux-2.6.12-rc5_omap1/drivers/input/touchscreen/omap/omap_ts.c linux-2.6.12-rc5_omap1_h6300/drivers/input/touchscreen/omap/omap_ts.c
+--- linux-2.6.12-rc5_omap1/drivers/input/touchscreen/omap/omap_ts.c 2005-08-23 22:36:32.555394570 +0300
++++ linux-2.6.12-rc5_omap1_h6300/drivers/input/touchscreen/omap/omap_ts.c 2005-08-23 22:38:07.551273120 +0300
+@@ -39,14 +39,14 @@
+
+ #include <asm/mach-types.h>
+
+-//#define DEBUG
++#define DEBUG
+
+ #include "omap_ts.h"
+
+ #define OMAP_TS_NAME "omap_ts"
+
+ static struct ts_device *__initdata ts_devs[] = {
+-#if defined(CONFIG_MACH_OMAP_H2) || defined(CONFIG_MACH_OMAP_H3)
++#if defined(CONFIG_MACH_OMAP_H2) || defined(CONFIG_MACH_OMAP_H3) || defined(CONFIG_MACH_H6300)
+ &hx_ts,
+ #endif
+ #ifdef CONFIG_MACH_OMAP_OSK
+@@ -70,8 +70,7 @@
+ input_report_abs(&(ts_omap.inputdevice), ABS_PRESSURE, data[2]);
+ input_sync(&(ts_omap.inputdevice));
+
+- DEBUG_TS("omap_ts_read: read x=%d,y=%d,p=%d\n", data[0], data[1],
+- data[2]);
++ //DEBUG_TS("omap_ts_read: read x=%d,y=%d,p=%d\n", data[0], data[1], data[2]);
+
+ return 0;
+ }
+@@ -84,7 +83,7 @@
+
+ if (!ts_omap.dev->penup()) {
+ if (!ts_omap.touched) {
+- DEBUG_TS("omap_ts_timer: pen down\n");
++ //DEBUG_TS("omap_ts_timer: pen down\n");
+ input_report_key(&(ts_omap.inputdevice), BTN_TOUCH, 1);
+ }
+ ts_omap.touched = 1;
+@@ -93,7 +92,7 @@
+ add_timer(&(ts_omap.ts_timer));
+ } else {
+ if (ts_omap.touched) {
+- DEBUG_TS("omap_ts_timer: pen up\n");
++ //DEBUG_TS("omap_ts_timer: pen up\n");
+ ts_omap.touched = 0;
+ input_report_abs(&(ts_omap.inputdevice), ABS_X, 0);
+ input_report_abs(&(ts_omap.inputdevice), ABS_Y, 0);
+diff -Naur linux-2.6.12-rc5_omap1/drivers/input/touchscreen/omap/ts_hx.c linux-2.6.12-rc5_omap1_h6300/drivers/input/touchscreen/omap/ts_hx.c
+--- linux-2.6.12-rc5_omap1/drivers/input/touchscreen/omap/ts_hx.c 2005-08-23 22:36:32.588389317 +0300
++++ linux-2.6.12-rc5_omap1_h6300/drivers/input/touchscreen/omap/ts_hx.c 2005-08-23 22:38:07.585267709 +0300
+@@ -33,6 +33,7 @@
+ #include <asm/arch/mux.h>
+ #include <asm/arch/hardware.h>
+ #include <asm/hardware/tsc2101.h>
++#include <linux/delay.h>
+
+ #include "../drivers/ssi/omap-tsc2101.h"
+ #include "omap_ts.h"
+@@ -88,6 +89,9 @@
+ } else if (machine_is_omap_h3()) {
+ gpio = H3_GPIO_NUM;
+ omap_cfg_reg(W19_1610_GPIO48);
++ }else if (machine_is_h6300()) {
++ gpio = 2;
++ omap_cfg_reg(M14_1510_GPIO2);
+ } else
+ return -ENODEV;
+
+@@ -180,5 +184,8 @@
+ omap_free_gpio(H2_GPIO_NUM);
+ else if (machine_is_omap_h3())
+ omap_free_gpio(H3_GPIO_NUM);
++ else if (machine_is_h6300())
++ omap_free_gpio(2);
++
+ }
+ #endif
+diff -Naur linux-2.6.12-rc5_omap1/drivers/ssi/omap-tsc2101.c linux-2.6.12-rc5_omap1_h6300/drivers/ssi/omap-tsc2101.c
+--- linux-2.6.12-rc5_omap1/drivers/ssi/omap-tsc2101.c 2005-08-23 22:36:33.800196420 +0300
++++ linux-2.6.12-rc5_omap1_h6300/drivers/ssi/omap-tsc2101.c 2005-08-23 22:38:07.586267550 +0300
+@@ -25,6 +25,7 @@
+ #include <linux/delay.h>
+
+ #include <asm/system.h>
++#include <asm/arch/gpio.h>
+ #include <asm/irq.h>
+ #include <asm/io.h>
+ #include <asm/mach-types.h>
+@@ -39,7 +40,7 @@
+
+ #include "omap-tsc2101.h"
+
+-#if CONFIG_ARCH_OMAP16XX
++#if CONFIG_ARCH_OMAP1
+ #include <../drivers/ssi/omap-uwire.h>
+ #else
+ #error "Unsupported configuration"
+@@ -47,7 +48,7 @@
+
+ #define SPIO 1
+
+-static int count;
++static int count = 0;
+ static spinlock_t tsc2101_lock = SPIN_LOCK_UNLOCKED;
+ static struct clk * tsc2101_mclk_ck;
+
+@@ -66,13 +67,12 @@
+ if (count++ == 0) {
+ int ret = 0;
+ /* set the Mux to provide MCLK to TSC2101 */
+- if (machine_is_omap_h3()) {
++ if (machine_is_omap_h3())
+ ret = omap_cfg_reg(V5_1710_MCLK_ON);
+- } else {
+- if (machine_is_omap_h2()) {
+- ret = omap_cfg_reg(R10_1610_MCLK_ON);
+- }
+- }
++ else if (machine_is_omap_h2())
++ ret = omap_cfg_reg(R10_1610_MCLK_ON);
++ else if (machine_is_h6300 ())
++ ret = omap_cfg_reg(R10_1610_MCLK_ON); // TODO: for now use the 1610 mux
+
+ /* Get the MCLK */
+ tsc2101_mclk_ck = clk_get(NULL, "mclk");
+@@ -108,19 +108,22 @@
+ if (--count == 0) {
+ int ret = 0;
+ /* Remove the Mux to Stop MCLK to TSC2101 */
+- if (machine_is_omap_h3()) {
++ if (machine_is_omap_h3())
+ ret = omap_cfg_reg(V5_1710_MCLK_OFF);
+- } else {
+- if (machine_is_omap_h2()) {
+- ret = omap_cfg_reg(R10_1610_MCLK_OFF);
+- }
+- }
++ else if (machine_is_omap_h2())
++ ret = omap_cfg_reg(R10_1610_MCLK_OFF);
++// else if (machine_is_h6300 ())
++// ret = omap_cfg_reg(R10_1610_MCLK_OFF); // TODO: for now use the 1610 mux
+
+ /* Release the MCLK */
+ clk_disable(tsc2101_mclk_ck);
+ clk_put(tsc2101_mclk_ck);
+ tsc2101_mclk_ck = NULL;
+
++#if defined(CONFIG_MACH_H6300)
++ omap_free_gpio(8);
++#endif
++
+ module_put(THIS_MODULE);
+ }
+ spin_unlock(&tsc2101_lock);
+@@ -130,57 +133,57 @@
+ {
+
+ int ret = 0;
++ int cs = 0;
+
+- if (machine_is_omap_h2()) {
+- ret =
+- omap_uwire_data_transfer(1,
+- (((page) << 11) | (address << 5)),
+- 16, 0, NULL, 1);
+- if (ret) {
+- printk(KERN_ERR
+- "uwire-write returned error for address %x\n",
+- address);
+- return;
+- }
+- ret = omap_uwire_data_transfer(1, data, 16, 0, NULL, 0);
+- if (ret) {
+- printk(KERN_ERR
+- "uwire-write returned error for address %x\n",
+- address);
+- return;
+- }
++ if (cpu_is_omap16xx ()) {
++ if (machine_is_omap_h2())
++ cs=1;
++ if (machine_is_omap_h3())
++ cs=0;
++ } else if (cpu_is_omap15xx ()) {
++ cs=0;
+ }
+- if (machine_is_omap_h3()) {
+
+- ret =
+- omap_uwire_data_transfer(0, ((page << 11) | (address << 5)),
+- 16, 0, NULL, 1);
+- if (ret) {
+- printk(KERN_ERR
+- "uwire-write returned error for address %x\n",
+- address);
+- return;
+- }
+- ret = omap_uwire_data_transfer(0, data, 16, 0, NULL, 0);
+- if (ret) {
+- printk(KERN_ERR
+- "uwire-write returned error for address %x\n",
+- address);
+- return;
+- }
++#if defined(CONFIG_MACH_H6300)
++ omap_set_gpio_dataout(8, 0);
++#endif
++
++ ret = omap_uwire_data_transfer(cs,
++ (((page) << 11) | (address << 5)),
++ 16, 0, NULL, 1);
++ if (ret) {
++ printk(KERN_ERR
++ "uwire-write returned error for address %x\n",
++ address);
++ omap_set_gpio_dataout(8, 1);
++ return;
++ }
++ ret = omap_uwire_data_transfer(cs, data, 16, 0, NULL, 0);
++ if (ret) {
++ printk(KERN_ERR
++ "uwire-write returned error for address %x\n",
++ address);
++ omap_set_gpio_dataout(8, 1);
++ return;
+ }
+
++#if defined(CONFIG_MACH_H6300)
++ omap_set_gpio_dataout(8, 1);
++#endif
+ }
+
+ void omap_tsc2101_reads(int page, u8 startaddress, u16 * data, int numregs)
+ {
+ int cs = 0, i;
+- if (machine_is_omap_h2()) {
++ if (machine_is_omap_h2())
+ cs = 1;
+- }
+- if (machine_is_omap_h3()) {
++ if (machine_is_omap_h3())
+ cs = 0;
+- }
++
++#if defined(CONFIG_MACH_H6300)
++ omap_set_gpio_dataout(8, 0);
++#endif
++
+ (void)omap_uwire_data_transfer(cs, (0x8000 | (page << 11)
+ | (startaddress << 5)),
+ 16, 0, NULL, 1);
+@@ -188,11 +191,15 @@
+ omap_uwire_data_transfer(cs, 0, 0, 16, data, 1);
+ }
+ omap_uwire_data_transfer(cs, 0, 0, 16, data, 0);
++
++#if defined(CONFIG_MACH_H6300)
++ omap_set_gpio_dataout(8, 1);
++#endif
+ }
+
+ u16 omap_tsc2101_read(int page, u8 address)
+ {
+- u16 ret;
++ u16 ret=0;
+ omap_tsc2101_reads(page, address, &ret, 1);
+ return ret;
+ }
+@@ -217,7 +224,6 @@
+ return err;
+ }
+ #endif
+-
+ if (machine_is_omap_h2()) {
+ uwire_flags = UWIRE_READ_RISING_EDGE | UWIRE_WRITE_RISING_EDGE;
+ omap_cfg_reg(N15_1610_UWIRE_CS1);
+@@ -228,9 +234,22 @@
+ omap_cfg_reg(N14_1610_UWIRE_CS0);
+ omap_uwire_configure_mode(0, uwire_flags);
+ }
++ if (machine_is_h6300()) {
++ uwire_flags = UWIRE_READ_RISING_EDGE | UWIRE_WRITE_RISING_EDGE;
++ omap_cfg_reg(X1_1510_UWIRE_CS0);
++ omap_uwire_configure_mode(0, uwire_flags);
++
++ omap_request_gpio(8);
++ omap_set_gpio_dataout(8, 0);
++ omap_set_gpio_direction (8, 0);
++ }
++
+
+ /* Configure MCLK enable */
+- omap_writel(omap_readl(PU_PD_SEL_2) | (1 << 22), PU_PD_SEL_2);
++ if (cpu_is_omap16xx ())
++ omap_writel(omap_readl(PU_PD_SEL_2) | (1 << 22), PU_PD_SEL_2);
++ if (machine_is_h6300())
++ omap_cfg_reg(X1_1510_UWIRE_SDI);
+
+ return 0;
+ }
+@@ -243,5 +262,5 @@
+
+ MODULE_AUTHOR("Texas Instruments");
+ MODULE_DESCRIPTION
+- ("Glue audio driver for the TI OMAP1610/OMAP1710 TSC2101 codec.");
++ ("Glue audio driver for the TI TSC2101 codec.");
+ MODULE_LICENSE("GPL");
+diff -Naur linux-2.6.12-rc5_omap1/drivers/ssi/omap-uwire.c linux-2.6.12-rc5_omap1_h6300/drivers/ssi/omap-uwire.c
+--- linux-2.6.12-rc5_omap1/drivers/ssi/omap-uwire.c 2005-08-23 22:36:33.827192123 +0300
++++ linux-2.6.12-rc5_omap1_h6300/drivers/ssi/omap-uwire.c 2005-08-23 22:38:07.586267550 +0300
+@@ -205,6 +205,11 @@
+ omap_cfg_reg(N14_1610_UWIRE_CS0);
+ omap_cfg_reg(N15_1610_UWIRE_CS1);
+ }
++
++ if (machine_is_h6300 ()) {
++ omap_cfg_reg(X1_1510_UWIRE_CS0);
++ omap_cfg_reg(X1_1510_UWIRE_CS3);
++ }
+ if (machine_is_omap_perseus2()) {
+ /* configure pins: MPU_UW_nSCS1, MPU_UW_SDO, MPU_UW_SCLK */
+ int val = omap_readl(OMAP730_IO_CONF_9) & ~0x00EEE000;
+diff -Naur linux-2.6.12-rc5_omap1/drivers/usb/gadget/omap_udc.c linux-2.6.12-rc5_omap1_h6300/drivers/usb/gadget/omap_udc.c
+--- linux-2.6.12-rc5_omap1/drivers/usb/gadget/omap_udc.c 2005-08-23 22:36:33.937174616 +0300
++++ linux-2.6.12-rc5_omap1_h6300/drivers/usb/gadget/omap_udc.c 2005-08-23 22:38:07.653256887 +0300
+@@ -2101,7 +2101,7 @@
+ /* boards that don't have VBUS sensing can't autogate 48MHz;
+ * can't enter deep sleep while a gadget driver is active.
+ */
+- if (machine_is_omap_innovator() || machine_is_omap_osk())
++ if (machine_is_omap_innovator() || machine_is_omap_osk() || machine_is_h6300())
+ omap_vbus_session(&udc->gadget, 1);
+
+ done:
+@@ -2119,7 +2119,7 @@
+ if (!driver || driver != udc->driver)
+ return -EINVAL;
+
+- if (machine_is_omap_innovator() || machine_is_omap_osk())
++ if (machine_is_omap_innovator() || machine_is_omap_osk() || machine_is_h6300())
+ omap_vbus_session(&udc->gadget, 0);
+
+ if (udc->transceiver)
+@@ -2727,7 +2727,7 @@
+ hmc = HMC_1510;
+ type = "(unknown)";
+
+- if (machine_is_omap_innovator()) {
++ if (machine_is_omap_innovator() || machine_is_h6300()) {
+ /* just set up software VBUS detect, and then
+ * later rig it so we always report VBUS.
+ * FIXME without really sensing VBUS, we can't
+@@ -2957,6 +2957,11 @@
+
+ static int __init udc_init(void)
+ {
++#ifdef USE_DMA
++ if (machine_is_h6300())
++ use_dma=0;
++#endif
++
+ INFO("%s, version: " DRIVER_VERSION
+ #ifdef USE_ISO
+ " (iso)"
+diff -Naur linux-2.6.12-rc5_omap1/drivers/usb/gadget/omap_udc.h linux-2.6.12-rc5_omap1_h6300/drivers/usb/gadget/omap_udc.h
+--- linux-2.6.12-rc5_omap1/drivers/usb/gadget/omap_udc.h 2005-08-23 22:36:33.939174298 +0300
++++ linux-2.6.12-rc5_omap1_h6300/drivers/usb/gadget/omap_udc.h 2005-08-23 22:37:10.616335999 +0300
+@@ -174,6 +174,7 @@
+ unsigned ep0_set_config:1;
+ unsigned ep0_reset_config:1;
+ unsigned ep0_setup:1;
++
+ struct completion *done;
+ };
+
+diff -Naur linux-2.6.12-rc5_omap1/drivers/video/omap/lcd_h6300.c linux-2.6.12-rc5_omap1_h6300/drivers/video/omap/lcd_h6300.c
+--- linux-2.6.12-rc5_omap1/drivers/video/omap/lcd_h6300.c 1970-01-01 02:00:00.000000000 +0200
++++ linux-2.6.12-rc5_omap1_h6300/drivers/video/omap/lcd_h6300.c 2005-08-23 22:38:07.655256568 +0300
+@@ -0,0 +1,90 @@
++/*
++ * File: drivers/video/omap_new/lcd-inn1510.c
++ *
++ * LCD panel support for the TI OMAP1510 Innovator board
++ *
++ * Copyright (C) 2004 Nokia Corporation
++ * Author: Imre Deak <imre.deak@nokia.com>
++ *
++ * This program is free software; you can redistribute it and/or modify it
++ * under the terms of the GNU General Public License as published by the
++ * Free Software Foundation; either version 2 of the License, or (at your
++ * option) any later version.
++ *
++ * This program is distributed in the hope that 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, write to the Free Software Foundation, Inc.,
++ * 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
++ */
++
++#include <linux/module.h>
++#include <asm/io.h>
++
++
++#include "omapfb.h"
++
++// #define OMAPFB_DBG 1
++
++#include "debug.h"
++
++static int h6300_panel_init(struct lcd_panel *panel)
++{
++ DBGENTER(1);
++ DBGLEAVE(1);
++ return 0;
++}
++
++static void h6300_panel_cleanup(struct lcd_panel *panel)
++{
++ DBGENTER(1);
++ DBGLEAVE(1);
++}
++
++static int h6300_panel_enable(struct lcd_panel *panel)
++{
++ DBGENTER(1);
++ DBGLEAVE(1);
++ return 0;
++}
++
++static void h6300_panel_disable(struct lcd_panel *panel)
++{
++ DBGENTER(1);
++ DBGLEAVE(1);
++}
++
++static unsigned long h6300_panel_get_caps(struct lcd_panel *panel)
++{
++ return 0;
++}
++
++static struct lcdc_video_mode mode240x320 = {
++ .x_res = 240,
++ .y_res = 320,
++ .pixel_clock = 12500,
++ .bpp = 16,
++ .hsw = 12,
++ .hfp = 10,
++ .hbp = 10,
++ .vsw = 3,
++ .vfp = 10,
++ .vbp = 3,
++ .pcd = 4,
++};
++
++struct lcd_panel h6300_panel = {
++ .name = "h6300",
++ .config = LCD_PANEL_TFT,
++ .video_mode = &mode240x320,
++
++ .init = h6300_panel_init,
++ .cleanup = h6300_panel_cleanup,
++ .enable = h6300_panel_enable,
++ .disable = h6300_panel_disable,
++ .get_caps= h6300_panel_get_caps,
++};
++
+diff -Naur linux-2.6.12-rc5_omap1/drivers/video/omap/Makefile linux-2.6.12-rc5_omap1_h6300/drivers/video/omap/Makefile
+--- linux-2.6.12-rc5_omap1/drivers/video/omap/Makefile 2005-08-23 22:36:34.395101723 +0300
++++ linux-2.6.12-rc5_omap1_h6300/drivers/video/omap/Makefile 2005-08-23 22:38:07.656256409 +0300
+@@ -11,6 +11,7 @@
+ objs-y$(CONFIG_MACH_OMAP_H2) += lcd_h2.o
+ objs-$(CONFIG_ARCH_OMAP16XX)$(CONFIG_MACH_OMAP_INNOVATOR) += lcd_inn1610.o
+ objs-$(CONFIG_ARCH_OMAP1510)$(CONFIG_MACH_OMAP_INNOVATOR) += lcd_inn1510.o
++objs-$(CONFIG_ARCH_OMAP1510)$(CONFIG_MACH_H6300) += lcd_h6300.o
+ objs-$(CONFIG_ARCH_OMAP16XX)$(CONFIG_MACH_OMAP_OSK) += lcd_osk.o
+ objs-$(CONFIG_ARCH_OMAP730)$(CONFIG_MACH_OMAP_PERSEUS2) += lcd_p2.o
+
+diff -Naur linux-2.6.12-rc5_omap1/drivers/video/omap/omapfb.h linux-2.6.12-rc5_omap1_h6300/drivers/video/omap/omapfb.h
+--- linux-2.6.12-rc5_omap1/drivers/video/omap/omapfb.h 2005-08-23 22:36:34.397101404 +0300
++++ linux-2.6.12-rc5_omap1_h6300/drivers/video/omap/omapfb.h 2005-08-23 22:38:07.688251316 +0300
+@@ -316,6 +316,7 @@
+ extern struct lcd_panel osk_panel;
+ extern struct lcd_panel innovator1610_panel;
+ extern struct lcd_panel innovator1510_panel;
++extern struct lcd_panel h6300_panel;
+
+ extern struct lcd_ctrl omapfb_lcdc_ctrl;
+
+diff -Naur linux-2.6.12-rc5_omap1/drivers/video/omap/omapfb_main.c linux-2.6.12-rc5_omap1_h6300/drivers/video/omap/omapfb_main.c
+--- linux-2.6.12-rc5_omap1/drivers/video/omap/omapfb_main.c 2005-08-23 22:36:34.472089467 +0300
++++ linux-2.6.12-rc5_omap1_h6300/drivers/video/omap/omapfb_main.c 2005-08-23 22:38:07.690250998 +0300
+@@ -108,6 +108,9 @@
+ &innovator1610_panel,
+ #endif
+ #endif
++#ifdef CONFIG_MACH_H6300
++ &h6300_panel,
++#endif
+ };
+
+ static struct lcd_ctrl *ctrls[] = {
+@@ -1881,6 +1884,8 @@
+ def_name = "inn1610";
+ if (machine_is_omap_innovator() && cpu_is_omap1510())
+ def_name = "inn1510";
++ if (machine_is_h6300())
++ def_name = "h6300";
+ if (def_name == NULL)
+ return -1;
+ strncpy(name, def_name, sizeof(name) - 1);
+diff -Naur linux-2.6.12-rc5_omap1/include/asm-arm/arch-omap/board-h6300.h linux-2.6.12-rc5_omap1_h6300/include/asm-arm/arch-omap/board-h6300.h
+--- linux-2.6.12-rc5_omap1/include/asm-arm/arch-omap/board-h6300.h 1970-01-01 02:00:00.000000000 +0200
++++ linux-2.6.12-rc5_omap1_h6300/include/asm-arm/arch-omap/board-h6300.h 2005-08-23 22:38:07.726245268 +0300
+@@ -0,0 +1,40 @@
++/*
++ * linux/include/asm-arm/arch-omap/board-innovator.h
++ *
++ * Copyright (C) 2001 RidgeRun, Inc.
++ *
++ * This program is free software; you can redistribute it and/or modify it
++ * under the terms of the GNU General Public License as published by the
++ * Free Software Foundation; either version 2 of the License, or (at your
++ * option) any later version.
++ *
++ * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESS OR IMPLIED
++ * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF
++ * MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN
++ * NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT,
++ * INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT
++ * NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
++ * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON
++ * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
++ * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF
++ * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
++ *
++ * You should have received a copy of the GNU General Public License along
++ * with this program; if not, write to the Free Software Foundation, Inc.,
++ * 675 Mass Ave, Cambridge, MA 02139, USA.
++ */
++#ifndef __ASM_ARCH_H6300_H
++#define __ASM_ARCH_H6300_H
++
++#ifndef OMAP_SDRAM_DEVICE
++#define OMAP_SDRAM_DEVICE D256M_1X16_4B
++#endif
++
++#define OMAP1510P1_IMIF_PRI_VALUE 0x00
++#define OMAP1510P1_EMIFS_PRI_VALUE 0x00
++#define OMAP1510P1_EMIFF_PRI_VALUE 0x00
++
++#define NR_FPGA_IRQS 24
++#define NR_IRQS IH_BOARD_BASE + NR_FPGA_IRQS
++
++#endif /* __ASM_ARCH_H6300_H */
+diff -Naur linux-2.6.12-rc5_omap1/include/asm-arm/arch-omap/hardware.h linux-2.6.12-rc5_omap1_h6300/include/asm-arm/arch-omap/hardware.h
+--- linux-2.6.12-rc5_omap1/include/asm-arm/arch-omap/hardware.h 2005-08-23 22:36:34.980008616 +0300
++++ linux-2.6.12-rc5_omap1_h6300/include/asm-arm/arch-omap/hardware.h 2005-08-23 22:38:07.727245109 +0300
+@@ -299,6 +299,10 @@
+ #include "board-innovator.h"
+ #endif
+
++#ifdef CONFIG_MACH_H6300
++#include "board-h6300.h"
++#endif
++
+ #ifdef CONFIG_MACH_OMAP_H2
+ #include "board-h2.h"
+ #endif
+diff -Naur linux-2.6.12-rc5_omap1/include/asm-arm/arch-omap/mux.h linux-2.6.12-rc5_omap1_h6300/include/asm-arm/arch-omap/mux.h
+--- linux-2.6.12-rc5_omap1/include/asm-arm/arch-omap/mux.h 2005-08-23 22:36:35.014003205 +0300
++++ linux-2.6.12-rc5_omap1_h6300/include/asm-arm/arch-omap/mux.h 2005-08-23 22:38:07.795234287 +0300
+@@ -250,9 +250,16 @@
+ U18_1610_UWIRE_SDI,
+ W21_1610_UWIRE_SDO,
+ N14_1610_UWIRE_CS0,
+- P15_1610_UWIRE_CS0,
++ P15_1610_UWIRE_CS3,
+ N15_1610_UWIRE_CS1,
+
++ /* OMAP-1510 uWire */
++ X1_1510_UWIRE_CS3,
++ X1_1510_UWIRE_CS0,
++ X1_1510_UWIRE_SCLK,
++ X1_1510_UWIRE_SDO,
++ X1_1510_UWIRE_SDI,
++
+ /* OMAP-1610 Flash */
+ L3_1610_FLASH_CS2B_OE,
+ M8_1610_FLASH_CS2B_WE,
+@@ -481,6 +488,13 @@
+ MUX_CFG("P15_1610_UWIRE_CS3", 8, 12, 1, 1, 22, 0, 1, 1, 1)
+ MUX_CFG("N15_1610_UWIRE_CS1", 7, 18, 2, 1, 14, 0, NA, 0, 1)
+
++/* OMAP-1510 uWire */
++MUX_CFG("X1_1510_UWIRE_CS3", 8, 12, 1, NA, 0, 0, NA, 0, 1)
++MUX_CFG("X1_1510_UWIRE_CS0", 8, 9, 1, NA, 0, 0, NA, 0, 1)
++MUX_CFG("X1_1510_UWIRE_SCLK", 8, 6, 0, NA, 0, 0, NA, 0, 1)
++MUX_CFG("X1_1510_UWIRE_SDO", 8, 3, 0, NA, 0, 0, NA, 0, 1)
++MUX_CFG("X1_1510_UWIRE_SDI", 8, 0, 0, 1, 18, 1, NA, 0, 1)
++
+ /* OMAP-1610 Flash */
+ MUX_CFG("L3_1610_FLASH_CS2B_OE",10, 6, 1, NA, 0, 0, NA, 0, 1)
+ MUX_CFG("M8_1610_FLASH_CS2B_WE",10, 3, 1, NA, 0, 0, NA, 0, 1)
+@@ -545,7 +559,8 @@
+ /* MCLK Settings */
+ MUX_CFG("V5_1710_MCLK_ON", B, 15, 0, NA, 0, 0, NA, 0, 0)
+ MUX_CFG("V5_1710_MCLK_OFF", B, 15, 6, NA, 0, 0, NA, 0, 0)
+-MUX_CFG("R10_1610_MCLK_ON", B, 18, 0, NA, 22, 0, NA, 1, 0)
++/* orig: MUX_CFG("R10_1610_MCLK_ON", B, 18, 0, NA, 22, 0, NA, 1, 0) */
++MUX_CFG("R10_1610_MCLK_ON", B, 18, 0, NA, 22, 0, NA, 1, 1)
+ MUX_CFG("R10_1610_MCLK_OFF", B, 18, 6, 2, 22, 1, 2, 1, 1)
+
+ /* CompactFlash controller, conflicts with MMC1 */
+diff -Naur linux-2.6.12-rc5_omap1/include/asm-arm/cpu-single.h linux-2.6.12-rc5_omap1_h6300/include/asm-arm/cpu-single.h
+--- linux-2.6.12-rc5_omap1/include/asm-arm/cpu-single.h 2005-05-25 06:31:20.000000000 +0300
++++ linux-2.6.12-rc5_omap1_h6300/include/asm-arm/cpu-single.h 2005-08-23 22:38:07.817230785 +0300
+@@ -41,4 +41,4 @@
+ extern void cpu_dcache_clean_area(void *, int);
+ extern void cpu_do_switch_mm(unsigned long pgd_phys, struct mm_struct *mm);
+ extern void cpu_set_pte(pte_t *ptep, pte_t pte);
+-extern volatile void cpu_reset(unsigned long addr);
++extern void cpu_reset(unsigned long addr);
+diff -Naur linux-2.6.12-rc5_omap1/Makefile linux-2.6.12-rc5_omap1_h6300/Makefile
+--- linux-2.6.12-rc5_omap1/Makefile 2005-08-23 22:36:35.409940179 +0300
++++ linux-2.6.12-rc5_omap1_h6300/Makefile 2005-08-23 22:38:07.818230626 +0300
+@@ -11,7 +11,7 @@
+ # expect to learn how to build the kernel reading this file.
+
+ # Add custom flags here to avoid conflict with updates
+-EXTRAVERSION := $(EXTRAVERSION)-omap2
++EXTRAVERSION := $(EXTRAVERSION)-omap1-h6300
+
+ # Do not print "Entering directory ..."
+ MAKEFLAGS += --no-print-directory
+diff -Naur linux-2.6.12-rc5_omap1/sound/oss/Kconfig linux-2.6.12-rc5_omap1_h6300/sound/oss/Kconfig
+--- linux-2.6.12-rc5_omap1/sound/oss/Kconfig 2005-08-23 22:36:35.439935405 +0300
++++ linux-2.6.12-rc5_omap1_h6300/sound/oss/Kconfig 2005-08-23 22:38:07.849225692 +0300
+@@ -12,7 +12,7 @@
+
+ config SOUND_OMAP_TSC2101
+ tristate "TSC2101 Stereo Codec"
+- depends on SOUND_OMAP && ( MACH_OMAP_H2 || MACH_OMAP_H3 )
++ depends on SOUND_OMAP && ARCH_OMAP1
+ select OMAP_TSC2101
+ select OMAP_UWIRE if ARCH_OMAP
+ ---help---
+diff -Naur linux-2.6.12-rc5_omap1/sound/oss/omap-audio.c linux-2.6.12-rc5_omap1_h6300/sound/oss/omap-audio.c
+--- linux-2.6.12-rc5_omap1/sound/oss/omap-audio.c 2005-08-23 22:36:35.498926014 +0300
++++ linux-2.6.12-rc5_omap1_h6300/sound/oss/omap-audio.c 2005-08-23 22:38:07.895218371 +0300
+@@ -56,8 +56,8 @@
+
+ /***************************** MACROS ************************************/
+
+-#undef DEBUG
+-//#define DEBUG
++//#undef DEBUG
++#define DEBUG
+ #ifdef DEBUG
+ #define DPRINTK printk
+ #define FN_IN printk("[omap_audio.c:[%s] start\n", __FUNCTION__)
+diff -Naur linux-2.6.12-rc5_omap1/sound/oss/omap-audio-tsc2101.c linux-2.6.12-rc5_omap1_h6300/sound/oss/omap-audio-tsc2101.c
+--- linux-2.6.12-rc5_omap1/sound/oss/omap-audio-tsc2101.c 2005-08-23 22:36:35.557916624 +0300
++++ linux-2.6.12-rc5_omap1_h6300/sound/oss/omap-audio-tsc2101.c 2005-08-23 22:38:07.897218053 +0300
+@@ -48,7 +48,7 @@
+ #include "omap-audio.h"
+ #include "omap-audio-dma-intfc.h"
+ #include <asm/arch/mcbsp.h>
+-#if CONFIG_ARCH_OMAP16XX
++#if CONFIG_ARCH_OMAP1
+ #include <../drivers/ssi/omap-uwire.h>
+ #include <asm/arch/dsp_common.h>
+ #else
+@@ -70,12 +70,14 @@
+
+ #define CODEC_NAME "TSC2101"
+
+-#if CONFIG_ARCH_OMAP16XX
+-#define PLATFORM_NAME "OMAP16XX"
++#if CONFIG_ARCH_OMAP1
++#define PLATFORM_NAME "OMAP"
+ #endif
+
+ #if CONFIG_ARCH_OMAP16XX
+ #define OMAP_DSP_BASE 0xE0000000
++#elif CONFIG_ARCH_OMAP1510
++#define OMAP_DSP_BASE 0xE0000000
+ #endif
+
+ /* Define to set the tsc as the master w.r.t McBSP */
+@@ -91,9 +93,15 @@
+
+ /* Select the McBSP For Audio */
+ #if CONFIG_ARCH_OMAP16XX
+-#define AUDIO_MCBSP OMAP_MCBSP1
++# define AUDIO_MCBSP OMAP_MCBSP1
++# define AUDIO_DMA_TX OMAP_DMA_MCBSP1_TX
++# define AUDIO_DMA_RX OMAP_DMA_MCBSP1_RX
++#elif CONFIG_ARCH_OMAP1510
++# define AUDIO_MCBSP OMAP_MCBSP1
++# define AUDIO_DMA_TX OMAP_DMA_MCBSP1_TX
++# define AUDIO_DMA_RX OMAP_DMA_MCBSP1_RX
+ #else
+-#error "UnSupported Configuration"
++# error "UnSupported Configuration"
+ #endif
+
+ #define REC_MASK (SOUND_MASK_LINE | SOUND_MASK_MIC)
+@@ -123,18 +131,18 @@
+
+ /*********** Debug Macros ********/
+ /* To Generate a rather shrill tone -test the entire path */
+-//#define TONE_GEN
++#define TONE_GEN
+ /* To Generate a tone for each keyclick - test the tsc,spi paths*/
+-//#define TEST_KEYCLICK
++#define TEST_KEYCLICK
+ /* To dump the tsc registers for debug */
+-//#define TSC_DUMP_REGISTERS
++#define TSC_DUMP_REGISTERS
+
+ #ifdef DPRINTK
+ #undef DPRINTK
+ #endif
+ #undef DEBUG
+
+-//#define DEBUG
++#define DEBUG
+ #ifdef DEBUG
+ #define DPRINTK(ARGS...) printk(KERN_INFO "<%s>: ",__FUNCTION__);printk(ARGS)
+ #define FN_IN printk(KERN_INFO "[%s]: start\n", __FUNCTION__)
+@@ -149,13 +157,13 @@
+
+ static audio_stream_t output_stream = {
+ .id = "TSC2101 out",
+- .dma_dev = OMAP_DMA_MCBSP1_TX,
++ .dma_dev = AUDIO_DMA_TX,
+ .input_or_output = FMODE_WRITE
+ };
+
+ static audio_stream_t input_stream = {
+ .id = "TSC2101 in",
+- .dma_dev = OMAP_DMA_MCBSP1_RX,
++ .dma_dev = AUDIO_DMA_RX,
+ .input_or_output = FMODE_READ
+ };
+
+@@ -215,6 +223,17 @@
+ };
+
+ static struct omap_mcbsp_reg_cfg initial_config = {
++#if CONFIG_MACH_H6300
++ .spcr2 = 0x0005,
++ .spcr1 = 0x0005,
++ .rcr2 = 0x8041,
++ .rcr1 = 0x8041,
++ .xcr2 = 0x00a1,
++ .xcr1 = 0x00a1,
++ .srgr2 = 0xb000,
++ .srgr1 = 0xb000,
++ .pcr0 = 0x0081,
++#else
+ .spcr2 = FREE | FRST | GRST | XRST | XINTM(3),
+ .spcr1 = RINTM(3) | RRST,
+ .rcr2 = RPHASE | RFRLEN2(OMAP_MCBSP_WORD_8) |
+@@ -230,14 +249,13 @@
+ #if CONFIG_MACH_OMAP_H2
+ .pcr0 = CLKXM | CLKRM | FSXP | FSRP | CLKXP | CLKRP,
+ #elif CONFIG_MACH_OMAP_H3
+-
+-#ifndef TSC_MASTER
++# ifndef TSC_MASTER
+ .pcr0 = FSXM | FSRM | CLKXM | CLKRM | CLKXP | CLKRP,
+-#else
++# else
+ .pcr0 = CLKRM | SCLKME | FSXP | FSRP | CLKXP | CLKRP,
+-#endif /* tsc Master defs */
+-
++# endif /* tsc Master defs */
+ #endif /* platform specific inits */
++#endif
+ };
+
+ /***************************** MODULES SPECIFIC FUNCTION PROTOTYPES ********************/
+@@ -1218,5 +1236,5 @@
+
+ MODULE_AUTHOR("Texas Instruments");
+ MODULE_DESCRIPTION
+- ("Glue audio driver for the TI OMAP1610/OMAP1710 TSC2101 codec.");
++ ("Glue audio driver for the TI OMAP TSC2101 codec.");
+ MODULE_LICENSE("GPL");