mirror of
https://git.yoctoproject.org/meta-ti
synced 2026-01-12 01:20:20 +00:00
TI BSP: add hawkboard support
Signed-off-by: Koen Kooi <koen@dominion.thruhere.net>
This commit is contained in:
29
conf/machine/hawkboard.conf
Normal file
29
conf/machine/hawkboard.conf
Normal file
@@ -0,0 +1,29 @@
|
||||
#@TYPE: Machine
|
||||
#@NAME: OMAP-L138 based board
|
||||
#@DESCRIPTION: Machine configuration for the TI Hawkboard
|
||||
|
||||
require conf/machine/include/davinci.inc
|
||||
require conf/machine/include/omapl138.inc
|
||||
|
||||
UBOOT_MACHINE = "da850_omapl138_evm_config"
|
||||
UBOOT_ENTRYPOINT = "0xc0008000"
|
||||
UBOOT_LOADADDRESS = "0xc0008000"
|
||||
|
||||
MACHINE_FEATURES = "kernel26 serial ethernet ide screen"
|
||||
|
||||
# do ubiattach /dev/ubi_ctrl -m 4
|
||||
# From dmesg:
|
||||
# UBI: smallest flash I/O unit: 2048
|
||||
# UBI: logical eraseblock size: 126976 bytes
|
||||
# from ubiattach stdout:
|
||||
# UBI device number 0, total 971 LEBs (123293696 bytes, 117.6 MiB), available 958 LEBs (121643008 bytes, 116.0 MiB), LEB size 126976 bytes (124.0 KiB)
|
||||
MKUBIFS_ARGS = "-m 2048 -e 126976 -c 948"
|
||||
|
||||
# do ubiattach /dev/ubi_ctrl -m 4
|
||||
# from dmesg:
|
||||
# UBI: smallest flash I/O unit: 2048
|
||||
# UBI: physical eraseblock size: 131072 bytes (128 KiB)
|
||||
# UBI: sub-page size: 512
|
||||
UBINIZE_ARGS = "-m 2048 -p 128KiB -s 512"
|
||||
|
||||
SERIAL_CONSOLE = "115200 ttyS2"
|
||||
@@ -0,0 +1,26 @@
|
||||
From b0a773f958b03ba77317f8b762d90d3c00269292 Mon Sep 17 00:00:00 2001
|
||||
From: Roger Monk <r-monk@ti.com>
|
||||
Date: Wed, 25 Aug 2010 16:45:46 +0100
|
||||
Subject: [PATCH] ahci-ti: Fix (currently harmless) typo in SATA PHY configuration
|
||||
|
||||
Signed-off-by: Roger Monk <r-monk@ti.com>
|
||||
---
|
||||
drivers/ata/ahci-ti.c | 2 +-
|
||||
1 files changed, 1 insertions(+), 1 deletions(-)
|
||||
|
||||
diff --git a/drivers/ata/ahci-ti.c b/drivers/ata/ahci-ti.c
|
||||
index 9e36c9d..674b216 100644
|
||||
--- a/drivers/ata/ahci-ti.c
|
||||
+++ b/drivers/ata/ahci-ti.c
|
||||
@@ -80,7 +80,7 @@ void ata_plat_init (void __iomem *base)
|
||||
phy_val = PHY_MPY << 0 | PHY_LB << 4 | PHY_LOS << 6 |
|
||||
PHY_RXINVPAIR << 7 | PHY_RXTERM << 8 |
|
||||
PHY_RXCDR << 10 | PHY_RXEQ << 13 |
|
||||
- PHY_RXINVPAIR << 17 | PHY_TXCM << 18 |
|
||||
+ PHY_TXINVPAIR << 17 | PHY_TXCM << 18 |
|
||||
PHY_TXSWING << 19 | PHY_TXDE << 22 |
|
||||
PHY_OVERRIDE << 30 | PHY_ENPLL << 31;
|
||||
|
||||
--
|
||||
1.6.0.4
|
||||
|
||||
@@ -0,0 +1,29 @@
|
||||
From 37a7868b15be9415abd3f57477afc8be956666e6 Mon Sep 17 00:00:00 2001
|
||||
From: Roger Monk <r-monk@ti.com>
|
||||
Date: Wed, 25 Aug 2010 16:46:28 +0100
|
||||
Subject: [PATCH] ahci-ti: Update SATA PHY configuration - RXCDR --> 4
|
||||
|
||||
* Update SATA PHY configuration for Receiver Clock/Data Recovery
|
||||
* Set to 0x4 = 2nd order, low precision
|
||||
|
||||
Signed-off-by: Roger Monk <r-monk@ti.com>
|
||||
---
|
||||
drivers/ata/ahci-ti.c | 2 +-
|
||||
1 files changed, 1 insertions(+), 1 deletions(-)
|
||||
|
||||
diff --git a/drivers/ata/ahci-ti.c b/drivers/ata/ahci-ti.c
|
||||
index 674b216..853d251 100644
|
||||
--- a/drivers/ata/ahci-ti.c
|
||||
+++ b/drivers/ata/ahci-ti.c
|
||||
@@ -55,7 +55,7 @@ void ata_plat_remove(struct ata_host *host);
|
||||
#define PHY_LOS 1 /* bit6 1 */
|
||||
#define PHY_RXINVPAIR 0 /* bit7 1 */
|
||||
#define PHY_RXTERM 0 /* bits9:8 2 */
|
||||
-#define PHY_RXCDR 0 /* bits12:10 3 */
|
||||
+#define PHY_RXCDR 4 /* bits12:10 3 */
|
||||
#define PHY_RXEQ 1 /* bits16:13 4 */
|
||||
#define PHY_TXINVPAIR 0 /* bit17 1 */
|
||||
#define PHY_TXCM 0 /* bit18 1 */
|
||||
--
|
||||
1.6.0.4
|
||||
|
||||
1857
recipes-bsp/linux/linux-davinci/dm355-evm/defconfig
Normal file
1857
recipes-bsp/linux/linux-davinci/dm355-evm/defconfig
Normal file
File diff suppressed because it is too large
Load Diff
@@ -0,0 +1,345 @@
|
||||
From a04a493ead5afb10aafe2c0cf57bf9e3bf7aa844 Mon Sep 17 00:00:00 2001
|
||||
From: Koen Kooi <koen@openembedded.org>
|
||||
Date: Thu, 12 Mar 2009 14:15:42 -0300
|
||||
Subject: [PATCH] dm355-leopard: add board file based on board-dm355-evm.c
|
||||
|
||||
---
|
||||
arch/arm/mach-davinci/Kconfig | 8 +
|
||||
arch/arm/mach-davinci/Makefile | 2 +
|
||||
arch/arm/mach-davinci/board-dm355-leopard.c | 295 +++++++++++++++++++++++++++
|
||||
3 files changed, 305 insertions(+), 0 deletions(-)
|
||||
create mode 100644 arch/arm/mach-davinci/board-dm355-leopard.c
|
||||
|
||||
diff --git a/arch/arm/mach-davinci/Kconfig b/arch/arm/mach-davinci/Kconfig
|
||||
index 0010f2d..85424b8 100644
|
||||
--- a/arch/arm/mach-davinci/Kconfig
|
||||
+++ b/arch/arm/mach-davinci/Kconfig
|
||||
@@ -50,6 +50,14 @@ config MACH_SFFSDR
|
||||
Say Y here to select the Lyrtech Small Form Factor
|
||||
Software Defined Radio (SFFSDR) board.
|
||||
|
||||
+config MACH_DM355_LEOPARD
|
||||
+ bool "TI DM355 Leopard board"
|
||||
+ default n
|
||||
+ depends on ARCH_DAVINCI_DM355
|
||||
+ help
|
||||
+ Configure this option to specify the whether the board used
|
||||
+ for development is a DM355 Leopard board.
|
||||
+
|
||||
config DAVINCI_MUX
|
||||
bool "DAVINCI multiplexing support"
|
||||
depends on ARCH_DAVINCI
|
||||
diff --git a/arch/arm/mach-davinci/Makefile b/arch/arm/mach-davinci/Makefile
|
||||
index 6783681..96ef484 100644
|
||||
--- a/arch/arm/mach-davinci/Makefile
|
||||
+++ b/arch/arm/mach-davinci/Makefile
|
||||
@@ -19,3 +19,5 @@ obj-$(CONFIG_MACH_DAVINCI_EVM) += board-dm644x-evm.o
|
||||
obj-$(CONFIG_MACH_DAVINCI_DM646X_EVM) += board-dm646x-evm.o
|
||||
obj-$(CONFIG_MACH_DAVINCI_DM355_EVM) += board-dm355-evm.o
|
||||
obj-$(CONFIG_MACH_SFFSDR) += board-sffsdr.o
|
||||
+obj-$(CONFIG_MACH_DM355_LEOPARD) += board-dm355-leopard.o
|
||||
+
|
||||
diff --git a/arch/arm/mach-davinci/board-dm355-leopard.c b/arch/arm/mach-davinci/board-dm355-leopard.c
|
||||
new file mode 100644
|
||||
index 0000000..a1e97e8
|
||||
--- /dev/null
|
||||
+++ b/arch/arm/mach-davinci/board-dm355-leopard.c
|
||||
@@ -0,0 +1,295 @@
|
||||
+/*
|
||||
+ * TI DM355 leopard board support
|
||||
+ *
|
||||
+ * Based on board-dm355-evm.c
|
||||
+ *
|
||||
+ * This file is licensed under the terms of the GNU General Public
|
||||
+ * License version 2. This program is licensed "as is" without any
|
||||
+ * warranty of any kind, whether express or implied.
|
||||
+ */
|
||||
+#include <linux/kernel.h>
|
||||
+#include <linux/module.h>
|
||||
+#include <linux/init.h>
|
||||
+#include <linux/dma-mapping.h>
|
||||
+#include <linux/platform_device.h>
|
||||
+#include <linux/mtd/mtd.h>
|
||||
+#include <linux/mtd/partitions.h>
|
||||
+#include <linux/mtd/nand.h>
|
||||
+#include <linux/i2c.h>
|
||||
+#include <linux/io.h>
|
||||
+#include <linux/gpio.h>
|
||||
+#include <linux/clk.h>
|
||||
+#include <linux/spi/spi.h>
|
||||
+#include <linux/spi/eeprom.h>
|
||||
+
|
||||
+#include <asm/setup.h>
|
||||
+#include <asm/mach-types.h>
|
||||
+#include <asm/mach/arch.h>
|
||||
+#include <asm/mach/map.h>
|
||||
+#include <asm/mach/flash.h>
|
||||
+
|
||||
+#include <mach/hardware.h>
|
||||
+#include <mach/dm355.h>
|
||||
+#include <mach/psc.h>
|
||||
+#include <mach/common.h>
|
||||
+#include <mach/emac.h>
|
||||
+#include <mach/i2c.h>
|
||||
+#include <mach/serial.h>
|
||||
+#include <mach/nand.h>
|
||||
+#include <mach/mmc.h>
|
||||
+
|
||||
+#define DAVINCI_ASYNC_EMIF_CONTROL_BASE 0x01e10000
|
||||
+#define DAVINCI_ASYNC_EMIF_DATA_CE0_BASE 0x02000000
|
||||
+
|
||||
+/* NOTE: this is geared for the standard config, with a socketed
|
||||
+ * 2 GByte Micron NAND (MT29F16G08FAA) using 128KB sectors. If you
|
||||
+ * swap chips, maybe with a different block size, partitioning may
|
||||
+ * need to be changed.
|
||||
+ */
|
||||
+#define NAND_BLOCK_SIZE SZ_128K
|
||||
+
|
||||
+static struct mtd_partition davinci_nand_partitions[] = {
|
||||
+ {
|
||||
+ /* UBL (a few copies) plus U-Boot */
|
||||
+ .name = "bootloader",
|
||||
+ .offset = 0,
|
||||
+ .size = 15 * NAND_BLOCK_SIZE,
|
||||
+ .mask_flags = MTD_WRITEABLE, /* force read-only */
|
||||
+ }, {
|
||||
+ /* U-Boot environment */
|
||||
+ .name = "params",
|
||||
+ .offset = MTDPART_OFS_APPEND,
|
||||
+ .size = 1 * NAND_BLOCK_SIZE,
|
||||
+ .mask_flags = 0,
|
||||
+ }, {
|
||||
+ .name = "kernel",
|
||||
+ .offset = MTDPART_OFS_APPEND,
|
||||
+ .size = SZ_4M,
|
||||
+ .mask_flags = 0,
|
||||
+ }, {
|
||||
+ .name = "filesystem1",
|
||||
+ .offset = MTDPART_OFS_APPEND,
|
||||
+ .size = SZ_512M,
|
||||
+ .mask_flags = 0,
|
||||
+ }, {
|
||||
+ .name = "filesystem2",
|
||||
+ .offset = MTDPART_OFS_APPEND,
|
||||
+ .size = MTDPART_SIZ_FULL,
|
||||
+ .mask_flags = 0,
|
||||
+ }
|
||||
+ /* two blocks with bad block table (and mirror) at the end */
|
||||
+};
|
||||
+
|
||||
+static struct davinci_nand_pdata davinci_nand_data = {
|
||||
+ .mask_chipsel = BIT(14),
|
||||
+ .parts = davinci_nand_partitions,
|
||||
+ .nr_parts = ARRAY_SIZE(davinci_nand_partitions),
|
||||
+ .ecc_mode = NAND_ECC_HW_SYNDROME,
|
||||
+ .options = NAND_USE_FLASH_BBT,
|
||||
+};
|
||||
+
|
||||
+static struct resource davinci_nand_resources[] = {
|
||||
+ {
|
||||
+ .start = DAVINCI_ASYNC_EMIF_DATA_CE0_BASE,
|
||||
+ .end = DAVINCI_ASYNC_EMIF_DATA_CE0_BASE + SZ_32M - 1,
|
||||
+ .flags = IORESOURCE_MEM,
|
||||
+ }, {
|
||||
+ .start = DAVINCI_ASYNC_EMIF_CONTROL_BASE,
|
||||
+ .end = DAVINCI_ASYNC_EMIF_CONTROL_BASE + SZ_4K - 1,
|
||||
+ .flags = IORESOURCE_MEM,
|
||||
+ },
|
||||
+};
|
||||
+
|
||||
+static struct platform_device davinci_nand_device = {
|
||||
+ .name = "davinci_nand",
|
||||
+ .id = 0,
|
||||
+
|
||||
+ .num_resources = ARRAY_SIZE(davinci_nand_resources),
|
||||
+ .resource = davinci_nand_resources,
|
||||
+
|
||||
+ .dev = {
|
||||
+ .platform_data = &davinci_nand_data,
|
||||
+ },
|
||||
+};
|
||||
+
|
||||
+static struct davinci_i2c_platform_data i2c_pdata = {
|
||||
+ .bus_freq = 400 /* kHz */,
|
||||
+ .bus_delay = 0 /* usec */,
|
||||
+};
|
||||
+
|
||||
+static int dm355leopard_mmc_gpios = -EINVAL;
|
||||
+
|
||||
+static void dm355leopard_mmcsd_gpios(unsigned gpio)
|
||||
+{
|
||||
+ gpio_request(gpio + 0, "mmc0_ro");
|
||||
+ gpio_request(gpio + 1, "mmc0_cd");
|
||||
+ gpio_request(gpio + 2, "mmc1_ro");
|
||||
+ gpio_request(gpio + 3, "mmc1_cd");
|
||||
+
|
||||
+ /* we "know" these are input-only so we don't
|
||||
+ * need to call gpio_direction_input()
|
||||
+ */
|
||||
+
|
||||
+ dm355leopard_mmc_gpios = gpio;
|
||||
+}
|
||||
+
|
||||
+static struct i2c_board_info dm355leopard_i2c_info[] = {
|
||||
+ { I2C_BOARD_INFO("dm355leopard_msp", 0x25),
|
||||
+ .platform_data = dm355leopard_mmcsd_gpios,
|
||||
+ /* plus irq */ },
|
||||
+ /* { I2C_BOARD_INFO("tlv320aic3x", 0x1b), }, */
|
||||
+ /* { I2C_BOARD_INFO("tvp5146", 0x5d), }, */
|
||||
+};
|
||||
+
|
||||
+static void __init leopard_init_i2c(void)
|
||||
+{
|
||||
+ davinci_init_i2c(&i2c_pdata);
|
||||
+
|
||||
+ gpio_request(5, "dm355leopard_msp");
|
||||
+ gpio_direction_input(5);
|
||||
+ dm355leopard_i2c_info[0].irq = gpio_to_irq(5);
|
||||
+
|
||||
+ i2c_register_board_info(1, dm355leopard_i2c_info,
|
||||
+ ARRAY_SIZE(dm355leopard_i2c_info));
|
||||
+}
|
||||
+
|
||||
+static struct resource dm355leopard_dm9000_rsrc[] = {
|
||||
+ {
|
||||
+ /* addr */
|
||||
+ .start = 0x04000000,
|
||||
+ .end = 0x04000001,
|
||||
+ .flags = IORESOURCE_MEM,
|
||||
+ }, {
|
||||
+ /* data */
|
||||
+ .start = 0x04000016,
|
||||
+ .end = 0x04000017,
|
||||
+ .flags = IORESOURCE_MEM,
|
||||
+ }, {
|
||||
+ .flags = IORESOURCE_IRQ
|
||||
+ | IORESOURCE_IRQ_HIGHEDGE /* rising (active high) */,
|
||||
+ },
|
||||
+};
|
||||
+
|
||||
+static struct platform_device dm355leopard_dm9000 = {
|
||||
+ .name = "dm9000",
|
||||
+ .id = -1,
|
||||
+ .resource = dm355leopard_dm9000_rsrc,
|
||||
+ .num_resources = ARRAY_SIZE(dm355leopard_dm9000_rsrc),
|
||||
+};
|
||||
+
|
||||
+static struct platform_device *davinci_leopard_devices[] __initdata = {
|
||||
+ &dm355leopard_dm9000,
|
||||
+ &davinci_nand_device,
|
||||
+};
|
||||
+
|
||||
+static struct davinci_uart_config uart_config __initdata = {
|
||||
+ .enabled_uarts = (1 << 0),
|
||||
+};
|
||||
+
|
||||
+static void __init dm355_leopard_map_io(void)
|
||||
+{
|
||||
+ davinci_map_common_io();
|
||||
+ dm355_init();
|
||||
+}
|
||||
+
|
||||
+static int dm355leopard_mmc_get_cd(int module)
|
||||
+{
|
||||
+ if (!gpio_is_valid(dm355leopard_mmc_gpios))
|
||||
+ return -ENXIO;
|
||||
+ /* low == card present */
|
||||
+ return !gpio_get_value_cansleep(dm355leopard_mmc_gpios + 2 * module + 1);
|
||||
+}
|
||||
+
|
||||
+static int dm355leopard_mmc_get_ro(int module)
|
||||
+{
|
||||
+ if (!gpio_is_valid(dm355leopard_mmc_gpios))
|
||||
+ return -ENXIO;
|
||||
+ /* high == card's write protect switch active */
|
||||
+ return gpio_get_value_cansleep(dm355leopard_mmc_gpios + 2 * module + 0);
|
||||
+}
|
||||
+
|
||||
+static struct davinci_mmc_config dm355leopard_mmc_config = {
|
||||
+ .get_cd = dm355leopard_mmc_get_cd,
|
||||
+ .get_ro = dm355leopard_mmc_get_ro,
|
||||
+ .wires = 4,
|
||||
+ .max_freq = 50000000,
|
||||
+ .caps = MMC_CAP_MMC_HIGHSPEED | MMC_CAP_SD_HIGHSPEED,
|
||||
+};
|
||||
+
|
||||
+/* Don't connect anything to J10 unless you're only using USB host
|
||||
+ * mode *and* have to do so with some kind of gender-bender. If
|
||||
+ * you have proper Mini-B or Mini-A cables (or Mini-A adapters)
|
||||
+ * the ID pin won't need any help.
|
||||
+ */
|
||||
+#ifdef CONFIG_USB_MUSB_PERIPHERAL
|
||||
+#define USB_ID_VALUE 0 /* ID pulled high; *should* float */
|
||||
+#else
|
||||
+#define USB_ID_VALUE 1 /* ID pulled low */
|
||||
+#endif
|
||||
+
|
||||
+static struct spi_eeprom at25640a = {
|
||||
+ .byte_len = SZ_64K / 8,
|
||||
+ .name = "at25640a",
|
||||
+ .page_size = 32,
|
||||
+ .flags = EE_ADDR2,
|
||||
+};
|
||||
+
|
||||
+static struct spi_board_info dm355_leopard_spi_info[] __initconst = {
|
||||
+ {
|
||||
+ .modalias = "at25",
|
||||
+ .platform_data = &at25640a,
|
||||
+ .max_speed_hz = 10 * 1000 * 1000, /* at 3v3 */
|
||||
+ .bus_num = 0,
|
||||
+ .chip_select = 0,
|
||||
+ .mode = SPI_MODE_0,
|
||||
+ },
|
||||
+};
|
||||
+
|
||||
+static __init void dm355_leopard_init(void)
|
||||
+{
|
||||
+ struct clk *aemif;
|
||||
+
|
||||
+ gpio_request(9, "dm9000");
|
||||
+ gpio_direction_input(9);
|
||||
+ dm355leopard_dm9000_rsrc[2].start = gpio_to_irq(9);
|
||||
+
|
||||
+ aemif = clk_get(&dm355leopard_dm9000.dev, "aemif");
|
||||
+ clk_enable(aemif);
|
||||
+ clk_put(aemif);
|
||||
+
|
||||
+ platform_add_devices(davinci_leopard_devices,
|
||||
+ ARRAY_SIZE(davinci_leopard_devices));
|
||||
+ leopard_init_i2c();
|
||||
+ davinci_serial_init(&uart_config);
|
||||
+
|
||||
+ /* NOTE: NAND flash timings set by the UBL are slower than
|
||||
+ * needed by MT29F16G08FAA chips ... EMIF.A1CR is 0x40400204
|
||||
+ * but could be 0x0400008c for about 25% faster page reads.
|
||||
+ */
|
||||
+
|
||||
+ gpio_request(2, "usb_id_toggle");
|
||||
+ gpio_direction_output(2, USB_ID_VALUE);
|
||||
+ /* irlml6401 switches over 1A in under 8 msec */
|
||||
+ setup_usb(500, 8);
|
||||
+
|
||||
+ davinci_setup_mmc(0, &dm355leopard_mmc_config);
|
||||
+ davinci_setup_mmc(1, &dm355leopard_mmc_config);
|
||||
+
|
||||
+ dm355_init_spi0(BIT(0), dm355_leopard_spi_info,
|
||||
+ ARRAY_SIZE(dm355_leopard_spi_info));
|
||||
+}
|
||||
+
|
||||
+static __init void dm355_leopard_irq_init(void)
|
||||
+{
|
||||
+ davinci_irq_init();
|
||||
+}
|
||||
+
|
||||
+MACHINE_START(DM355_LEOPARD, "DaVinci DM355 leopard")
|
||||
+ .phys_io = IO_PHYS,
|
||||
+ .io_pg_offst = (__IO_ADDRESS(IO_PHYS) >> 18) & 0xfffc,
|
||||
+ .boot_params = (0x80000100),
|
||||
+ .map_io = dm355_leopard_map_io,
|
||||
+ .init_irq = dm355_leopard_irq_init,
|
||||
+ .timer = &davinci_timer,
|
||||
+ .init_machine = dm355_leopard_init,
|
||||
+MACHINE_END
|
||||
--
|
||||
1.6.1.2
|
||||
|
||||
1798
recipes-bsp/linux/linux-davinci/dm355-leopard/defconfig
Normal file
1798
recipes-bsp/linux/linux-davinci/dm355-leopard/defconfig
Normal file
File diff suppressed because it is too large
Load Diff
143
recipes-bsp/linux/linux-davinci/dm355-leopard/vfpe.patch
Normal file
143
recipes-bsp/linux/linux-davinci/dm355-leopard/vfpe.patch
Normal file
@@ -0,0 +1,143 @@
|
||||
Subject:
|
||||
[PATCH 7/7] DM355 platform related changes for vpfe capture driver
|
||||
From:
|
||||
m-karicheri2-l0cyMroinI0@public.gmane.org
|
||||
Date:
|
||||
Fri, 13 Mar 2009 17:24:34 -0400
|
||||
To:
|
||||
davinci-linux-open-source-VycZQUHpC/PFrsHnngEfi1aTQe2KTcn/@public.gmane.org, davinci_opensource_ccb-uAqBSO/uNfhBDgjK7y7TUQ@public.gmane.org, psp_video-uAqBSO/uNfhBDgjK7y7TUQ@public.gmane.org
|
||||
Newsgroups:
|
||||
gmane.linux.davinci
|
||||
|
||||
Add platform related changes for vpfe capture driver on DM355
|
||||
|
||||
Signed-off-by: Murali Karicheri <m-karicheri2-l0cyMroinI0@public.gmane.org>
|
||||
---
|
||||
arch/arm/mach-davinci/board-dm355-leopard.c | 91 +++++++++++++++++++++++++++-
|
||||
|
||||
diff --git a/arch/arm/mach-davinci/board-dm355-leopard.c b/arch/arm/mach-davinci/board-dm355-leopard.c
|
||||
index e104650..aaa58ba 100644
|
||||
--- a/arch/arm/mach-davinci/board-dm355-leopard.c
|
||||
+++ b/arch/arm/mach-davinci/board-dm355-leopard.c
|
||||
@@ -20,6 +20,8 @@
|
||||
#include <linux/io.h>
|
||||
#include <linux/gpio.h>
|
||||
#include <linux/clk.h>
|
||||
+#include <media/v4l2-int-device.h>
|
||||
+#include <media/tvp514x.h>
|
||||
#include <linux/spi/spi.h>
|
||||
#include <linux/spi/eeprom.h>
|
||||
|
||||
@@ -134,12 +136,58 @@ static void dm355leopard_mmcsd_gpios(unsigned gpio)
|
||||
dm355leopard_mmc_gpios = gpio;
|
||||
}
|
||||
|
||||
+#define TVP5146_I2C_ADDR 0x5D
|
||||
+static struct v4l2_ifparm tvp5146_ifparm = {
|
||||
+ .if_type = V4L2_IF_TYPE_BT656,
|
||||
+ .u = {
|
||||
+ .bt656 = {
|
||||
+ .frame_start_on_rising_vs = 1,
|
||||
+ .bt_sync_correct = 0,
|
||||
+ .swap = 0,
|
||||
+ .latch_clk_inv = 0,
|
||||
+ .nobt_hs_inv = 0, /* active high */
|
||||
+ .nobt_vs_inv = 0, /* active high */
|
||||
+ .mode = V4L2_IF_TYPE_BT656_MODE_BT_8BIT,
|
||||
+ .clock_min = TVP514X_XCLK_BT656,
|
||||
+ .clock_max = TVP514X_XCLK_BT656,
|
||||
+ },
|
||||
+ },
|
||||
+};
|
||||
+
|
||||
+/**
|
||||
+ * @brief tvp5146_g_ifparm - Returns the TVP5146 decoder interface parameters
|
||||
+ *
|
||||
+ * @param p - pointer to v4l2_ifparm structure
|
||||
+ * @return result of operation - 0 is success
|
||||
+ */
|
||||
+static int tvp5146_g_ifparm(struct v4l2_ifparm *p)
|
||||
+{
|
||||
+ if (p == NULL)
|
||||
+ return -EINVAL;
|
||||
+
|
||||
+ *p = tvp5146_ifparm;
|
||||
+ return 0;
|
||||
+}
|
||||
+
|
||||
+#define TVP5146_NUM_INPUTS ARRAY_SIZE(tvp5146_input_list)
|
||||
+
|
||||
+static struct tvp514x_platform_data tvp5146_pdata = {
|
||||
+ .master = CAPTURE_DRV_NAME,
|
||||
+ .ifparm = tvp5146_g_ifparm,
|
||||
+ .hs_polarity = 1,
|
||||
+ .vs_polarity = 1
|
||||
+};
|
||||
+
|
||||
static struct i2c_board_info dm355leopard_i2c_info[] = {
|
||||
- { I2C_BOARD_INFO("dm355leopard_msp", 0x25),
|
||||
+ { I2C_BOARD_INFO("dm355leopard_msp", 0x25),
|
||||
.platform_data = dm355leopard_mmcsd_gpios,
|
||||
- /* plus irq */ },
|
||||
+ },
|
||||
+ {
|
||||
+ I2C_BOARD_INFO("tvp5146", TVP5146_I2C_ADDR),
|
||||
+ .platform_data = &tvp5146_pdata,
|
||||
+ },
|
||||
+ /* { plus irq }, */
|
||||
/* { I2C_BOARD_INFO("tlv320aic3x", 0x1b), }, */
|
||||
- /* { I2C_BOARD_INFO("tvp5146", 0x5d), }, */
|
||||
};
|
||||
|
||||
static void __init leopard_init_i2c(void)
|
||||
@@ -178,6 +226,41 @@ static struct platform_device dm355leopard_dm9000 = {
|
||||
.num_resources = ARRAY_SIZE(dm355leopard_dm9000_rsrc),
|
||||
};
|
||||
|
||||
+#define TVP514X_STD_ALL (V4L2_STD_NTSC | V4L2_STD_PAL)
|
||||
+
|
||||
+static struct vpfe_capture_input vpfe_capture_inputs = {
|
||||
+ .num_inputs = VPFE_MAX_DEC_INPUTS,
|
||||
+ .current_input = 0,
|
||||
+ .inputs[0] = {
|
||||
+ .dec_name = TVP514X_MODULE_NAME,
|
||||
+ .input = {
|
||||
+ .index = 0,
|
||||
+ .name = "COMPOSITE",
|
||||
+ .type = V4L2_INPUT_TYPE_CAMERA,
|
||||
+ .std = TVP514X_STD_ALL,
|
||||
+ },
|
||||
+ .route = {
|
||||
+ .input = INPUT_CVBS_VI2B,
|
||||
+ .output = OUTPUT_10BIT_422_EMBEDDED_SYNC,
|
||||
+ },
|
||||
+ .routing_supported = 1,
|
||||
+ },
|
||||
+ .inputs[1] = {
|
||||
+ .dec_name = TVP514X_MODULE_NAME,
|
||||
+ .input = {
|
||||
+ .index = 1,
|
||||
+ .name = "SVIDEO",
|
||||
+ .type = V4L2_INPUT_TYPE_CAMERA,
|
||||
+ .std = TVP514X_STD_ALL,
|
||||
+ },
|
||||
+ .route = {
|
||||
+ .input = INPUT_SVIDEO_VI2C_VI1C,
|
||||
+ .output = OUTPUT_10BIT_422_EMBEDDED_SYNC,
|
||||
+ },
|
||||
+ .routing_supported = 1,
|
||||
+ },
|
||||
+};
|
||||
+
|
||||
static struct platform_device *davinci_leopard_devices[] __initdata = {
|
||||
&dm355leopard_dm9000,
|
||||
&davinci_nand_device,
|
||||
@@ -190,6 +273,8 @@ static struct davinci_uart_config uart_config __initdata = {
|
||||
static void __init dm355_leopard_map_io(void)
|
||||
{
|
||||
davinci_map_common_io();
|
||||
+ /* setup input configuration for VPFE input devices */
|
||||
+ setup_vpfe_input_config(&vpfe_capture_inputs);
|
||||
dm355_init();
|
||||
}
|
||||
|
||||
1864
recipes-bsp/linux/linux-davinci/dm365-evm/defconfig
Normal file
1864
recipes-bsp/linux/linux-davinci/dm365-evm/defconfig
Normal file
File diff suppressed because it is too large
Load Diff
1711
recipes-bsp/linux/linux-davinci/dm6446-evm/defconfig
Normal file
1711
recipes-bsp/linux/linux-davinci/dm6446-evm/defconfig
Normal file
File diff suppressed because it is too large
Load Diff
1956
recipes-bsp/linux/linux-davinci/dm6467-evm/defconfig
Normal file
1956
recipes-bsp/linux/linux-davinci/dm6467-evm/defconfig
Normal file
File diff suppressed because it is too large
Load Diff
1953
recipes-bsp/linux/linux-davinci/dm6467t-evm/defconfig
Normal file
1953
recipes-bsp/linux/linux-davinci/dm6467t-evm/defconfig
Normal file
File diff suppressed because it is too large
Load Diff
@@ -0,0 +1,27 @@
|
||||
From 69600e5a42512204bc4eb83a3a459496b049107f Mon Sep 17 00:00:00 2001
|
||||
From: Roger Monk <r-monk@ti.com>
|
||||
Date: Wed, 25 Aug 2010 17:47:16 +0100
|
||||
Subject: [PATCH] board-da850-hawk: Disable NAND SUBPAGE
|
||||
|
||||
* This was causing issues with UBI
|
||||
* Solution/Workaround identified by Caglar Akyuz - now applied locally to board file
|
||||
---
|
||||
arch/arm/mach-davinci/board-da850-hawk.c | 2 +-
|
||||
1 files changed, 1 insertions(+), 1 deletions(-)
|
||||
|
||||
diff --git a/arch/arm/mach-davinci/board-da850-hawk.c b/arch/arm/mach-davinci/board-da850-hawk.c
|
||||
index 87ed017..bbfe32a 100644
|
||||
--- a/arch/arm/mach-davinci/board-da850-hawk.c
|
||||
+++ b/arch/arm/mach-davinci/board-da850-hawk.c
|
||||
@@ -118,7 +118,7 @@ static struct davinci_nand_pdata da850_hawk_nandflash_data = {
|
||||
.nr_parts = ARRAY_SIZE(da850_hawk_nandflash_partition),
|
||||
.ecc_mode = NAND_ECC_HW,
|
||||
.ecc_bits = 4,
|
||||
- .options = NAND_USE_FLASH_BBT,
|
||||
+ .options = NAND_USE_FLASH_BBT | NAND_NO_SUBPAGE_WRITE,
|
||||
.timing = &da850_hawk_nandflash_timing,
|
||||
};
|
||||
|
||||
--
|
||||
1.6.0.4
|
||||
|
||||
2630
recipes-bsp/linux/linux-davinci/hawkboard/defconfig
Normal file
2630
recipes-bsp/linux/linux-davinci/hawkboard/defconfig
Normal file
File diff suppressed because it is too large
Load Diff
51363
recipes-bsp/linux/linux-davinci/hawkboard/logo_linux_clut224.ppm
Normal file
51363
recipes-bsp/linux/linux-davinci/hawkboard/logo_linux_clut224.ppm
Normal file
File diff suppressed because it is too large
Load Diff
File diff suppressed because it is too large
Load Diff
File diff suppressed because it is too large
Load Diff
1803
recipes-bsp/linux/linux-davinci/omapl137/defconfig
Normal file
1803
recipes-bsp/linux/linux-davinci/omapl137/defconfig
Normal file
File diff suppressed because it is too large
Load Diff
@@ -0,0 +1,29 @@
|
||||
From 2ee9f2c655710d9e60a5a9b49871edc316e5363d Mon Sep 17 00:00:00 2001
|
||||
From: Roger Monk <r-monk@ti.com>
|
||||
Date: Wed, 25 Aug 2010 17:29:14 +0100
|
||||
Subject: [PATCH] board-da850-evm: Disable NAND SUBPAGE
|
||||
|
||||
* This was causing issues with UBI
|
||||
* Solution/Workaround identified by Caglar Akyuz - now applied locally to board file
|
||||
|
||||
Signed-off-by: Roger Monk <r-monk@ti.com>
|
||||
---
|
||||
arch/arm/mach-davinci/board-da850-evm.c | 2 +-
|
||||
1 files changed, 1 insertions(+), 1 deletions(-)
|
||||
|
||||
diff --git a/arch/arm/mach-davinci/board-da850-evm.c b/arch/arm/mach-davinci/board-da850-evm.c
|
||||
index cfed439..502b914 100755
|
||||
--- a/arch/arm/mach-davinci/board-da850-evm.c
|
||||
+++ b/arch/arm/mach-davinci/board-da850-evm.c
|
||||
@@ -187,7 +187,7 @@ static struct davinci_nand_pdata da850_evm_nandflash_data = {
|
||||
.nr_parts = ARRAY_SIZE(da850_evm_nandflash_partition),
|
||||
.ecc_mode = NAND_ECC_HW,
|
||||
.ecc_bits = 4,
|
||||
- .options = NAND_USE_FLASH_BBT,
|
||||
+ .options = NAND_USE_FLASH_BBT | NAND_NO_SUBPAGE_WRITE,
|
||||
.timing = &da850_evm_nandflash_timing,
|
||||
};
|
||||
|
||||
--
|
||||
1.6.0.4
|
||||
|
||||
@@ -0,0 +1,334 @@
|
||||
From: Melissa Watkins <m-watkins@ti.com>
|
||||
Date: Wed, 24 Nov 2010 02:59:34 -0600
|
||||
Subject: [PATCH 1/3] uio_pruss1: Core driver addition
|
||||
|
||||
This patch adds the uio_pru driver and updates the uio Makefile
|
||||
and Kconfig files to support this driver. The uio_pru driver provides
|
||||
a framework for handling the PRU in the user space and is responsible
|
||||
for the device setup and the primary interrupt handling.
|
||||
|
||||
Signed-off-by: Amit Chatterjee <amit.chatterjee@ti.com>
|
||||
Signed-off-by: Melissa Watkins <m-watkins@ti.com>
|
||||
---
|
||||
drivers/uio/Kconfig | 10 ++
|
||||
drivers/uio/Makefile | 1 +
|
||||
drivers/uio/uio_pru.c | 279 +++++++++++++++++++++++++++++++++++++++++++++++++
|
||||
3 files changed, 290 insertions(+), 0 deletions(-)
|
||||
create mode 100644 drivers/uio/uio_pru.c
|
||||
|
||||
diff --git a/drivers/uio/Kconfig b/drivers/uio/Kconfig
|
||||
index 8aa1955..8ae8280 100644
|
||||
--- a/drivers/uio/Kconfig
|
||||
+++ b/drivers/uio/Kconfig
|
||||
@@ -94,4 +94,14 @@ config UIO_PCI_GENERIC
|
||||
primarily, for virtualization scenarios.
|
||||
If you compile this as a module, it will be called uio_pci_generic.
|
||||
|
||||
+config UIO_PRUSS
|
||||
+ tristate "Texas Instruments PRUSS driver"
|
||||
+ depends on ARCH_DAVINCI_DA850
|
||||
+ default n
|
||||
+ help
|
||||
+ PRUSS driver for OMAPL13X/DA8XX/AM17XX/AM18XX devices
|
||||
+ PRUSS driver requires user space components
|
||||
+ To compile this driver as a module, choose M here: the module
|
||||
+ will be called uio_pruss.
|
||||
+
|
||||
endif
|
||||
diff --git a/drivers/uio/Makefile b/drivers/uio/Makefile
|
||||
index 73b2e75..e6d8adb 100644
|
||||
--- a/drivers/uio/Makefile
|
||||
+++ b/drivers/uio/Makefile
|
||||
@@ -6,3 +6,4 @@ obj-$(CONFIG_UIO_SMX) += uio_smx.o
|
||||
obj-$(CONFIG_UIO_AEC) += uio_aec.o
|
||||
obj-$(CONFIG_UIO_SERCOS3) += uio_sercos3.o
|
||||
obj-$(CONFIG_UIO_PCI_GENERIC) += uio_pci_generic.o
|
||||
+obj-$(CONFIG_UIO_PRUSS) += uio_pru.o
|
||||
diff --git a/drivers/uio/uio_pru.c b/drivers/uio/uio_pru.c
|
||||
new file mode 100644
|
||||
index 0000000..82dc35e
|
||||
--- /dev/null
|
||||
+++ b/drivers/uio/uio_pru.c
|
||||
@@ -0,0 +1,279 @@
|
||||
+/*
|
||||
+ * UIO TI Programmable Real-Time Unit (PRU) driver.
|
||||
+ *
|
||||
+ * (C) 2010 Amit Chatterjee <amit.chatterjee@ti.com>
|
||||
+ *
|
||||
+ * Copyright (C) {YEAR} Texas Instruments Incorporated - http://www.ti.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 version 2.
|
||||
+ *
|
||||
+ * This program is distributed .as is. WITHOUT ANY WARRANTY of any
|
||||
+ * kind, whether express or implied; without even the implied warranty
|
||||
+ * of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
+ * GNU General Public License for more details.
|
||||
+ */
|
||||
+
|
||||
+#include <linux/device.h>
|
||||
+#include <linux/module.h>
|
||||
+#include <linux/platform_device.h>
|
||||
+#include <linux/uio_driver.h>
|
||||
+#include <linux/io.h>
|
||||
+#include <linux/clk.h>
|
||||
+#include <linux/dma-mapping.h>
|
||||
+
|
||||
+#define DRV_NAME "pruss"
|
||||
+#define DRV_VERSION "0.01"
|
||||
+
|
||||
+/*
|
||||
+0x01C30000 - 0x01C301FF Data RAM 0
|
||||
+0x01C30200 - 0x01C31FFF Reserved
|
||||
+0x01C32000 - 0x01C321FF Data RAM 1
|
||||
+0x01C32200 - 0x01C33FFF Reserved
|
||||
+0x01C34000 - 0x01C36FFF INTC Registers
|
||||
+0x01C37000 - 0x01C373FF PRU0 Control Registers
|
||||
+0x01C37400 - 0x01C377FF PRU0 Debug Registers
|
||||
+0x01C37800 - 0x01C37BFF PRU1 Control Registers
|
||||
+0x01C37C00 - 0x01C37FFF PRU1 Debug Registers
|
||||
+0x01C38000 - 0x01C38FFF PRU0 Instruction RAM
|
||||
+0x01C39000 - 0x01C3BFFF Reserved
|
||||
+0x01C3C000 - 0x01C3CFFF PRU1 Instruction RAM
|
||||
+0x01C3D000 - 0x01C3FFFF Reserved
|
||||
+*/
|
||||
+/*
|
||||
+ * 3 PRU_EVTOUT0 PRUSS Interrupt
|
||||
+ * 4 PRU_EVTOUT1 PRUSS Interrupt
|
||||
+ * 5 PRU_EVTOUT2 PRUSS Interrupt
|
||||
+ * 6 PRU_EVTOUT3 PRUSS Interrupt
|
||||
+ * 7 PRU_EVTOUT4 PRUSS Interrupt
|
||||
+ * 8 PRU_EVTOUT5 PRUSS Interrupt
|
||||
+ * 9 PRU_EVTOUT6 PRUSS Interrupt
|
||||
+ * 10 PRU_EVTOUT7 PRUSS Interrupt
|
||||
+*/
|
||||
+
|
||||
+#define PRUSS_INSTANCE (8)
|
||||
+
|
||||
+static struct clk *pruss_clk = NULL, *ecap0_clk = NULL;
|
||||
+static struct uio_info *info[PRUSS_INSTANCE];
|
||||
+static void *ddr_virt_addr;
|
||||
+static dma_addr_t ddr_phy_addr;
|
||||
+
|
||||
+
|
||||
+
|
||||
+static irqreturn_t pruss_handler(int irq, struct uio_info *dev_info)
|
||||
+{
|
||||
+ return IRQ_HANDLED;
|
||||
+}
|
||||
+
|
||||
+static int __devinit pruss_probe(struct platform_device *dev)
|
||||
+{
|
||||
+ int ret = -ENODEV;
|
||||
+ int count = 0;
|
||||
+ struct resource *regs_pruram, *regs_l3ram, *regs_ddr;
|
||||
+ char *string;
|
||||
+
|
||||
+ /* Power on PRU in case its not done as part of boot-loader */
|
||||
+ pruss_clk = clk_get(&dev->dev, "pruss");
|
||||
+ if (IS_ERR(pruss_clk)) {
|
||||
+ dev_err(&dev->dev, "no pruss clock available\n");
|
||||
+ ret = PTR_ERR(pruss_clk);
|
||||
+ pruss_clk = NULL;
|
||||
+ return ret;
|
||||
+ } else {
|
||||
+ clk_enable (pruss_clk);
|
||||
+ }
|
||||
+
|
||||
+ ecap0_clk = clk_get(&dev->dev, "ecap0");
|
||||
+ if (IS_ERR(ecap0_clk)) {
|
||||
+ dev_err(&dev->dev, "no ecap0 clock available\n");
|
||||
+ ret = PTR_ERR(ecap0_clk);
|
||||
+ ecap0_clk = NULL;
|
||||
+ return ret;
|
||||
+ } else {
|
||||
+ clk_enable(ecap0_clk);
|
||||
+ }
|
||||
+
|
||||
+
|
||||
+
|
||||
+ for (count = 0; count < PRUSS_INSTANCE; count++) {
|
||||
+ info[count] = (struct uio_info *)kzalloc(sizeof(struct uio_info), GFP_KERNEL);
|
||||
+ if (!info[count])
|
||||
+ return -ENOMEM;
|
||||
+
|
||||
+ }
|
||||
+
|
||||
+ regs_pruram = platform_get_resource(dev, IORESOURCE_MEM, 0);
|
||||
+ if (!regs_pruram) {
|
||||
+ dev_err(&dev->dev, "No memory resource specified\n");
|
||||
+ goto out_free;
|
||||
+ }
|
||||
+
|
||||
+ regs_l3ram = platform_get_resource(dev, IORESOURCE_MEM, 1);
|
||||
+ if (!regs_l3ram) {
|
||||
+ dev_err(&dev->dev, "No memory resource specified\n");
|
||||
+ goto out_free;
|
||||
+ }
|
||||
+
|
||||
+ regs_ddr = platform_get_resource(dev, IORESOURCE_MEM, 2);
|
||||
+ if (!regs_ddr) {
|
||||
+ dev_err(&dev->dev, "No memory resource specified\n");
|
||||
+ goto out_free;
|
||||
+ }
|
||||
+ ddr_virt_addr = dma_alloc_coherent(&dev->dev, regs_ddr->end-regs_ddr->start+1, &ddr_phy_addr, GFP_KERNEL|GFP_DMA);
|
||||
+
|
||||
+
|
||||
+ for (count = 0; count < PRUSS_INSTANCE; count++) {
|
||||
+ info[count]->mem[0].addr = regs_pruram->start;
|
||||
+ if (!info[count]->mem[0].addr) {
|
||||
+ dev_err(&dev->dev, "Invalid memory resource\n");
|
||||
+ break;
|
||||
+ }
|
||||
+
|
||||
+ info[count]->mem[0].size = regs_pruram->end - regs_pruram->start + 1;
|
||||
+ info[count]->mem[0].internal_addr = ioremap(regs_pruram->start, info[count]->mem[0].size);
|
||||
+
|
||||
+ if (!info[count]->mem[0].internal_addr) {
|
||||
+ dev_err(&dev->dev, "Can't remap memory address range\n");
|
||||
+ break;
|
||||
+ }
|
||||
+ info[count]->mem[0].memtype = UIO_MEM_PHYS;
|
||||
+
|
||||
+
|
||||
+ info[count]->mem[1].addr = regs_l3ram->start;
|
||||
+ if (!info[count]->mem[1].addr) {
|
||||
+ dev_err(&dev->dev, "Invalid memory resource\n");
|
||||
+ break;
|
||||
+ }
|
||||
+
|
||||
+ info[count]->mem[1].size = regs_l3ram->end - regs_l3ram->start + 1;
|
||||
+ info[count]->mem[1].internal_addr = ioremap(regs_l3ram->start, info[count]->mem[1].size);
|
||||
+
|
||||
+ if (!info[count]->mem[1].internal_addr) {
|
||||
+ dev_err(&dev->dev, "Can't remap memory address range\n");
|
||||
+ break;
|
||||
+ }
|
||||
+ info[count]->mem[1].memtype = UIO_MEM_PHYS;
|
||||
+
|
||||
+
|
||||
+ info[count]->mem[2].size = regs_ddr->end - regs_ddr->start + 1;
|
||||
+ if (!(info[count]->mem[2].size-1)) {
|
||||
+ dev_err(&dev->dev, "Invalid memory resource\n");
|
||||
+ break;
|
||||
+ }
|
||||
+
|
||||
+
|
||||
+ info[count]->mem[2].internal_addr = ddr_virt_addr;
|
||||
+
|
||||
+ if (!info[count]->mem[2].internal_addr) {
|
||||
+ dev_err(&dev->dev, "Can't remap memory address range\n");
|
||||
+ break;
|
||||
+ }
|
||||
+ info[count]->mem[2].addr = ddr_phy_addr;
|
||||
+ info[count]->mem[2].memtype = UIO_MEM_PHYS;
|
||||
+
|
||||
+
|
||||
+ string = kzalloc(20, GFP_KERNEL);
|
||||
+ sprintf(string, "pruss_evt%d", count);
|
||||
+ info[count]->name = string;
|
||||
+ info[count]->version = "0.01";
|
||||
+
|
||||
+ /* Register PRUSS IRQ lines */
|
||||
+ info[count]->irq = IRQ_DA8XX_EVTOUT0+count;
|
||||
+
|
||||
+ info[count]->irq_flags = IRQF_SHARED;
|
||||
+ info[count]->handler = pruss_handler;
|
||||
+
|
||||
+ ret = uio_register_device(&dev->dev, info[count]);
|
||||
+
|
||||
+ if (ret < 0)
|
||||
+ break;
|
||||
+ }
|
||||
+
|
||||
+ platform_set_drvdata(dev, info);
|
||||
+
|
||||
+ if (ret < 0) {
|
||||
+ if (ddr_virt_addr)
|
||||
+ dma_free_coherent(&dev->dev, regs_ddr->end - regs_ddr->start + 1, ddr_virt_addr, ddr_phy_addr);
|
||||
+ while (count--) {
|
||||
+ uio_unregister_device(info[count]);
|
||||
+ if (info[count]->name)
|
||||
+ kfree(info[count]->name);
|
||||
+ iounmap(info[count]->mem[0].internal_addr);
|
||||
+ }
|
||||
+ } else {
|
||||
+ return 0;
|
||||
+ }
|
||||
+
|
||||
+out_free:
|
||||
+ for (count = 0; count < PRUSS_INSTANCE; count++) {
|
||||
+ if (info[count])
|
||||
+ kfree(info[count]);
|
||||
+ }
|
||||
+
|
||||
+ if (pruss_clk != NULL)
|
||||
+ clk_put(pruss_clk);
|
||||
+ if (ecap0_clk != NULL)
|
||||
+ clk_put(ecap0_clk);
|
||||
+
|
||||
+ return ret;
|
||||
+}
|
||||
+
|
||||
+static int __devexit pruss_remove(struct platform_device *dev)
|
||||
+{
|
||||
+ int count = 0;
|
||||
+ struct uio_info **info;
|
||||
+
|
||||
+ info = (struct uio_info **)platform_get_drvdata(dev);
|
||||
+
|
||||
+ for (count = 0; count < PRUSS_INSTANCE; count++) {
|
||||
+ uio_unregister_device(info[count]);
|
||||
+ if (info[count]->name)
|
||||
+ kfree(info[count]->name);
|
||||
+
|
||||
+ }
|
||||
+ iounmap(info[0]->mem[0].internal_addr);
|
||||
+ iounmap(info[0]->mem[1].internal_addr);
|
||||
+ if (ddr_virt_addr)
|
||||
+ dma_free_coherent(&dev->dev, info[0]->mem[2].size, info[0]->mem[2].internal_addr, info[0]->mem[2].addr);
|
||||
+
|
||||
+ for (count = 0; count < PRUSS_INSTANCE; count++) {
|
||||
+ if (info[count])
|
||||
+ kfree(info[count]);
|
||||
+ }
|
||||
+
|
||||
+ platform_set_drvdata(dev, NULL);
|
||||
+
|
||||
+ if (pruss_clk != NULL)
|
||||
+ clk_put(pruss_clk);
|
||||
+ if (ecap0_clk != NULL)
|
||||
+ clk_put(ecap0_clk);
|
||||
+
|
||||
+
|
||||
+ return 0;
|
||||
+}
|
||||
+
|
||||
+static struct platform_driver pruss_driver = {
|
||||
+ .probe = pruss_probe,
|
||||
+ .remove = __devexit_p(pruss_remove),
|
||||
+ .driver = {
|
||||
+ .name = DRV_NAME,
|
||||
+ .owner = THIS_MODULE,
|
||||
+ },
|
||||
+};
|
||||
+
|
||||
+static int __init pruss_init_module(void)
|
||||
+{
|
||||
+ return platform_driver_register(&pruss_driver);
|
||||
+}
|
||||
+module_init(pruss_init_module);
|
||||
+
|
||||
+static void __exit pruss_exit_module(void)
|
||||
+{
|
||||
+ platform_driver_unregister(&pruss_driver);
|
||||
+}
|
||||
+module_exit(pruss_exit_module);
|
||||
+
|
||||
+MODULE_LICENSE("GPL v2");
|
||||
+MODULE_VERSION(DRV_VERSION);
|
||||
+MODULE_AUTHOR("Amit Chatterjee <amit.chatterjee@ti.com>");
|
||||
--
|
||||
1.7.0.4
|
||||
|
||||
243
recipes-bsp/linux/linux-davinci/omapl138/0002-uio_pruss2-Platform-changes.patch
Executable file
243
recipes-bsp/linux/linux-davinci/omapl138/0002-uio_pruss2-Platform-changes.patch
Executable file
@@ -0,0 +1,243 @@
|
||||
From: Melissa Watkins <m-watkins@ti.com>
|
||||
Date: Wed, 24 Nov 2010 04:18:07 -0600
|
||||
Subject: [PATCH 2/3] uio_pruss2: Platform changes
|
||||
|
||||
Adding resources supporting the uio_pru driver within the
|
||||
da850 (omapl138) device.
|
||||
|
||||
Signed-off-by: Amit Chatterjee <amit.chatterjee@ti.com>
|
||||
Signed-off-by: Melissa Watkins <m-watkins@ti.com>
|
||||
---
|
||||
arch/arm/configs/da850_omapl138_defconfig | 8 +++-
|
||||
arch/arm/mach-davinci/board-da850-evm.c | 3 +
|
||||
arch/arm/mach-davinci/da850.c | 38 +++++++++++++-
|
||||
arch/arm/mach-davinci/devices-da8xx.c | 75 ++++++++++++++++++++++++++++
|
||||
arch/arm/mach-davinci/include/mach/da8xx.h | 3 +
|
||||
5 files changed, 124 insertions(+), 3 deletions(-)
|
||||
|
||||
diff --git a/arch/arm/configs/da850_omapl138_defconfig b/arch/arm/configs/da850_omapl138_defconfig
|
||||
index b312050..baebec8 100644
|
||||
--- a/arch/arm/configs/da850_omapl138_defconfig
|
||||
+++ b/arch/arm/configs/da850_omapl138_defconfig
|
||||
@@ -1361,6 +1361,7 @@ CONFIG_USB_MUSB_HDRC=y
|
||||
CONFIG_USB_MUSB_SOC=y
|
||||
CONFIG_USB_MUSB_HOST=y
|
||||
# CONFIG_USB_MUSB_PERIPHERAL is not set
|
||||
+# CONFIG_USB_MUSB_DUAL_ROLE is not set
|
||||
# CONFIG_USB_MUSB_OTG is not set
|
||||
CONFIG_USB_MUSB_HDRC_HCD=y
|
||||
# CONFIG_MUSB_PIO_ONLY is not set
|
||||
@@ -1535,7 +1536,12 @@ CONFIG_RTC_INTF_DEV=y
|
||||
CONFIG_RTC_DRV_OMAP=y
|
||||
# CONFIG_DMADEVICES is not set
|
||||
# CONFIG_AUXDISPLAY is not set
|
||||
-# CONFIG_UIO is not set
|
||||
+CONFIG_UIO=y
|
||||
+# CONFIG_UIO_PDRV is not set
|
||||
+# CONFIG_UIO_PDRV_GENIRQ is not set
|
||||
+# CONFIG_UIO_SMX is not set
|
||||
+# CONFIG_UIO_SERCOS3 is not set
|
||||
+CONFIG_UIO_PRUSS=m
|
||||
|
||||
#
|
||||
# TI VLYNQ
|
||||
diff --git a/arch/arm/mach-davinci/board-da850-evm.c b/arch/arm/mach-davinci/board-da850-evm.c
|
||||
index 009e9b5..1687c7c 100755
|
||||
--- a/arch/arm/mach-davinci/board-da850-evm.c
|
||||
+++ b/arch/arm/mach-davinci/board-da850-evm.c
|
||||
@@ -1070,6 +1070,9 @@ static __init void da850_evm_init(void)
|
||||
|
||||
platform_device_register(&da850_gpio_i2c);
|
||||
|
||||
+ /* Register PRUSS device */
|
||||
+ da8xx_register_pruss();
|
||||
+
|
||||
ret = da8xx_register_watchdog();
|
||||
if (ret)
|
||||
pr_warning("da830_evm_init: watchdog registration failed: %d\n",
|
||||
diff --git a/arch/arm/mach-davinci/da850.c b/arch/arm/mach-davinci/da850.c
|
||||
index 513ae85..8bd1919 100755
|
||||
--- a/arch/arm/mach-davinci/da850.c
|
||||
+++ b/arch/arm/mach-davinci/da850.c
|
||||
@@ -237,6 +237,13 @@ static struct clk tptc2_clk = {
|
||||
.flags = ALWAYS_ENABLED,
|
||||
};
|
||||
|
||||
+static struct clk pruss_clk = {
|
||||
+ .name = "pruss",
|
||||
+ .parent = &pll0_sysclk2,
|
||||
+ .lpsc = DA8XX_LPSC0_DMAX,
|
||||
+ .flags = ALWAYS_ENABLED,
|
||||
+};
|
||||
+
|
||||
static struct clk uart0_clk = {
|
||||
.name = "uart0",
|
||||
.parent = &pll0_sysclk2,
|
||||
@@ -385,13 +392,37 @@ static struct clk usb20_clk = {
|
||||
.gpsc = 1,
|
||||
};
|
||||
|
||||
-
|
||||
static struct clk sata_clk = {
|
||||
.name = "ahci",
|
||||
.parent = &pll0_sysclk2,
|
||||
.lpsc = DA850_LPSC1_SATA,
|
||||
.gpsc = 1,
|
||||
};
|
||||
+
|
||||
+static struct clk ecap0_clk = {
|
||||
+ .name = "ecap0",
|
||||
+ .parent = &pll0_sysclk2,
|
||||
+ .lpsc = DA8XX_LPSC1_ECAP,
|
||||
+ .flags = DA850_CLK_ASYNC3,
|
||||
+ .gpsc = 1,
|
||||
+};
|
||||
+
|
||||
+static struct clk ecap1_clk = {
|
||||
+ .name = "ecap1",
|
||||
+ .parent = &pll0_sysclk2,
|
||||
+ .lpsc = DA8XX_LPSC1_ECAP,
|
||||
+ .flags = DA850_CLK_ASYNC3,
|
||||
+ .gpsc = 1,
|
||||
+};
|
||||
+
|
||||
+static struct clk ecap2_clk = {
|
||||
+ .name = "ecap2",
|
||||
+ .parent = &pll0_sysclk2,
|
||||
+ .lpsc = DA8XX_LPSC1_ECAP,
|
||||
+ .flags = DA850_CLK_ASYNC3,
|
||||
+ .gpsc = 1,
|
||||
+};
|
||||
+
|
||||
static struct clk_lookup da850_clks[] = {
|
||||
CLK(NULL, "ref", &ref_clk),
|
||||
CLK(NULL, "pll0", &pll0_clk),
|
||||
@@ -419,6 +450,7 @@ static struct clk_lookup da850_clks[] = {
|
||||
CLK(NULL, "tptc1", &tptc1_clk),
|
||||
CLK(NULL, "tpcc1", &tpcc1_clk),
|
||||
CLK(NULL, "tptc2", &tptc2_clk),
|
||||
+ CLK(NULL, "pruss", &pruss_clk),
|
||||
CLK(NULL, "uart0", &uart0_clk),
|
||||
CLK(NULL, "uart1", &uart1_clk),
|
||||
CLK(NULL, "uart2", &uart2_clk),
|
||||
@@ -441,7 +473,9 @@ static struct clk_lookup da850_clks[] = {
|
||||
CLK(NULL, "usb11", &usb11_clk),
|
||||
CLK(NULL, "usb20", &usb20_clk),
|
||||
CLK(NULL, "ahci", &sata_clk),
|
||||
-
|
||||
+ CLK(NULL, "ecap0", &ecap0_clk),
|
||||
+ CLK(NULL, "ecap1", &ecap1_clk),
|
||||
+ CLK(NULL, "ecap2", &ecap2_clk),
|
||||
CLK(NULL, NULL, NULL),
|
||||
};
|
||||
|
||||
diff --git a/arch/arm/mach-davinci/devices-da8xx.c b/arch/arm/mach-davinci/devices-da8xx.c
|
||||
index 0842590..94979b3 100755
|
||||
--- a/arch/arm/mach-davinci/devices-da8xx.c
|
||||
+++ b/arch/arm/mach-davinci/devices-da8xx.c
|
||||
@@ -972,6 +972,81 @@ int __init da8xx_register_sata(void)
|
||||
return platform_device_register(&da850_ahci_device);
|
||||
}
|
||||
|
||||
+static struct resource pruss_resources[] = {
|
||||
+ [0] = {
|
||||
+ .start = DA8XX_PRUSS_BASE,
|
||||
+ .end = DA8XX_PRUSS_BASE + SZ_64K - 1,
|
||||
+ .flags = IORESOURCE_MEM,
|
||||
+ },
|
||||
+ [1] = {
|
||||
+ .start = DA8XX_L3RAM_BASE,
|
||||
+ .end = DA8XX_L3RAM_BASE + SZ_128K - 1,
|
||||
+ .flags = IORESOURCE_MEM,
|
||||
+ },
|
||||
+ [2] = {
|
||||
+ .start = 0,
|
||||
+ .end = SZ_256K - 1,
|
||||
+ .flags = IORESOURCE_MEM,
|
||||
+ },
|
||||
+
|
||||
+ [3] = {
|
||||
+ .start = IRQ_DA8XX_EVTOUT0,
|
||||
+ .end = IRQ_DA8XX_EVTOUT0,
|
||||
+ .flags = IORESOURCE_IRQ,
|
||||
+ },
|
||||
+ [4] = {
|
||||
+ .start = IRQ_DA8XX_EVTOUT1,
|
||||
+ .end = IRQ_DA8XX_EVTOUT1,
|
||||
+ .flags = IORESOURCE_IRQ,
|
||||
+ },
|
||||
+ [5] = {
|
||||
+ .start = IRQ_DA8XX_EVTOUT2,
|
||||
+ .end = IRQ_DA8XX_EVTOUT2,
|
||||
+ .flags = IORESOURCE_IRQ,
|
||||
+ },
|
||||
+ [6] = {
|
||||
+ .start = IRQ_DA8XX_EVTOUT3,
|
||||
+ .end = IRQ_DA8XX_EVTOUT3,
|
||||
+ .flags = IORESOURCE_IRQ,
|
||||
+ },
|
||||
+ [7] = {
|
||||
+ .start = IRQ_DA8XX_EVTOUT4,
|
||||
+ .end = IRQ_DA8XX_EVTOUT4,
|
||||
+ .flags = IORESOURCE_IRQ,
|
||||
+ },
|
||||
+ [8] = {
|
||||
+ .start = IRQ_DA8XX_EVTOUT5,
|
||||
+ .end = IRQ_DA8XX_EVTOUT5,
|
||||
+ .flags = IORESOURCE_IRQ,
|
||||
+ },
|
||||
+ [9] = {
|
||||
+ .start = IRQ_DA8XX_EVTOUT6,
|
||||
+ .end = IRQ_DA8XX_EVTOUT6,
|
||||
+ .flags = IORESOURCE_IRQ,
|
||||
+ },
|
||||
+ [10] = {
|
||||
+ .start = IRQ_DA8XX_EVTOUT7,
|
||||
+ .end = IRQ_DA8XX_EVTOUT7,
|
||||
+ .flags = IORESOURCE_IRQ,
|
||||
+ },
|
||||
+};
|
||||
+
|
||||
+static struct platform_device pruss_device = {
|
||||
+ .name = "pruss",
|
||||
+ .id = 0,
|
||||
+ .num_resources = ARRAY_SIZE(pruss_resources),
|
||||
+ .resource = pruss_resources,
|
||||
+ .dev = {
|
||||
+ .coherent_dma_mask = 0xffffffff,
|
||||
+ }
|
||||
+
|
||||
+};
|
||||
+
|
||||
+int __init da8xx_register_pruss()
|
||||
+{
|
||||
+ return platform_device_register(&pruss_device);
|
||||
+}
|
||||
+
|
||||
#define CFGCHIP2 DA8XX_SYSCFG0_VIRT(DA8XX_CFGCHIP2_REG)
|
||||
/*
|
||||
* Configure the USB PHY for DA8xx platforms.
|
||||
diff --git a/arch/arm/mach-davinci/include/mach/da8xx.h b/arch/arm/mach-davinci/include/mach/da8xx.h
|
||||
index f76433f..632d7e2 100755
|
||||
--- a/arch/arm/mach-davinci/include/mach/da8xx.h
|
||||
+++ b/arch/arm/mach-davinci/include/mach/da8xx.h
|
||||
@@ -75,6 +75,8 @@ extern void __iomem *da8xx_syscfg1_base;
|
||||
#define DA8XX_USB0_BASE 0x01e00000
|
||||
#define DA850_SATA_BASE 0x01E18000
|
||||
#define DA850_SATA_CLK_PWRDN 0x01E2C018
|
||||
+#define DA8XX_PRUSS_BASE 0x01C30000
|
||||
+#define DA8XX_L3RAM_BASE 0x80000000
|
||||
|
||||
#define PINMUX0 0x00
|
||||
#define PINMUX1 0x04
|
||||
@@ -162,6 +164,7 @@ int __init da850_register_vpif_capture(struct vpif_capture_config
|
||||
|
||||
int cppi41_init(void);
|
||||
int da8xx_register_sata(void);
|
||||
+int da8xx_register_pruss(void);
|
||||
|
||||
|
||||
extern struct platform_device da8xx_serial_device;
|
||||
--
|
||||
1.7.0.4
|
||||
|
||||
@@ -0,0 +1,45 @@
|
||||
From: Melissa Watkins <m-watkins@ti.com>
|
||||
Date: Wed, 24 Nov 2010 04:20:24 -0600
|
||||
Subject: [PATCH 3/3] uio_pruss3: Workarounds put into core code to support our devices
|
||||
|
||||
This patch modifies uio.c to support the uio_pruss driver. The UIO user space module relies on IO memory being mapped to user space. The IO map works fine for all mapped virtual addresses less than 0x80000000. However for the uio_pruss driver, the virtual address is on the higher side, so it fails. The fix added in this patch is mainly to check if the page map returned is correct.
|
||||
|
||||
Signed-off-by: Amit Chatterjee <amit.chatterjee@ti.com>
|
||||
Signed-off-by: Melissa Watkins <m-watkins@ti.com>
|
||||
---
|
||||
drivers/uio/uio.c | 9 +++++++--
|
||||
1 files changed, 7 insertions(+), 2 deletions(-)
|
||||
|
||||
diff --git a/drivers/uio/uio.c b/drivers/uio/uio.c
|
||||
index e941367..3241d26 100644
|
||||
--- a/drivers/uio/uio.c
|
||||
+++ b/drivers/uio/uio.c
|
||||
@@ -19,7 +19,6 @@
|
||||
#include <linux/device.h>
|
||||
#include <linux/mm.h>
|
||||
#include <linux/idr.h>
|
||||
-#include <linux/sched.h>
|
||||
#include <linux/string.h>
|
||||
#include <linux/kobject.h>
|
||||
#include <linux/uio_driver.h>
|
||||
@@ -615,7 +615,7 @@ static int uio_find_mem_index(struct vm_area_struct *vma)
|
||||
for (mi = 0; mi < MAX_UIO_MAPS; mi++) {
|
||||
if (idev->info->mem[mi].size == 0)
|
||||
return -1;
|
||||
- if (vma->vm_pgoff == mi)
|
||||
+ if ((idev->info->mem[mi].addr) >> PAGE_SHIFT == vma->vm_pgoff)
|
||||
return mi;
|
||||
}
|
||||
return -1;
|
||||
@@ -659,7 +664,7 @@ static int uio_vma_fault(struct vm_area_struct *vma, struct vm_fault *vmf)
|
||||
return 0;
|
||||
}
|
||||
|
||||
-static const struct vm_operations_struct uio_vm_ops = {
|
||||
+static struct vm_operations_struct uio_vm_ops = {
|
||||
.open = uio_vma_open,
|
||||
.close = uio_vma_close,
|
||||
.fault = uio_vma_fault,
|
||||
--
|
||||
1.7.0.4
|
||||
|
||||
File diff suppressed because it is too large
Load Diff
File diff suppressed because it is too large
Load Diff
File diff suppressed because it is too large
Load Diff
File diff suppressed because it is too large
Load Diff
File diff suppressed because it is too large
Load Diff
1951
recipes-bsp/linux/linux-davinci/omapl138/defconfig
Normal file
1951
recipes-bsp/linux/linux-davinci/omapl138/defconfig
Normal file
File diff suppressed because it is too large
Load Diff
21763
recipes-bsp/linux/linux-davinci/omapl138/logo_linux_clut224.ppm
Normal file
21763
recipes-bsp/linux/linux-davinci/omapl138/logo_linux_clut224.ppm
Normal file
File diff suppressed because it is too large
Load Diff
160
recipes-bsp/linux/linux-davinci/update-mach-types.patch
Normal file
160
recipes-bsp/linux/linux-davinci/update-mach-types.patch
Normal file
@@ -0,0 +1,160 @@
|
||||
--- /tmp/mach-types 2009-03-17 16:55:42.000000000 +0100
|
||||
+++ git/arch/arm/tools/mach-types 2009-03-17 16:56:28.000000000 +0100
|
||||
@@ -12,7 +12,7 @@
|
||||
#
|
||||
# http://www.arm.linux.org.uk/developer/machines/?action=new
|
||||
#
|
||||
-# Last update: Sun Nov 30 16:39:36 2008
|
||||
+# Last update: Tue Mar 17 15:56:28 2009
|
||||
#
|
||||
# machine_is_xxx CONFIG_xxxx MACH_TYPE_xxx number
|
||||
#
|
||||
@@ -1811,7 +1811,7 @@
|
||||
jade MACH_JADE JADE 1821
|
||||
ks8695_softplc MACH_KS8695_SOFTPLC KS8695_SOFTPLC 1822
|
||||
gprisc3 MACH_GPRISC3 GPRISC3 1823
|
||||
-stamp9260 MACH_STAMP9260 STAMP9260 1824
|
||||
+stamp9g20 MACH_STAMP9G20 STAMP9G20 1824
|
||||
smdk6430 MACH_SMDK6430 SMDK6430 1825
|
||||
smdkc100 MACH_SMDKC100 SMDKC100 1826
|
||||
tavorevb MACH_TAVOREVB TAVOREVB 1827
|
||||
@@ -1993,4 +1993,138 @@
|
||||
benzina MACH_BENZINA BENZINA 2003
|
||||
blaze MACH_BLAZE BLAZE 2004
|
||||
linkstation_ls_hgl MACH_LINKSTATION_LS_HGL LINKSTATION_LS_HGL 2005
|
||||
-htcvenus MACH_HTCVENUS HTCVENUS 2006
|
||||
+htckovsky MACH_HTCVENUS HTCVENUS 2006
|
||||
+sony_prs505 MACH_SONY_PRS505 SONY_PRS505 2007
|
||||
+hanlin_v3 MACH_HANLIN_V3 HANLIN_V3 2008
|
||||
+sapphira MACH_SAPPHIRA SAPPHIRA 2009
|
||||
+dack_sda_01 MACH_DACK_SDA_01 DACK_SDA_01 2010
|
||||
+armbox MACH_ARMBOX ARMBOX 2011
|
||||
+harris_rvp MACH_HARRIS_RVP HARRIS_RVP 2012
|
||||
+ribaldo MACH_RIBALDO RIBALDO 2013
|
||||
+agora MACH_AGORA AGORA 2014
|
||||
+omap3_mini MACH_OMAP3_MINI OMAP3_MINI 2015
|
||||
+a9sam6432_b MACH_A9SAM6432_B A9SAM6432_B 2016
|
||||
+usg2410 MACH_USG2410 USG2410 2017
|
||||
+pc72052_i10_revb MACH_PC72052_I10_REVB PC72052_I10_REVB 2018
|
||||
+mx35_exm32 MACH_MX35_EXM32 MX35_EXM32 2019
|
||||
+topas910 MACH_TOPAS910 TOPAS910 2020
|
||||
+hyena MACH_HYENA HYENA 2021
|
||||
+pospax MACH_POSPAX POSPAX 2022
|
||||
+hdl_gx MACH_HDL_GX HDL_GX 2023
|
||||
+ctera_4bay MACH_CTERA_4BAY CTERA_4BAY 2024
|
||||
+ctera_plug_c MACH_CTERA_PLUG_C CTERA_PLUG_C 2025
|
||||
+crwea_plug_i MACH_CRWEA_PLUG_I CRWEA_PLUG_I 2026
|
||||
+egauge2 MACH_EGAUGE2 EGAUGE2 2027
|
||||
+didj MACH_DIDJ DIDJ 2028
|
||||
+m_s3c2443 MACH_MEISTER MEISTER 2029
|
||||
+htcblackstone MACH_HTCBLACKSTONE HTCBLACKSTONE 2030
|
||||
+cpuat9g20 MACH_CPUAT9G20 CPUAT9G20 2031
|
||||
+smdk6440 MACH_SMDK6440 SMDK6440 2032
|
||||
+omap_35xx_mvp MACH_OMAP_35XX_MVP OMAP_35XX_MVP 2033
|
||||
+ctera_plug_i MACH_CTERA_PLUG_I CTERA_PLUG_I 2034
|
||||
+pvg610_100 MACH_PVG610 PVG610 2035
|
||||
+hprw6815 MACH_HPRW6815 HPRW6815 2036
|
||||
+omap3_oswald MACH_OMAP3_OSWALD OMAP3_OSWALD 2037
|
||||
+nas4220b MACH_NAS4220B NAS4220B 2038
|
||||
+htcraphael_cdma MACH_HTCRAPHAEL_CDMA HTCRAPHAEL_CDMA 2039
|
||||
+htcdiamond_cdma MACH_HTCDIAMOND_CDMA HTCDIAMOND_CDMA 2040
|
||||
+scaler MACH_SCALER SCALER 2041
|
||||
+zylonite2 MACH_ZYLONITE2 ZYLONITE2 2042
|
||||
+aspenite MACH_ASPENITE ASPENITE 2043
|
||||
+teton MACH_TETON TETON 2044
|
||||
+ttc_dkb MACH_TTC_DKB TTC_DKB 2045
|
||||
+bishop2 MACH_BISHOP2 BISHOP2 2046
|
||||
+ippv5 MACH_IPPV5 IPPV5 2047
|
||||
+farm926 MACH_FARM926 FARM926 2048
|
||||
+mmccpu MACH_MMCCPU MMCCPU 2049
|
||||
+sgmsfl MACH_SGMSFL SGMSFL 2050
|
||||
+tt8000 MACH_TT8000 TT8000 2051
|
||||
+zrn4300lp MACH_ZRN4300LP ZRN4300LP 2052
|
||||
+mptc MACH_MPTC MPTC 2053
|
||||
+h6051 MACH_H6051 H6051 2054
|
||||
+pvg610_101 MACH_PVG610_101 PVG610_101 2055
|
||||
+stamp9261_pc_evb MACH_STAMP9261_PC_EVB STAMP9261_PC_EVB 2056
|
||||
+pelco_odysseus MACH_PELCO_ODYSSEUS PELCO_ODYSSEUS 2057
|
||||
+tny_a9260 MACH_TNY_A9260 TNY_A9260 2058
|
||||
+tny_a9g20 MACH_TNY_A9G20 TNY_A9G20 2059
|
||||
+aesop_mp2530f MACH_AESOP_MP2530F AESOP_MP2530F 2060
|
||||
+dx900 MACH_DX900 DX900 2061
|
||||
+cpodc2 MACH_CPODC2 CPODC2 2062
|
||||
+tilt_8925 MACH_TILT_8925 TILT_8925 2063
|
||||
+davinci_dm357_evm MACH_DAVINCI_DM357_EVM DAVINCI_DM357_EVM 2064
|
||||
+swordfish MACH_SWORDFISH SWORDFISH 2065
|
||||
+corvus MACH_CORVUS CORVUS 2066
|
||||
+taurus MACH_TAURUS TAURUS 2067
|
||||
+axm MACH_AXM AXM 2068
|
||||
+axc MACH_AXC AXC 2069
|
||||
+baby MACH_BABY BABY 2070
|
||||
+mp200 MACH_MP200 MP200 2071
|
||||
+pcm043 MACH_PCM043 PCM043 2072
|
||||
+hanlin_v3c MACH_HANLIN_V3C HANLIN_V3C 2073
|
||||
+kbk9g20 MACH_KBK9G20 KBK9G20 2074
|
||||
+adsturbog5 MACH_ADSTURBOG5 ADSTURBOG5 2075
|
||||
+avenger_lite1 MACH_AVENGER_LITE1 AVENGER_LITE1 2076
|
||||
+suc82x MACH_SUC SUC 2077
|
||||
+at91sam7s256 MACH_AT91SAM7S256 AT91SAM7S256 2078
|
||||
+mendoza MACH_MENDOZA MENDOZA 2079
|
||||
+kira MACH_KIRA KIRA 2080
|
||||
+mx1hbm MACH_MX1HBM MX1HBM 2081
|
||||
+quatro43xx MACH_QUATRO43XX QUATRO43XX 2082
|
||||
+quatro4230 MACH_QUATRO4230 QUATRO4230 2083
|
||||
+nsb400 MACH_NSB400 NSB400 2084
|
||||
+drp255 MACH_DRP255 DRP255 2085
|
||||
+thoth MACH_THOTH THOTH 2086
|
||||
+firestone MACH_FIRESTONE FIRESTONE 2087
|
||||
+asusp750 MACH_ASUSP750 ASUSP750 2088
|
||||
+ctera_dl MACH_CTERA_DL CTERA_DL 2089
|
||||
+socr MACH_SOCR SOCR 2090
|
||||
+htcoxygen MACH_HTCOXYGEN HTCOXYGEN 2091
|
||||
+heroc MACH_HEROC HEROC 2092
|
||||
+zeno6800 MACH_ZENO6800 ZENO6800 2093
|
||||
+sc2mcs MACH_SC2MCS SC2MCS 2094
|
||||
+gene100 MACH_GENE100 GENE100 2095
|
||||
+as353x MACH_AS353X AS353X 2096
|
||||
+sheevaplug MACH_SHEEVAPLUG SHEEVAPLUG 2097
|
||||
+at91sam9g20 MACH_AT91SAM9G20 AT91SAM9G20 2098
|
||||
+mv88f6192gtw_fe MACH_MV88F6192GTW_FE MV88F6192GTW_FE 2099
|
||||
+cc9200 MACH_CC9200 CC9200 2100
|
||||
+sm9200 MACH_SM9200 SM9200 2101
|
||||
+tp9200 MACH_TP9200 TP9200 2102
|
||||
+snapperdv MACH_SNAPPERDV SNAPPERDV 2103
|
||||
+avengers_lite MACH_AVENGERS_LITE AVENGERS_LITE 2104
|
||||
+avengers_lite1 MACH_AVENGERS_LITE1 AVENGERS_LITE1 2105
|
||||
+omap3axon MACH_OMAP3AXON OMAP3AXON 2106
|
||||
+ma8xx MACH_MA8XX MA8XX 2107
|
||||
+mp201ek MACH_MP201EK MP201EK 2108
|
||||
+davinci_tux MACH_DAVINCI_TUX DAVINCI_TUX 2109
|
||||
+mpa1600 MACH_MPA1600 MPA1600 2110
|
||||
+pelco_troy MACH_PELCO_TROY PELCO_TROY 2111
|
||||
+nsb667 MACH_NSB667 NSB667 2112
|
||||
+rovers5_4mpix MACH_ROVERS5_4MPIX ROVERS5_4MPIX 2113
|
||||
+twocom MACH_TWOCOM TWOCOM 2114
|
||||
+ubisys_p9_rcu3r2 MACH_UBISYS_P9_RCU3R2 UBISYS_P9_RCU3R2 2115
|
||||
+hero_espresso MACH_HERO_ESPRESSO HERO_ESPRESSO 2116
|
||||
+afeusb MACH_AFEUSB AFEUSB 2117
|
||||
+t830 MACH_T830 T830 2118
|
||||
+spd8020_cc MACH_SPD8020_CC SPD8020_CC 2119
|
||||
+om_3d7k MACH_OM_3D7K OM_3D7K 2120
|
||||
+picocom2 MACH_PICOCOM2 PICOCOM2 2121
|
||||
+uwg4mx27 MACH_UWG4MX27 UWG4MX27 2122
|
||||
+uwg4mx31 MACH_UWG4MX31 UWG4MX31 2123
|
||||
+cherry MACH_CHERRY CHERRY 2124
|
||||
+mx51_babbage MACH_MX51_BABBAGE MX51_BABBAGE 2125
|
||||
+s3c2440turkiye MACH_S3C2440TURKIYE S3C2440TURKIYE 2126
|
||||
+tx37 MACH_TX37 TX37 2127
|
||||
+sbc2800_9g20 MACH_SBC2800_9G20 SBC2800_9G20 2128
|
||||
+benzglb MACH_BENZGLB BENZGLB 2129
|
||||
+benztd MACH_BENZTD BENZTD 2130
|
||||
+cartesio_plus MACH_CARTESIO_PLUS CARTESIO_PLUS 2131
|
||||
+solrad_g20 MACH_SOLRAD_G20 SOLRAD_G20 2132
|
||||
+mx27wallace MACH_MX27WALLACE MX27WALLACE 2133
|
||||
+fmzwebmodul MACH_FMZWEBMODUL FMZWEBMODUL 2134
|
||||
+rd78x00_masa MACH_RD78X00_MASA RD78X00_MASA 2135
|
||||
+smallogger MACH_SMALLOGGER SMALLOGGER 2136
|
||||
+ccw9p9215 MACH_CCW9P9215 CCW9P9215 2137
|
||||
+dm355_leopard MACH_DM355_LEOPARD DM355_LEOPARD 2138
|
||||
+ts219 MACH_TS219 TS219 2139
|
||||
+tny_a9263 MACH_TNY_A9263 TNY_A9263 2140
|
||||
3928
recipes-bsp/linux/linux-davinci/vfpe1.patch
Normal file
3928
recipes-bsp/linux/linux-davinci/vfpe1.patch
Normal file
File diff suppressed because it is too large
Load Diff
200
recipes-bsp/linux/linux-davinci/vfpe2.patch
Normal file
200
recipes-bsp/linux/linux-davinci/vfpe2.patch
Normal file
@@ -0,0 +1,200 @@
|
||||
Subject:
|
||||
[PATCH 2/7] interface for configuring CCDC and common ccdc types
|
||||
From:
|
||||
m-karicheri2-l0cyMroinI0@public.gmane.org
|
||||
Date:
|
||||
Fri, 13 Mar 2009 17:22:39 -0400
|
||||
To:
|
||||
davinci-linux-open-source-VycZQUHpC/PFrsHnngEfi1aTQe2KTcn/@public.gmane.org, davinci_opensource_ccb-uAqBSO/uNfhBDgjK7y7TUQ@public.gmane.org, psp_video-uAqBSO/uNfhBDgjK7y7TUQ@public.gmane.org
|
||||
Newsgroups:
|
||||
gmane.linux.davinci
|
||||
|
||||
Adding an interface for configuring ccdc as per data format of decoder
|
||||
output. Also adds a header file for common ccdc data types.
|
||||
|
||||
Signed-off-by: Murali Karicheri <m-karicheri2-l0cyMroinI0@public.gmane.org>
|
||||
---
|
||||
include/media/davinci/ccdc_common.h | 48 +++++++++++++
|
||||
include/media/davinci/ccdc_hw_device.h | 117 ++++++++++++++++++++++++++++++++
|
||||
2 files changed, 165 insertions(+), 0 deletions(-)
|
||||
create mode 100644 include/media/davinci/ccdc_common.h
|
||||
create mode 100644 include/media/davinci/ccdc_hw_device.h
|
||||
|
||||
diff --git a/include/media/davinci/ccdc_common.h b/include/media/davinci/ccdc_common.h
|
||||
new file mode 100644
|
||||
index 0000000..0992af5
|
||||
--- /dev/null
|
||||
+++ b/include/media/davinci/ccdc_common.h
|
||||
@@ -0,0 +1,48 @@
|
||||
+/*
|
||||
+ * Copyright (C) 2008-2009 Texas Instruments 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 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
|
||||
+ *
|
||||
+ **************************************************************************/
|
||||
+#ifndef _CCDC_COMMON_H
|
||||
+#define _CCDC_COMMON_H
|
||||
+enum ccdc_pixfmt {
|
||||
+ CCDC_PIXFMT_RAW = 0,
|
||||
+ CCDC_PIXFMT_YCBCR_16BIT = 1,
|
||||
+ CCDC_PIXFMT_YCBCR_8BIT = 2
|
||||
+};
|
||||
+
|
||||
+enum ccdc_frmfmt {
|
||||
+ CCDC_FRMFMT_PROGRESSIVE = 0,
|
||||
+ CCDC_FRMFMT_INTERLACED = 1
|
||||
+};
|
||||
+
|
||||
+/* PIXEL ORDER IN MEMORY from LSB to MSB */
|
||||
+/* only applicable for 8-bit input mode */
|
||||
+enum ccdc_pixorder {
|
||||
+ CCDC_PIXORDER_CBYCRY = 1,
|
||||
+ CCDC_PIXORDER_YCBYCR = 0
|
||||
+};
|
||||
+
|
||||
+enum ccdc_buftype {
|
||||
+ CCDC_BUFTYPE_FLD_INTERLEAVED,
|
||||
+ CCDC_BUFTYPE_FLD_SEPARATED
|
||||
+};
|
||||
+
|
||||
+enum ccdc_pinpol {
|
||||
+ CCDC_PINPOL_POSITIVE = 0,
|
||||
+ CCDC_PINPOL_NEGATIVE = 1
|
||||
+};
|
||||
+#endif
|
||||
diff --git a/include/media/davinci/ccdc_hw_device.h b/include/media/davinci/ccdc_hw_device.h
|
||||
new file mode 100644
|
||||
index 0000000..4ae9876
|
||||
--- /dev/null
|
||||
+++ b/include/media/davinci/ccdc_hw_device.h
|
||||
@@ -0,0 +1,117 @@
|
||||
+/*
|
||||
+ * Copyright (C) 2008 Texas Instruments 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 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
|
||||
+ *
|
||||
+ * ccdc device API
|
||||
+ */
|
||||
+#ifndef _CCDC_HW_DEVICE_H
|
||||
+#define _CCDC_HW_DEVICE_H
|
||||
+
|
||||
+#ifdef __KERNEL__
|
||||
+#include <linux/videodev2.h>
|
||||
+#include <linux/device.h>
|
||||
+#include <media/davinci/vpfe_types.h>
|
||||
+#include <media/davinci/ccdc_common.h>
|
||||
+/*
|
||||
+ * Maximum number of capture channels supported by VPFE
|
||||
+ */
|
||||
+#define CCDC_CAPTURE_NUM_CHANNELS 1
|
||||
+/*
|
||||
+ * vpfe hw interface
|
||||
+ */
|
||||
+struct ccdc_hw_device {
|
||||
+
|
||||
+ /* vpfe device name */
|
||||
+ char name[30];
|
||||
+
|
||||
+ /* Pointer to initialize function to initialize ccdc device */
|
||||
+ int (*open) (struct device *dev);
|
||||
+ /* Set of functions pointers for control related functions.
|
||||
+ * Use queryctrl of decoder interface to check if it is a decoder
|
||||
+ * control id. If not passed to ccdc to process it
|
||||
+ */
|
||||
+ /* set ccdc base address */
|
||||
+ void (*set_ccdc_base)(void *base, int size);
|
||||
+
|
||||
+ /* set vpss base address */
|
||||
+ void (*set_vpss_base)(void *base, int size);
|
||||
+
|
||||
+ /* get ccdc base */
|
||||
+ void * (*get_ccdc_base)(void);
|
||||
+
|
||||
+ /* get vpss base */
|
||||
+ void * (*get_vpss_base)(void);
|
||||
+
|
||||
+ void (*enable) (int en);
|
||||
+ /*
|
||||
+ * Pointer to function to enable or disable ccdc
|
||||
+ */
|
||||
+ u32 (*reset) (void);
|
||||
+ /* reset sbl. only for 6446 */
|
||||
+ void (*enable_out_to_sdram) (int en);
|
||||
+ /* Pointer to function to set hw frame type */
|
||||
+ int (*set_hw_if_type) (enum vpfe_hw_if_type iface);
|
||||
+ /* get interface parameters */
|
||||
+ int (*get_hw_if_params) (struct vpfe_hw_if_param *param);
|
||||
+ /* Pointer to function to set parameters. Used
|
||||
+ * for implementing VPFE_S_CCDC_PARAMS
|
||||
+ */
|
||||
+ int (*setparams) (void *params);
|
||||
+ /* Pointer to function to get parameter. Used
|
||||
+ * for implementing VPFE_G_CCDC_PARAMS
|
||||
+ */
|
||||
+ int (*getparams) (void *params);
|
||||
+ /* Pointer to function to configure ccdc */
|
||||
+ int (*configure) (void);
|
||||
+
|
||||
+ /* enumerate hw pix formats */
|
||||
+ int (*enum_pix)(enum vpfe_hw_pix_format *hw_pix, int i);
|
||||
+ /* Pointer to function to set buffer type */
|
||||
+ int (*set_buftype) (enum ccdc_buftype buf_type);
|
||||
+ /* Pointer to function to get buffer type */
|
||||
+ int (*get_buftype) (enum ccdc_buftype *buf_type);
|
||||
+ /* Pointer to function to set frame format */
|
||||
+ int (*set_frame_format) (enum ccdc_frmfmt frm_fmt);
|
||||
+ /* Pointer to function to get frame format */
|
||||
+ int (*get_frame_format) (enum ccdc_frmfmt *frm_fmt);
|
||||
+ /* Pointer to function to set buffer type */
|
||||
+ int (*get_pixelformat) (enum vpfe_hw_pix_format *pixfmt);
|
||||
+ /* Pointer to function to get pixel format. Uses V4L2 type */
|
||||
+ int (*set_pixelformat) (enum vpfe_hw_pix_format pixfmt);
|
||||
+ /* Pointer to function to set image window */
|
||||
+ int (*set_image_window) (struct v4l2_rect *win);
|
||||
+ /* Pointer to function to set image window */
|
||||
+ int (*get_image_window) (struct v4l2_rect *win);
|
||||
+ /* Pointer to function to get line length */
|
||||
+ int (*get_line_length) (unsigned int *len);
|
||||
+
|
||||
+ /* Query SoC control IDs */
|
||||
+ int (*queryctrl)(struct v4l2_queryctrl *qctrl);
|
||||
+ /* Set SoC control */
|
||||
+ int (*setcontrol)(struct v4l2_control *ctrl);
|
||||
+ /* Get SoC control */
|
||||
+ int (*getcontrol)(struct v4l2_control *ctrl);
|
||||
+ /* Pointer to function to set current standard info */
|
||||
+ /* Pointer to function to set frame buffer address */
|
||||
+ void (*setfbaddr) (unsigned long addr);
|
||||
+ /* Pointer to function to get field id */
|
||||
+ int (*getfid) (void);
|
||||
+ /* Pointer to deinitialize function */
|
||||
+ int (*close) (struct device *dev);
|
||||
+};
|
||||
+
|
||||
+#endif
|
||||
+#endif
|
||||
-- 1.6.0.4
|
||||
2558
recipes-bsp/linux/linux-davinci/vfpe3.patch
Normal file
2558
recipes-bsp/linux/linux-davinci/vfpe3.patch
Normal file
File diff suppressed because it is too large
Load Diff
1660
recipes-bsp/linux/linux-davinci/vfpe4.patch
Normal file
1660
recipes-bsp/linux/linux-davinci/vfpe4.patch
Normal file
File diff suppressed because it is too large
Load Diff
132
recipes-bsp/linux/linux-davinci/vfpe5.patch
Normal file
132
recipes-bsp/linux/linux-davinci/vfpe5.patch
Normal file
@@ -0,0 +1,132 @@
|
||||
Subject:
|
||||
[PATCH 5/7] Kconfig and Makefile changes for vpfe capture driver
|
||||
From:
|
||||
m-karicheri2-l0cyMroinI0@public.gmane.org
|
||||
Date:
|
||||
Fri, 13 Mar 2009 17:23:32 -0400
|
||||
To:
|
||||
davinci-linux-open-source-VycZQUHpC/PFrsHnngEfi1aTQe2KTcn/@public.gmane.org, davinci_opensource_ccb-uAqBSO/uNfhBDgjK7y7TUQ@public.gmane.org, psp_video-uAqBSO/uNfhBDgjK7y7TUQ@public.gmane.org
|
||||
Newsgroups:
|
||||
gmane.linux.davinci
|
||||
|
||||
Adding updates to video Kconfig and Makefile and adding
|
||||
Makefile for building vpfe-capture files
|
||||
|
||||
Signed-off-by: Murali Karicheri <m-karicheri2-l0cyMroinI0@public.gmane.org>
|
||||
---
|
||||
drivers/media/video/Kconfig | 48 ++++++++++++++++++++++++----------
|
||||
drivers/media/video/Makefile | 6 +---
|
||||
drivers/media/video/davinci/Makefile | 8 +++++
|
||||
3 files changed, 43 insertions(+), 19 deletions(-)
|
||||
create mode 100644 drivers/media/video/davinci/Makefile
|
||||
|
||||
diff --git a/drivers/media/video/Kconfig b/drivers/media/video/Kconfig
|
||||
index 1dd98d8..ea3a526 100644
|
||||
--- a/drivers/media/video/Kconfig
|
||||
+++ b/drivers/media/video/Kconfig
|
||||
@@ -485,25 +485,45 @@ config VIDEO_VIVI
|
||||
Say Y here if you want to test video apps or debug V4L devices.
|
||||
In doubt, say N.
|
||||
|
||||
-config VIDEO_TVP5146
|
||||
- tristate "TVP5146 video decoder"
|
||||
- depends on I2C && ARCH_DAVINCI
|
||||
+config VIDEO_VPFE_CAPTURE
|
||||
+ tristate "VPFE Video Capture Driver"
|
||||
+ depends on VIDEO_V4L2 && ARCH_DAVINCI
|
||||
+ select VIDEOBUF_DMA_CONTIG
|
||||
help
|
||||
- Support for I2C bus based TVP5146 configuration.
|
||||
+ Support for DMXXXX VPFE based frame grabber. This is the
|
||||
+ common V4L2 module for following DMXXX SoCs from Texas
|
||||
+ Instruments:- DM6446 & DM355.
|
||||
|
||||
To compile this driver as a module, choose M here: the
|
||||
- module will be called tvp5146.
|
||||
+ module will be called vpfe-capture.
|
||||
|
||||
-config VIDEO_DAVINCI
|
||||
- tristate "Davinci Video Capture"
|
||||
- depends on VIDEO_DEV && VIDEO_TVP5146 && ARCH_DAVINCI
|
||||
- select VIDEOBUF_GEN
|
||||
- select VIDEOBUF_DMA_SG
|
||||
+config VIDEO_DAVINCI_CCDC
|
||||
+ tristate "DM6446 CCDC HW module"
|
||||
+ depends on ARCH_DAVINCI_DM644x && VIDEO_VPFE_CAPTURE
|
||||
+ default y
|
||||
help
|
||||
- Support for Davinci based frame grabber through CCDC.
|
||||
-
|
||||
- To compile this driver as a module, choose M here: the
|
||||
- module will be called vpfe.
|
||||
+ Enables DaVinci CCD hw module. DaVinci CCDC hw interfaces
|
||||
+ with decoder modules such as TVP5146 over BT656 or
|
||||
+ sensor module such as MT9T001 over a raw interface. This
|
||||
+ module configures the interface and CCDC/ISIF to do
|
||||
+ video frame capture from slave decoders.
|
||||
+
|
||||
+ To compile this driver as a module, choose M here: the
|
||||
+ module will be called vpfe.
|
||||
+
|
||||
+config VIDEO_DM355_CCDC
|
||||
+ tristate "DM355 CCDC HW module"
|
||||
+ depends on ARCH_DAVINCI_DM355 && VIDEO_VPFE_CAPTURE
|
||||
+ default y
|
||||
+ help
|
||||
+ Enables DM355 CCD hw module. DM355 CCDC hw interfaces
|
||||
+ with decoder modules such as TVP5146 over BT656 or
|
||||
+ sensor module such as MT9T001 over a raw interface. This
|
||||
+ module configures the interface and CCDC/ISIF to do
|
||||
+ video frame capture from a slave decoders
|
||||
+
|
||||
+ To compile this driver as a module, choose M here: the
|
||||
+ module will be called vpfe.
|
||||
|
||||
source "drivers/media/video/bt8xx/Kconfig"
|
||||
|
||||
diff --git a/drivers/media/video/Makefile b/drivers/media/video/Makefile
|
||||
index 863b5c8..f8b6c0c 100644
|
||||
--- a/drivers/media/video/Makefile
|
||||
+++ b/drivers/media/video/Makefile
|
||||
@@ -10,8 +10,6 @@ stkwebcam-objs := stk-webcam.o stk-sensor.o
|
||||
|
||||
omap2cam-objs := omap24xxcam.o omap24xxcam-dma.o
|
||||
|
||||
-davinci-vpfe-objs := ccdc_davinci.o davinci_vpfe.o
|
||||
-
|
||||
videodev-objs := v4l2-dev.o v4l2-ioctl.o
|
||||
|
||||
videodev-objs := v4l2-dev.o v4l2-ioctl.o v4l2-device.o v4l2-subdev.o
|
||||
@@ -29,6 +27,7 @@ endif
|
||||
|
||||
obj-$(CONFIG_VIDEO_TUNER) += tuner.o
|
||||
|
||||
+obj-$(CONFIG_ARCH_DAVINCI) += davinci/
|
||||
obj-$(CONFIG_VIDEO_BT848) += bt8xx/
|
||||
obj-$(CONFIG_VIDEO_IR_I2C) += ir-kbd-i2c.o
|
||||
obj-$(CONFIG_VIDEO_TVAUDIO) += tvaudio.o
|
||||
@@ -135,9 +134,6 @@ obj-$(CONFIG_USB_S2255) += s2255drv.o
|
||||
obj-$(CONFIG_VIDEO_IVTV) += ivtv/
|
||||
obj-$(CONFIG_VIDEO_CX18) += cx18/
|
||||
|
||||
-obj-$(CONFIG_VIDEO_DAVINCI) += davinci-vpfe.o
|
||||
-obj-$(CONFIG_VIDEO_TVP5146) += tvp5146.o
|
||||
-
|
||||
obj-$(CONFIG_VIDEO_VIVI) += vivi.o
|
||||
obj-$(CONFIG_VIDEO_CX23885) += cx23885/
|
||||
|
||||
diff --git a/drivers/media/video/davinci/Makefile b/drivers/media/video/davinci/Makefile
|
||||
new file mode 100644
|
||||
index 0000000..77fe038
|
||||
--- /dev/null
|
||||
+++ b/drivers/media/video/davinci/Makefile
|
||||
@@ -0,0 +1,8 @@
|
||||
+#
|
||||
+# Makefile for the davinci video device drivers.
|
||||
+#
|
||||
+
|
||||
+# Capture: DaVinci and DM355
|
||||
+obj-$(CONFIG_VIDEO_DAVINCI_CCDC) += ccdc_davinci.o
|
||||
+obj-$(CONFIG_VIDEO_DM355_CCDC) += ccdc_dm355.o
|
||||
+obj-$(CONFIG_VIDEO_VPFE_CAPTURE) += vpfe_capture.o
|
||||
-- 1.6.0.4
|
||||
224
recipes-bsp/linux/linux-davinci/vfpe6.patch
Normal file
224
recipes-bsp/linux/linux-davinci/vfpe6.patch
Normal file
@@ -0,0 +1,224 @@
|
||||
Subject:
|
||||
[PATCH 6/7] platform-related-updates for vpfe capture driver on DM6446
|
||||
From:
|
||||
m-karicheri2-l0cyMroinI0@public.gmane.org
|
||||
Date:
|
||||
Fri, 13 Mar 2009 17:24:04 -0400
|
||||
To:
|
||||
davinci-linux-open-source-VycZQUHpC/PFrsHnngEfi1aTQe2KTcn/@public.gmane.org, davinci_opensource_ccb-uAqBSO/uNfhBDgjK7y7TUQ@public.gmane.org, psp_video-uAqBSO/uNfhBDgjK7y7TUQ@public.gmane.org
|
||||
Newsgroups:
|
||||
gmane.linux.davinci
|
||||
|
||||
Add platform related changes for vpfe capture driver on DM6446
|
||||
|
||||
Signed-off-by: Murali Karicheri <m-karicheri2-l0cyMroinI0@public.gmane.org>
|
||||
---
|
||||
arch/arm/mach-davinci/board-dm644x-evm.c | 88 ++++++++++++++++++++++++++-
|
||||
arch/arm/mach-davinci/dm644x.c | 42 +++++++++++++
|
||||
arch/arm/mach-davinci/include/mach/dm644x.h | 2 +
|
||||
3 files changed, 130 insertions(+), 2 deletions(-)
|
||||
|
||||
diff --git a/arch/arm/mach-davinci/board-dm644x-evm.c b/arch/arm/mach-davinci/board-dm644x-evm.c
|
||||
index 20ec961..5f4d9a8 100644
|
||||
--- a/arch/arm/mach-davinci/board-dm644x-evm.c
|
||||
+++ b/arch/arm/mach-davinci/board-dm644x-evm.c
|
||||
@@ -27,7 +27,9 @@
|
||||
#include <linux/io.h>
|
||||
#include <linux/phy.h>
|
||||
#include <linux/clk.h>
|
||||
-
|
||||
+#include <linux/videodev2.h>
|
||||
+#include <media/v4l2-int-device.h>
|
||||
+#include <media/tvp514x.h>
|
||||
#include <asm/setup.h>
|
||||
#include <asm/mach-types.h>
|
||||
|
||||
@@ -161,6 +163,41 @@ static struct platform_device davinci_fb_device = {
|
||||
.num_resources = 0,
|
||||
};
|
||||
|
||||
+
|
||||
+#define TVP514X_STD_ALL (V4L2_STD_NTSC | V4L2_STD_PAL)
|
||||
+static struct vpfe_capture_input vpfe_capture_inputs = {
|
||||
+ .num_inputs = VPFE_MAX_DEC_INPUTS,
|
||||
+ .current_input = 0,
|
||||
+ .inputs[0] = {
|
||||
+ .dec_name = TVP514X_MODULE_NAME,
|
||||
+ .input = {
|
||||
+ .index = 0,
|
||||
+ .name = "COMPOSITE",
|
||||
+ .type = V4L2_INPUT_TYPE_CAMERA,
|
||||
+ .std = TVP514X_STD_ALL,
|
||||
+ },
|
||||
+ .route = {
|
||||
+ .input = INPUT_CVBS_VI2B,
|
||||
+ .output = OUTPUT_10BIT_422_EMBEDDED_SYNC,
|
||||
+ },
|
||||
+ .routing_supported = 1,
|
||||
+ },
|
||||
+ .inputs[1] = {
|
||||
+ .dec_name = TVP514X_MODULE_NAME,
|
||||
+ .input = {
|
||||
+ .index = 1,
|
||||
+ .name = "SVIDEO",
|
||||
+ .type = V4L2_INPUT_TYPE_CAMERA,
|
||||
+ .std = TVP514X_STD_ALL,
|
||||
+ },
|
||||
+ .route = {
|
||||
+ .input = INPUT_SVIDEO_VI2C_VI1C,
|
||||
+ .output = OUTPUT_10BIT_422_EMBEDDED_SYNC,
|
||||
+ },
|
||||
+ .routing_supported = 1,
|
||||
+ },
|
||||
+};
|
||||
+
|
||||
static struct platform_device rtc_dev = {
|
||||
.name = "rtc_davinci_evm",
|
||||
.id = -1,
|
||||
@@ -447,6 +484,48 @@ int dm6446evm_eeprom_write(void *buf, off_t off, size_t count)
|
||||
}
|
||||
EXPORT_SYMBOL(dm6446evm_eeprom_write);
|
||||
|
||||
+#define TVP5146_I2C_ADDR (0x5D)
|
||||
+static struct v4l2_ifparm tvp5146_ifparm = {
|
||||
+ .if_type = V4L2_IF_TYPE_BT656,
|
||||
+ .u = {
|
||||
+ .bt656 = {
|
||||
+ .frame_start_on_rising_vs = 1,
|
||||
+ .bt_sync_correct = 0,
|
||||
+ .swap = 0,
|
||||
+ .latch_clk_inv = 0,
|
||||
+ .nobt_hs_inv = 0, /* active high */
|
||||
+ .nobt_vs_inv = 0, /* active high */
|
||||
+ .mode = V4L2_IF_TYPE_BT656_MODE_BT_8BIT,
|
||||
+ .clock_min = TVP514X_XCLK_BT656,
|
||||
+ .clock_max = TVP514X_XCLK_BT656,
|
||||
+ },
|
||||
+ },
|
||||
+};
|
||||
+
|
||||
+/**
|
||||
+ * @brief tvp5146_g_ifparm - Returns the TVP5146 decoder interface parameters
|
||||
+ *
|
||||
+ * @param p - pointer to v4l2_ifparm structure
|
||||
+ * @return result of operation - 0 is success
|
||||
+ */
|
||||
+static int tvp5146_g_ifparm(struct v4l2_ifparm *p)
|
||||
+{
|
||||
+ if (p == NULL)
|
||||
+ return -EINVAL;
|
||||
+
|
||||
+ *p = tvp5146_ifparm;
|
||||
+ return 0;
|
||||
+}
|
||||
+
|
||||
+#define TVP5146_NUM_INPUTS ARRAY_SIZE(tvp5146_input_list)
|
||||
+
|
||||
+static struct tvp514x_platform_data tvp5146_pdata = {
|
||||
+ .master = CAPTURE_DRV_NAME,
|
||||
+ .ifparm = tvp5146_g_ifparm,
|
||||
+ .hs_polarity = 1,
|
||||
+ .vs_polarity = 1
|
||||
+};
|
||||
+
|
||||
/*
|
||||
* MSP430 supports RTC, card detection, input from IR remote, and
|
||||
* a bit more. It triggers interrupts on GPIO(7) from pressing
|
||||
@@ -557,9 +636,12 @@ static struct i2c_board_info __initdata i2c_info[] = {
|
||||
I2C_BOARD_INFO("24c256", 0x50),
|
||||
.platform_data = &eeprom_info,
|
||||
},
|
||||
+ {
|
||||
+ I2C_BOARD_INFO("tvp5146", TVP5146_I2C_ADDR),
|
||||
+ .platform_data = &tvp5146_pdata,
|
||||
+ },
|
||||
/* ALSO:
|
||||
* - tvl320aic33 audio codec (0x1b)
|
||||
- * - tvp5146 video decoder (0x5d)
|
||||
*/
|
||||
};
|
||||
|
||||
@@ -591,6 +673,8 @@ static void __init
|
||||
davinci_evm_map_io(void)
|
||||
{
|
||||
davinci_map_common_io();
|
||||
+ /* setup input configuration for VPFE input devices */
|
||||
+ setup_vpfe_input_config(&vpfe_capture_inputs);
|
||||
dm644x_init();
|
||||
}
|
||||
|
||||
diff --git a/arch/arm/mach-davinci/dm644x.c b/arch/arm/mach-davinci/dm644x.c
|
||||
index 03946fd..f46095e 100644
|
||||
--- a/arch/arm/mach-davinci/dm644x.c
|
||||
+++ b/arch/arm/mach-davinci/dm644x.c
|
||||
@@ -419,6 +419,46 @@ static struct platform_device dm644x_edma_device = {
|
||||
.resource = edma_resources,
|
||||
};
|
||||
|
||||
+static struct resource vpfe_resources[] = {
|
||||
+ {
|
||||
+ .start = IRQ_VDINT0,
|
||||
+ .end = IRQ_VDINT0,
|
||||
+ .flags = IORESOURCE_IRQ,
|
||||
+ },
|
||||
+ {
|
||||
+ .start = IRQ_VDINT1,
|
||||
+ .end = IRQ_VDINT1,
|
||||
+ .flags = IORESOURCE_IRQ,
|
||||
+ },
|
||||
+ {
|
||||
+ .start = 0x01c70400,
|
||||
+ .end = 0x01c70400 + 0xff,
|
||||
+ .flags = IORESOURCE_MEM,
|
||||
+ },
|
||||
+ {
|
||||
+ .start = 0x01c73400,
|
||||
+ .end = 0x01c73400 + 0xff,
|
||||
+ .flags = IORESOURCE_MEM,
|
||||
+ },
|
||||
+};
|
||||
+
|
||||
+static u64 vpfe_capture_dma_mask = DMA_32BIT_MASK;
|
||||
+static struct platform_device vpfe_capture_dev = {
|
||||
+ .name = CAPTURE_DRV_NAME,
|
||||
+ .id = -1,
|
||||
+ .num_resources = ARRAY_SIZE(vpfe_resources),
|
||||
+ .resource = vpfe_resources,
|
||||
+ .dev = {
|
||||
+ .dma_mask = &vpfe_capture_dma_mask,
|
||||
+ .coherent_dma_mask = DMA_32BIT_MASK,
|
||||
+ },
|
||||
+};
|
||||
+
|
||||
+void setup_vpfe_input_config(struct vpfe_capture_input *input_config)
|
||||
+{
|
||||
+ vpfe_capture_dev.dev.platform_data = input_config;
|
||||
+}
|
||||
+
|
||||
/*----------------------------------------------------------------------*/
|
||||
|
||||
void __init dm644x_init(void)
|
||||
@@ -433,6 +473,8 @@ static int __init dm644x_init_devices(void)
|
||||
return 0;
|
||||
|
||||
platform_device_register(&dm644x_edma_device);
|
||||
+ /* Register VPFE capture device */
|
||||
+ platform_device_register(&vpfe_capture_dev);
|
||||
return 0;
|
||||
}
|
||||
postcore_initcall(dm644x_init_devices);
|
||||
diff --git a/arch/arm/mach-davinci/include/mach/dm644x.h b/arch/arm/mach-davinci/include/mach/dm644x.h
|
||||
index 5b3d512..14f9a8a 100644
|
||||
--- a/arch/arm/mach-davinci/include/mach/dm644x.h
|
||||
+++ b/arch/arm/mach-davinci/include/mach/dm644x.h
|
||||
@@ -23,7 +23,9 @@
|
||||
#define __ASM_ARCH_DM644X_H
|
||||
|
||||
#include <mach/hardware.h>
|
||||
+#include <media/davinci/vpfe_capture.h>
|
||||
|
||||
void __init dm644x_init(void);
|
||||
+void setup_vpfe_input_config(struct vpfe_capture_input *input_config);
|
||||
|
||||
#endif /* __ASM_ARCH_DM644X_H */
|
||||
-- 1.6.0.4
|
||||
283
recipes-bsp/linux/linux-davinci/vfpe7.patch
Normal file
283
recipes-bsp/linux/linux-davinci/vfpe7.patch
Normal file
@@ -0,0 +1,283 @@
|
||||
Subject:
|
||||
[PATCH 7/7] DM355 platform related changes for vpfe capture driver
|
||||
From:
|
||||
m-karicheri2-l0cyMroinI0@public.gmane.org
|
||||
Date:
|
||||
Fri, 13 Mar 2009 17:24:34 -0400
|
||||
To:
|
||||
davinci-linux-open-source-VycZQUHpC/PFrsHnngEfi1aTQe2KTcn/@public.gmane.org, davinci_opensource_ccb-uAqBSO/uNfhBDgjK7y7TUQ@public.gmane.org, psp_video-uAqBSO/uNfhBDgjK7y7TUQ@public.gmane.org
|
||||
Newsgroups:
|
||||
gmane.linux.davinci
|
||||
|
||||
Add platform related changes for vpfe capture driver on DM355
|
||||
|
||||
Signed-off-by: Murali Karicheri <m-karicheri2-l0cyMroinI0@public.gmane.org>
|
||||
---
|
||||
arch/arm/mach-davinci/board-dm355-evm.c | 91 +++++++++++++++++++++++++++-
|
||||
arch/arm/mach-davinci/dm355.c | 64 +++++++++++++++++++
|
||||
arch/arm/mach-davinci/include/mach/dm355.h | 2 +
|
||||
arch/arm/mach-davinci/include/mach/mux.h | 9 +++
|
||||
4 files changed, 163 insertions(+), 3 deletions(-)
|
||||
|
||||
diff --git a/arch/arm/mach-davinci/board-dm355-evm.c b/arch/arm/mach-davinci/board-dm355-evm.c
|
||||
index e104650..aaa58ba 100644
|
||||
--- a/arch/arm/mach-davinci/board-dm355-evm.c
|
||||
+++ b/arch/arm/mach-davinci/board-dm355-evm.c
|
||||
@@ -20,6 +20,8 @@
|
||||
#include <linux/io.h>
|
||||
#include <linux/gpio.h>
|
||||
#include <linux/clk.h>
|
||||
+#include <media/v4l2-int-device.h>
|
||||
+#include <media/tvp514x.h>
|
||||
#include <linux/spi/spi.h>
|
||||
#include <linux/spi/eeprom.h>
|
||||
|
||||
@@ -134,12 +136,58 @@ static void dm355evm_mmcsd_gpios(unsigned gpio)
|
||||
dm355evm_mmc_gpios = gpio;
|
||||
}
|
||||
|
||||
+#define TVP5146_I2C_ADDR 0x5D
|
||||
+static struct v4l2_ifparm tvp5146_ifparm = {
|
||||
+ .if_type = V4L2_IF_TYPE_BT656,
|
||||
+ .u = {
|
||||
+ .bt656 = {
|
||||
+ .frame_start_on_rising_vs = 1,
|
||||
+ .bt_sync_correct = 0,
|
||||
+ .swap = 0,
|
||||
+ .latch_clk_inv = 0,
|
||||
+ .nobt_hs_inv = 0, /* active high */
|
||||
+ .nobt_vs_inv = 0, /* active high */
|
||||
+ .mode = V4L2_IF_TYPE_BT656_MODE_BT_8BIT,
|
||||
+ .clock_min = TVP514X_XCLK_BT656,
|
||||
+ .clock_max = TVP514X_XCLK_BT656,
|
||||
+ },
|
||||
+ },
|
||||
+};
|
||||
+
|
||||
+/**
|
||||
+ * @brief tvp5146_g_ifparm - Returns the TVP5146 decoder interface parameters
|
||||
+ *
|
||||
+ * @param p - pointer to v4l2_ifparm structure
|
||||
+ * @return result of operation - 0 is success
|
||||
+ */
|
||||
+static int tvp5146_g_ifparm(struct v4l2_ifparm *p)
|
||||
+{
|
||||
+ if (p == NULL)
|
||||
+ return -EINVAL;
|
||||
+
|
||||
+ *p = tvp5146_ifparm;
|
||||
+ return 0;
|
||||
+}
|
||||
+
|
||||
+#define TVP5146_NUM_INPUTS ARRAY_SIZE(tvp5146_input_list)
|
||||
+
|
||||
+static struct tvp514x_platform_data tvp5146_pdata = {
|
||||
+ .master = CAPTURE_DRV_NAME,
|
||||
+ .ifparm = tvp5146_g_ifparm,
|
||||
+ .hs_polarity = 1,
|
||||
+ .vs_polarity = 1
|
||||
+};
|
||||
+
|
||||
static struct i2c_board_info dm355evm_i2c_info[] = {
|
||||
- { I2C_BOARD_INFO("dm355evm_msp", 0x25),
|
||||
+ { I2C_BOARD_INFO("dm355evm_msp", 0x25),
|
||||
.platform_data = dm355evm_mmcsd_gpios,
|
||||
- /* plus irq */ },
|
||||
+ },
|
||||
+ {
|
||||
+ I2C_BOARD_INFO("tvp5146", TVP5146_I2C_ADDR),
|
||||
+ .platform_data = &tvp5146_pdata,
|
||||
+ },
|
||||
+ /* { plus irq }, */
|
||||
/* { I2C_BOARD_INFO("tlv320aic3x", 0x1b), }, */
|
||||
- /* { I2C_BOARD_INFO("tvp5146", 0x5d), }, */
|
||||
};
|
||||
|
||||
static void __init evm_init_i2c(void)
|
||||
@@ -178,6 +226,41 @@ static struct platform_device dm355evm_dm9000 = {
|
||||
.num_resources = ARRAY_SIZE(dm355evm_dm9000_rsrc),
|
||||
};
|
||||
|
||||
+#define TVP514X_STD_ALL (V4L2_STD_NTSC | V4L2_STD_PAL)
|
||||
+
|
||||
+static struct vpfe_capture_input vpfe_capture_inputs = {
|
||||
+ .num_inputs = VPFE_MAX_DEC_INPUTS,
|
||||
+ .current_input = 0,
|
||||
+ .inputs[0] = {
|
||||
+ .dec_name = TVP514X_MODULE_NAME,
|
||||
+ .input = {
|
||||
+ .index = 0,
|
||||
+ .name = "COMPOSITE",
|
||||
+ .type = V4L2_INPUT_TYPE_CAMERA,
|
||||
+ .std = TVP514X_STD_ALL,
|
||||
+ },
|
||||
+ .route = {
|
||||
+ .input = INPUT_CVBS_VI2B,
|
||||
+ .output = OUTPUT_10BIT_422_EMBEDDED_SYNC,
|
||||
+ },
|
||||
+ .routing_supported = 1,
|
||||
+ },
|
||||
+ .inputs[1] = {
|
||||
+ .dec_name = TVP514X_MODULE_NAME,
|
||||
+ .input = {
|
||||
+ .index = 1,
|
||||
+ .name = "SVIDEO",
|
||||
+ .type = V4L2_INPUT_TYPE_CAMERA,
|
||||
+ .std = TVP514X_STD_ALL,
|
||||
+ },
|
||||
+ .route = {
|
||||
+ .input = INPUT_SVIDEO_VI2C_VI1C,
|
||||
+ .output = OUTPUT_10BIT_422_EMBEDDED_SYNC,
|
||||
+ },
|
||||
+ .routing_supported = 1,
|
||||
+ },
|
||||
+};
|
||||
+
|
||||
static struct platform_device *davinci_evm_devices[] __initdata = {
|
||||
&dm355evm_dm9000,
|
||||
&davinci_nand_device,
|
||||
@@ -190,6 +273,8 @@ static struct davinci_uart_config uart_config __initdata = {
|
||||
static void __init dm355_evm_map_io(void)
|
||||
{
|
||||
davinci_map_common_io();
|
||||
+ /* setup input configuration for VPFE input devices */
|
||||
+ setup_vpfe_input_config(&vpfe_capture_inputs);
|
||||
dm355_init();
|
||||
}
|
||||
|
||||
diff --git a/arch/arm/mach-davinci/dm355.c b/arch/arm/mach-davinci/dm355.c
|
||||
index 5f31649..e2612dd 100644
|
||||
--- a/arch/arm/mach-davinci/dm355.c
|
||||
+++ b/arch/arm/mach-davinci/dm355.c
|
||||
@@ -463,6 +463,14 @@ INT_CFG(DM355, INT_EDMA_TC1_ERR, 4, 1, 1, false)
|
||||
EVT_CFG(DM355, EVT8_ASP1_TX, 0, 1, 0, false)
|
||||
EVT_CFG(DM355, EVT9_ASP1_RX, 1, 1, 0, false)
|
||||
EVT_CFG(DM355, EVT26_MMC0_RX, 2, 1, 0, false)
|
||||
+
|
||||
+MUX_CFG(DM355, VIN_PCLK, 0, 14, 1, 1, false)
|
||||
+MUX_CFG(DM355, VIN_CAM_WEN, 0, 13, 1, 1, false)
|
||||
+MUX_CFG(DM355, VIN_CAM_VD, 0, 12, 1, 1, false)
|
||||
+MUX_CFG(DM355, VIN_CAM_HD, 0, 11, 1, 1, false)
|
||||
+MUX_CFG(DM355, VIN_YIN_EN, 0, 10, 1, 1, false)
|
||||
+MUX_CFG(DM355, VIN_CINL_EN, 0, 0, 0xff, 0x55, false)
|
||||
+MUX_CFG(DM355, VIN_CINH_EN, 0, 8, 3, 3, false)
|
||||
};
|
||||
|
||||
/*----------------------------------------------------------------------*/
|
||||
@@ -520,6 +528,47 @@ static struct platform_device dm355_edma_device = {
|
||||
.resource = edma_resources,
|
||||
};
|
||||
|
||||
+static struct resource vpfe_resources[] = {
|
||||
+ {
|
||||
+ .start = IRQ_VDINT0,
|
||||
+ .end = IRQ_VDINT0,
|
||||
+ .flags = IORESOURCE_IRQ,
|
||||
+ },
|
||||
+ {
|
||||
+ .start = IRQ_VDINT1,
|
||||
+ .end = IRQ_VDINT1,
|
||||
+ .flags = IORESOURCE_IRQ,
|
||||
+ },
|
||||
+ /* CCDC Base address */
|
||||
+ {
|
||||
+ .flags = IORESOURCE_MEM,
|
||||
+ .start = 0x01c70600,
|
||||
+ .end = 0x01c70600 + 0x1ff,
|
||||
+ },
|
||||
+ /* VPSS Base address */
|
||||
+ {
|
||||
+ .start = 0x01c70800,
|
||||
+ .end = 0x01c70800 + 0xff,
|
||||
+ .flags = IORESOURCE_MEM,
|
||||
+ },
|
||||
+};
|
||||
+
|
||||
+static u64 vpfe_capture_dma_mask = DMA_32BIT_MASK;
|
||||
+static struct platform_device vpfe_capture_dev = {
|
||||
+ .name = CAPTURE_DRV_NAME,
|
||||
+ .id = -1,
|
||||
+ .num_resources = ARRAY_SIZE(vpfe_resources),
|
||||
+ .resource = vpfe_resources,
|
||||
+ .dev = {
|
||||
+ .dma_mask = &vpfe_capture_dma_mask,
|
||||
+ .coherent_dma_mask = DMA_32BIT_MASK,
|
||||
+ },
|
||||
+};
|
||||
+
|
||||
+void setup_vpfe_input_config(struct vpfe_capture_input *input_config)
|
||||
+{
|
||||
+ vpfe_capture_dev.dev.platform_data = input_config;
|
||||
+}
|
||||
/*----------------------------------------------------------------------*/
|
||||
|
||||
void __init dm355_init(void)
|
||||
@@ -528,13 +577,28 @@ void __init dm355_init(void)
|
||||
davinci_mux_register(dm355_pins, ARRAY_SIZE(dm355_pins));;
|
||||
}
|
||||
|
||||
+#define DM355_VPSSCLK_CLKCTRL_REG 0x1c70004
|
||||
static int __init dm355_init_devices(void)
|
||||
{
|
||||
+ void __iomem *base = IO_ADDRESS(DM355_VPSSCLK_CLKCTRL_REG);
|
||||
if (!cpu_is_davinci_dm355())
|
||||
return 0;
|
||||
|
||||
davinci_cfg_reg(DM355_INT_EDMA_CC);
|
||||
platform_device_register(&dm355_edma_device);
|
||||
+ /* setup clock for vpss modules */
|
||||
+ __raw_writel(0x79, base);
|
||||
+ /* setup Mux configuration for vpfe input and register
|
||||
+ * vpfe capture platform device
|
||||
+ */
|
||||
+ davinci_cfg_reg(DM355_VIN_PCLK);
|
||||
+ davinci_cfg_reg(DM355_VIN_CAM_WEN);
|
||||
+ davinci_cfg_reg(DM355_VIN_CAM_VD);
|
||||
+ davinci_cfg_reg(DM355_VIN_CAM_HD);
|
||||
+ davinci_cfg_reg(DM355_VIN_YIN_EN);
|
||||
+ davinci_cfg_reg(DM355_VIN_CINL_EN);
|
||||
+ davinci_cfg_reg(DM355_VIN_CINH_EN);
|
||||
+ platform_device_register(&vpfe_capture_dev);
|
||||
return 0;
|
||||
}
|
||||
postcore_initcall(dm355_init_devices);
|
||||
diff --git a/arch/arm/mach-davinci/include/mach/dm355.h b/arch/arm/mach-davinci/include/mach/dm355.h
|
||||
index f7100b6..0b3bd76 100644
|
||||
--- a/arch/arm/mach-davinci/include/mach/dm355.h
|
||||
+++ b/arch/arm/mach-davinci/include/mach/dm355.h
|
||||
@@ -12,6 +12,7 @@
|
||||
#define __ASM_ARCH_DM355_H
|
||||
|
||||
#include <mach/hardware.h>
|
||||
+#include <media/davinci/vpfe_capture.h>
|
||||
|
||||
void __init dm355_init(void);
|
||||
|
||||
@@ -19,5 +20,6 @@ struct spi_board_info;
|
||||
|
||||
void dm355_init_spi0(unsigned chipselect_mask,
|
||||
struct spi_board_info *info, unsigned len);
|
||||
+void setup_vpfe_input_config(struct vpfe_capture_input *input_config);
|
||||
|
||||
#endif /* __ASM_ARCH_DM355_H */
|
||||
diff --git a/arch/arm/mach-davinci/include/mach/mux.h b/arch/arm/mach-davinci/include/mach/mux.h
|
||||
index cd95629..4c135b0 100644
|
||||
--- a/arch/arm/mach-davinci/include/mach/mux.h
|
||||
+++ b/arch/arm/mach-davinci/include/mach/mux.h
|
||||
@@ -149,6 +149,15 @@ enum davinci_dm355_index {
|
||||
DM355_EVT8_ASP1_TX,
|
||||
DM355_EVT9_ASP1_RX,
|
||||
DM355_EVT26_MMC0_RX,
|
||||
+
|
||||
+ /* Video In Pin Mux */
|
||||
+ DM355_VIN_PCLK,
|
||||
+ DM355_VIN_CAM_WEN,
|
||||
+ DM355_VIN_CAM_VD,
|
||||
+ DM355_VIN_CAM_HD,
|
||||
+ DM355_VIN_YIN_EN,
|
||||
+ DM355_VIN_CINL_EN,
|
||||
+ DM355_VIN_CINH_EN,
|
||||
};
|
||||
|
||||
#ifdef CONFIG_DAVINCI_MUX
|
||||
-- 1.6.0.4
|
||||
84
recipes-bsp/linux/linux-davinci_git.bb
Normal file
84
recipes-bsp/linux/linux-davinci_git.bb
Normal file
@@ -0,0 +1,84 @@
|
||||
require multi-kernel.inc
|
||||
|
||||
DESCRIPTION = "Linux kernel for DaVinci processors"
|
||||
KERNEL_IMAGETYPE = "uImage"
|
||||
|
||||
COMPATIBLE_MACHINE = "(dm355-evm|dm365-evm|dm6446-evm|dm6467-evm|dm6467t-evm|omapl137|omapl138|dm355-leopard|davinci-sffsdr|hawkboard)"
|
||||
|
||||
DEFAULT_PREFERENCE = "1"
|
||||
DEFAULT_PREFERENCE_dm365 = "-1"
|
||||
|
||||
BRANCH = "master"
|
||||
SRC_URI = "file://defconfig "
|
||||
|
||||
S = "${WORKDIR}/git"
|
||||
|
||||
# DaVinci DM3xx/DM6xxx
|
||||
# dm355-evm/dm365-evm/dm6446-evm/dm6467-evm/dm6467t-evm Davinci PSP 03.01.00/03.02.00 (build r30)
|
||||
# The main PR is now using MACHINE_KERNEL_PR, for davinci see conf/machine/include/davinci.inc
|
||||
|
||||
ARAGO_DM_REV = "e87a8397d2830db11ce1518bd2abc4e8815763f1"
|
||||
ARAGO_DM_PV = "2.6.31+2.6.32-rc2-${PR}+gitr${SRCREV}"
|
||||
ARAGO_DM_BR = "r32"
|
||||
ARAGO_DM_URI = "git://arago-project.org/git/projects/linux-davinci.git;protocol=git;branch=${BRANCH} "
|
||||
|
||||
SRCREV_dm355 = ${ARAGO_DM_REV}
|
||||
SRCREV_dm365 = ${ARAGO_DM_REV}
|
||||
SRCREV_dm6446 = ${ARAGO_DM_REV}
|
||||
SRCREV_dm6467 = ${ARAGO_DM_REV}
|
||||
|
||||
PV_dm355 = ${ARAGO_DM_PV}
|
||||
PV_dm365 = ${ARAGO_DM_PV}
|
||||
PV_dm6446 = ${ARAGO_DM_PV}
|
||||
PV_dm6467 = ${ARAGO_DM_PV}
|
||||
|
||||
BRANCH_dm355 = ${ARAGO_DM_BR}
|
||||
BRANCH_dm365 = ${ARAGO_DM_BR}
|
||||
BRANCH_dm6446 = ${ARAGO_DM_BR}
|
||||
BRANCH_dm6467 = ${ARAGO_DM_BR}
|
||||
|
||||
SRC_URI_append_dm355 = ${ARAGO_DM_URI}
|
||||
SRC_URI_append_dm365 = ${ARAGO_DM_URI}
|
||||
SRC_URI_append_dm6446 = ${ARAGO_DM_URI}
|
||||
SRC_URI_append_dm6467 = ${ARAGO_DM_URI}
|
||||
|
||||
|
||||
# The main PR is now using MACHINE_KERNEL_PR, for davinci see conf/machine/include/davinci.inc
|
||||
|
||||
# OMAPL tracking master branch - PSP 3.20.00.12
|
||||
|
||||
ARAGO_L1_REV = "2acf935c01b9adb50164d421c40cdc5862b9e143"
|
||||
ARAGO_L1_BR = "master"
|
||||
ARAGO_L1_PV = "2.6.32+2.6.33-rc4-${PR}+gitr${SRCREV}"
|
||||
ARAGO_L1_URI = "git://arago-project.org/git/projects/linux-omapl1.git;protocol=git;branch=${BRANCH} "
|
||||
|
||||
SRCREV_omapl137 = ${ARAGO_L1_REV}
|
||||
SRCREV_omapl138 = ${ARAGO_L1_REV}
|
||||
SRCREV_hawkboard = ${ARAGO_L1_REV}
|
||||
|
||||
PV_omapl137 = ${ARAGO_L1_PV}
|
||||
PV_omapl138 = ${ARAGO_L1_PV}
|
||||
|
||||
BRANCH_omapl137 = ${ARAGO_L1_BR}
|
||||
BRANCH_omapl138 = ${ARAGO_L1_BR}
|
||||
|
||||
SRC_URI_append_omapl137 = ${ARAGO_L1_URI}
|
||||
SRC_URI_append_omapl138 = ${ARAGO_L1_URI}
|
||||
|
||||
SRC_URI_append_omapl138 = "file://logo_linux_clut224.ppm \
|
||||
file://0001-ahci-ti-Fix-currently-harmless-typo-in-SATA-PHY.patch \
|
||||
file://0002-ahci-ti-Update-SATA-PHY-configuration-RXCDR.patch \
|
||||
file://0001-board-da850-evm-Disable-NAND-SUBPAGE.patch \
|
||||
file://0001-uio_pruss1-Core-driver-addition.patch \
|
||||
file://0002-uio_pruss2-Platform-changes.patch \
|
||||
file://0003-uio_pruss3-Workarounds-put-into-core-code.patch \
|
||||
"
|
||||
|
||||
SRC_URI_append_hawkboard = " \
|
||||
file://patch-2.6.33rc4-psp-to-hawkboard.patch \
|
||||
file://0001-board-da850-hawk-Disable-NAND-SUBPAGE.patch \
|
||||
"
|
||||
|
||||
do_configure_prepend_dm355-leopard() {
|
||||
sed -i s:2138:1381:g ${S}/arch/arm/tools/mach-types
|
||||
}
|
||||
45
recipes-bsp/u-boot/u-boot/dont-inline-weak-symbols.patch
Normal file
45
recipes-bsp/u-boot/u-boot/dont-inline-weak-symbols.patch
Normal file
@@ -0,0 +1,45 @@
|
||||
Patch initially created by Ron Lee and archived in OE patchwork at
|
||||
http://patchwork.openembedded.org/patch/1534/.
|
||||
|
||||
GCC 4.4 complains about this now.
|
||||
|
||||
Signed-off-by: Ron Lee <ron@debian.org>
|
||||
---
|
||||
lib_arm/board.c | 18 +++++++++---------
|
||||
1 files changed, 9 insertions(+), 9 deletions(-)
|
||||
|
||||
--- a/lib_arm/board.c
|
||||
+++ b/lib_arm/board.c
|
||||
@@ -124,23 +124,23 @@
|
||||
* May be supplied by boards if desired
|
||||
*/
|
||||
void inline __coloured_LED_init (void) {}
|
||||
-void inline coloured_LED_init (void) __attribute__((weak, alias("__coloured_LED_init")));
|
||||
+void coloured_LED_init (void) __attribute__((weak, alias("__coloured_LED_init")));
|
||||
void inline __red_LED_on (void) {}
|
||||
-void inline red_LED_on (void) __attribute__((weak, alias("__red_LED_on")));
|
||||
+void red_LED_on (void) __attribute__((weak, alias("__red_LED_on")));
|
||||
void inline __red_LED_off(void) {}
|
||||
-void inline red_LED_off(void) __attribute__((weak, alias("__red_LED_off")));
|
||||
+void red_LED_off(void) __attribute__((weak, alias("__red_LED_off")));
|
||||
void inline __green_LED_on(void) {}
|
||||
-void inline green_LED_on(void) __attribute__((weak, alias("__green_LED_on")));
|
||||
+void green_LED_on(void) __attribute__((weak, alias("__green_LED_on")));
|
||||
void inline __green_LED_off(void) {}
|
||||
-void inline green_LED_off(void)__attribute__((weak, alias("__green_LED_off")));
|
||||
+void green_LED_off(void)__attribute__((weak, alias("__green_LED_off")));
|
||||
void inline __yellow_LED_on(void) {}
|
||||
-void inline yellow_LED_on(void)__attribute__((weak, alias("__yellow_LED_on")));
|
||||
+void yellow_LED_on(void)__attribute__((weak, alias("__yellow_LED_on")));
|
||||
void inline __yellow_LED_off(void) {}
|
||||
-void inline yellow_LED_off(void)__attribute__((weak, alias("__yellow_LED_off")));
|
||||
+void yellow_LED_off(void)__attribute__((weak, alias("__yellow_LED_off")));
|
||||
void inline __blue_LED_on(void) {}
|
||||
-void inline blue_LED_on(void)__attribute__((weak, alias("__blue_LED_on")));
|
||||
+void blue_LED_on(void)__attribute__((weak, alias("__blue_LED_on")));
|
||||
void inline __blue_LED_off(void) {}
|
||||
-void inline blue_LED_off(void)__attribute__((weak, alias("__blue_LED_off")));
|
||||
+void blue_LED_off(void)__attribute__((weak, alias("__blue_LED_off")));
|
||||
|
||||
/************************************************************************
|
||||
* Init Utilities *
|
||||
@@ -66,4 +66,11 @@ SRC_URI_omap3evm = "git://arago-project.org/git/projects/u-boot-omap3.git;protoc
|
||||
SRCREV_omap3evm = "c0a8fb217fdca7888d89f9a3dee74a4cec865620"
|
||||
PV_omap3evm = "2009.11+${PR}+gitr${SRCREV}"
|
||||
|
||||
# hawkboard - master branch (hawk still .07beta)
|
||||
SRC_URI_hawkboard = "git://arago-project.org/git/people/sekhar/u-boot-omapl1.git;protocol=git;branch=master"
|
||||
SRC_URI_hawkboard += "file://dont-inline-weak-symbols.patch"
|
||||
SRCREV_hawkboard = "0d291f2f255e6d66a78b3dc2445362a96ae39a57"
|
||||
PV_hawkboard = "2009.08+gitr${SRCREV}"
|
||||
|
||||
|
||||
S = "${WORKDIR}/git"
|
||||
|
||||
Reference in New Issue
Block a user