Commit c091575c authored by Richard Röjfors's avatar Richard Röjfors Committed by Mauro Carvalho Chehab

[media] mfd: Add timberdale video-in driver to timberdale

This patch defines platform data for the video-in driver
and adds it to all configurations of timberdale.
Signed-off-by: default avatarRichard Röjfors <richard.rojfors@pelagicore.com>
Acked-by: default avatarSamuel Ortiz <sameo@linux.intel.com>
Signed-off-by: default avatarMauro Carvalho Chehab <mchehab@redhat.com>
parent 9eae42e5
...@@ -40,6 +40,7 @@ ...@@ -40,6 +40,7 @@
#include <linux/spi/mc33880.h> #include <linux/spi/mc33880.h>
#include <media/timb_radio.h> #include <media/timb_radio.h>
#include <media/timb_video.h>
#include <linux/timb_dma.h> #include <linux/timb_dma.h>
...@@ -246,7 +247,23 @@ static const __devinitconst struct resource timberdale_uartlite_resources[] = { ...@@ -246,7 +247,23 @@ static const __devinitconst struct resource timberdale_uartlite_resources[] = {
}, },
}; };
static const __devinitconst struct resource timberdale_radio_resources[] = { static __devinitdata struct i2c_board_info timberdale_adv7180_i2c_board_info = {
/* Requires jumper JP9 to be off */
I2C_BOARD_INFO("adv7180", 0x42 >> 1),
.irq = IRQ_TIMBERDALE_ADV7180
};
static __devinitdata struct timb_video_platform_data
timberdale_video_platform_data = {
.dma_channel = DMA_VIDEO_RX,
.i2c_adapter = 0,
.encoder = {
.info = &timberdale_adv7180_i2c_board_info
}
};
static const __devinitconst struct resource
timberdale_radio_resources[] = {
{ {
.start = RDSOFFSET, .start = RDSOFFSET,
.end = RDSEND, .end = RDSEND,
...@@ -278,6 +295,18 @@ static __devinitdata struct timb_radio_platform_data ...@@ -278,6 +295,18 @@ static __devinitdata struct timb_radio_platform_data
} }
}; };
static const __devinitconst struct resource timberdale_video_resources[] = {
{
.start = LOGIWOFFSET,
.end = LOGIWEND,
.flags = IORESOURCE_MEM,
},
/*
note that the "frame buffer" is located in DMA area
starting at 0x1200000
*/
};
static __devinitdata struct timb_dma_platform_data timb_dma_platform_data = { static __devinitdata struct timb_dma_platform_data timb_dma_platform_data = {
.nr_channels = 10, .nr_channels = 10,
.channels = { .channels = {
...@@ -377,6 +406,13 @@ static __devinitdata struct mfd_cell timberdale_cells_bar0_cfg0[] = { ...@@ -377,6 +406,13 @@ static __devinitdata struct mfd_cell timberdale_cells_bar0_cfg0[] = {
.platform_data = &timberdale_gpio_platform_data, .platform_data = &timberdale_gpio_platform_data,
.data_size = sizeof(timberdale_gpio_platform_data), .data_size = sizeof(timberdale_gpio_platform_data),
}, },
{
.name = "timb-video",
.num_resources = ARRAY_SIZE(timberdale_video_resources),
.resources = timberdale_video_resources,
.platform_data = &timberdale_video_platform_data,
.data_size = sizeof(timberdale_video_platform_data),
},
{ {
.name = "timb-radio", .name = "timb-radio",
.num_resources = ARRAY_SIZE(timberdale_radio_resources), .num_resources = ARRAY_SIZE(timberdale_radio_resources),
...@@ -437,6 +473,13 @@ static __devinitdata struct mfd_cell timberdale_cells_bar0_cfg1[] = { ...@@ -437,6 +473,13 @@ static __devinitdata struct mfd_cell timberdale_cells_bar0_cfg1[] = {
.num_resources = ARRAY_SIZE(timberdale_mlogicore_resources), .num_resources = ARRAY_SIZE(timberdale_mlogicore_resources),
.resources = timberdale_mlogicore_resources, .resources = timberdale_mlogicore_resources,
}, },
{
.name = "timb-video",
.num_resources = ARRAY_SIZE(timberdale_video_resources),
.resources = timberdale_video_resources,
.platform_data = &timberdale_video_platform_data,
.data_size = sizeof(timberdale_video_platform_data),
},
{ {
.name = "timb-radio", .name = "timb-radio",
.num_resources = ARRAY_SIZE(timberdale_radio_resources), .num_resources = ARRAY_SIZE(timberdale_radio_resources),
...@@ -487,6 +530,13 @@ static __devinitdata struct mfd_cell timberdale_cells_bar0_cfg2[] = { ...@@ -487,6 +530,13 @@ static __devinitdata struct mfd_cell timberdale_cells_bar0_cfg2[] = {
.platform_data = &timberdale_gpio_platform_data, .platform_data = &timberdale_gpio_platform_data,
.data_size = sizeof(timberdale_gpio_platform_data), .data_size = sizeof(timberdale_gpio_platform_data),
}, },
{
.name = "timb-video",
.num_resources = ARRAY_SIZE(timberdale_video_resources),
.resources = timberdale_video_resources,
.platform_data = &timberdale_video_platform_data,
.data_size = sizeof(timberdale_video_platform_data),
},
{ {
.name = "timb-radio", .name = "timb-radio",
.num_resources = ARRAY_SIZE(timberdale_radio_resources), .num_resources = ARRAY_SIZE(timberdale_radio_resources),
...@@ -530,6 +580,13 @@ static __devinitdata struct mfd_cell timberdale_cells_bar0_cfg3[] = { ...@@ -530,6 +580,13 @@ static __devinitdata struct mfd_cell timberdale_cells_bar0_cfg3[] = {
.platform_data = &timberdale_gpio_platform_data, .platform_data = &timberdale_gpio_platform_data,
.data_size = sizeof(timberdale_gpio_platform_data), .data_size = sizeof(timberdale_gpio_platform_data),
}, },
{
.name = "timb-video",
.num_resources = ARRAY_SIZE(timberdale_video_resources),
.resources = timberdale_video_resources,
.platform_data = &timberdale_video_platform_data,
.data_size = sizeof(timberdale_video_platform_data),
},
{ {
.name = "timb-radio", .name = "timb-radio",
.num_resources = ARRAY_SIZE(timberdale_radio_resources), .num_resources = ARRAY_SIZE(timberdale_radio_resources),
......
...@@ -23,7 +23,7 @@ ...@@ -23,7 +23,7 @@
#ifndef MFD_TIMBERDALE_H #ifndef MFD_TIMBERDALE_H
#define MFD_TIMBERDALE_H #define MFD_TIMBERDALE_H
#define DRV_VERSION "0.2" #define DRV_VERSION "0.3"
/* This driver only support versions >= 3.8 and < 4.0 */ /* This driver only support versions >= 3.8 and < 4.0 */
#define TIMB_SUPPORTED_MAJOR 3 #define TIMB_SUPPORTED_MAJOR 3
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment