diff options
author | Linus Torvalds <torvalds@linux-foundation.org> | 2012-10-11 23:39:17 -0400 |
---|---|---|
committer | Linus Torvalds <torvalds@linux-foundation.org> | 2012-10-11 23:39:17 -0400 |
commit | 4f1cd91497774488ed16119ec3f54b3daf1561de (patch) | |
tree | 190ed2b2ecbbfe371740cf6e29d9aefd25ecc3e3 /arch/arm/mach-davinci | |
parent | 759e00b8a8883be28357426206d2f1752827e38a (diff) | |
parent | bf3b202b41999f88f091632f13842b7234bd58b7 (diff) |
Merge branch 'v4l_for_linus' of git://git.kernel.org/pub/scm/linux/kernel/git/mchehab/linux-media
Pull second set of media updates from Mauro Carvalho Chehab:
"Despite its size, most of the stuff here is trivial. This series
contains:
- s5p-mfc: additions at the driver and at the core to support H.264
hardware codec;
- Some improvements at s5p and davinci embedded drivers;
- Some V4L2 compliance fixes applied on a few drivers;
- Several random trivial patches, including several fixes and a few
new board support additions;
Notes:
1) Some Exynos media patches were dependent on some -arm fixes that
got merged on changeset 782cd9e. That's why this pull request is
based that changeset.
2) As promised, I reviewed the pending VB2 DMABUF series.
While setting a test environment, it was noticed that the upstream
support for Samsung Exynos 4 boards (smdk310 and Origen) are
broken upstream, likely due to regressions: both defconfigs are
wrong and regulator settings for both boards are broken. That,
allied with some bug at the dummy regulator driver, causes OOPSes
during boot time.
Long story short: even fixing the above, the proposed patches
OOPSed when running the DMABUF test. Not sure yet if the OOPSes
are due to some other undetected regressions, or due to some bug
on the patches.
Due to the above, DMABUF patches for vb2 got NACKed for 3.7."
* 'v4l_for_linus' of git://git.kernel.org/pub/scm/linux/kernel/git/mchehab/linux-media: (109 commits)
[media] m5mols: Add missing #include <linux/sizes.h>
[media] stk1160: Add support for S-Video input
Revert "[media] omap3isp: Replace cpu_is_omap3630() with ISP revision check"
[media] dvb: LNA implementation changes
[media] v4l2-ioctl: fix W=1 warnings
[media] v4l2-ioctl: add blocks check for VIDIOC_SUBDEV_G/S_EDID
[media] omap3isp: Fix compilation error in ispreg.h
[media] rc-msi-digivox-ii: Add full scan keycodes
[media] cx25821: testing the wrong variable
[media] tda18271-common: hold the I2C adapter during write transfers
[media] ds3000: add module parameter to force firmware upload
[media] drivers/media: Remove unnecessary semicolon
[media] winbond: remove space from driver name
[media] iguanair: cannot send data from the stack
[media] omap3isp: Replace cpu_is_omap3630() with ISP revision check
[media] dvb-usb: print small buffers via %*ph
[media] uvc: Add return code check at vb2_queue_init()
[media] em28xx: Replace memcpy with struct assignment
[media] bt8xx: Add video4linux control V4L2_CID_COLOR_KILLER
[media] mem2mem_testdev: Use devm_kzalloc() in probe
...
Conflicts:
arch/arm/mach-davinci/include/mach/da8xx.h
Diffstat (limited to 'arch/arm/mach-davinci')
-rw-r--r-- | arch/arm/mach-davinci/Kconfig | 7 | ||||
-rw-r--r-- | arch/arm/mach-davinci/board-da850-evm.c | 179 | ||||
-rw-r--r-- | arch/arm/mach-davinci/board-dm644x-evm.c | 15 | ||||
-rw-r--r-- | arch/arm/mach-davinci/board-dm646x-evm.c | 80 | ||||
-rw-r--r-- | arch/arm/mach-davinci/da850.c | 152 | ||||
-rw-r--r-- | arch/arm/mach-davinci/dm644x.c | 17 | ||||
-rw-r--r-- | arch/arm/mach-davinci/include/mach/da8xx.h | 11 | ||||
-rw-r--r-- | arch/arm/mach-davinci/include/mach/mux.h | 42 | ||||
-rw-r--r-- | arch/arm/mach-davinci/include/mach/psc.h | 1 |
9 files changed, 460 insertions, 44 deletions
diff --git a/arch/arm/mach-davinci/Kconfig b/arch/arm/mach-davinci/Kconfig index ab99c3c3b752..026b4b277ae5 100644 --- a/arch/arm/mach-davinci/Kconfig +++ b/arch/arm/mach-davinci/Kconfig | |||
@@ -186,6 +186,13 @@ config DA850_UI_RMII | |||
186 | NOTE: Please take care while choosing this option, MII PHY will | 186 | NOTE: Please take care while choosing this option, MII PHY will |
187 | not be functional if RMII mode is selected. | 187 | not be functional if RMII mode is selected. |
188 | 188 | ||
189 | config DA850_UI_SD_VIDEO_PORT | ||
190 | bool "Video Port Interface" | ||
191 | help | ||
192 | Say Y if you want to use Video Port Interface (VPIF) on the | ||
193 | DA850/OMAP-L138 EVM. The Video decoders/encoders are found on the | ||
194 | UI daughter card that is supplied with the EVM. | ||
195 | |||
189 | endchoice | 196 | endchoice |
190 | 197 | ||
191 | config DA850_WL12XX | 198 | config DA850_WL12XX |
diff --git a/arch/arm/mach-davinci/board-da850-evm.c b/arch/arm/mach-davinci/board-da850-evm.c index 1295e616ceee..32ee3f895967 100644 --- a/arch/arm/mach-davinci/board-da850-evm.c +++ b/arch/arm/mach-davinci/board-da850-evm.c | |||
@@ -45,6 +45,9 @@ | |||
45 | #include <linux/platform_data/mtd-davinci-aemif.h> | 45 | #include <linux/platform_data/mtd-davinci-aemif.h> |
46 | #include <linux/platform_data/spi-davinci.h> | 46 | #include <linux/platform_data/spi-davinci.h> |
47 | 47 | ||
48 | #include <media/tvp514x.h> | ||
49 | #include <media/adv7343.h> | ||
50 | |||
48 | #define DA850_EVM_PHY_ID "davinci_mdio-0:00" | 51 | #define DA850_EVM_PHY_ID "davinci_mdio-0:00" |
49 | #define DA850_LCD_PWR_PIN GPIO_TO_PIN(2, 8) | 52 | #define DA850_LCD_PWR_PIN GPIO_TO_PIN(2, 8) |
50 | #define DA850_LCD_BL_PIN GPIO_TO_PIN(2, 15) | 53 | #define DA850_LCD_BL_PIN GPIO_TO_PIN(2, 15) |
@@ -452,6 +455,15 @@ static void da850_evm_ui_keys_init(unsigned gpio) | |||
452 | } | 455 | } |
453 | } | 456 | } |
454 | 457 | ||
458 | #ifdef CONFIG_DA850_UI_SD_VIDEO_PORT | ||
459 | static inline void da850_evm_setup_video_port(int video_sel) | ||
460 | { | ||
461 | gpio_set_value_cansleep(video_sel, 0); | ||
462 | } | ||
463 | #else | ||
464 | static inline void da850_evm_setup_video_port(int video_sel) { } | ||
465 | #endif | ||
466 | |||
455 | static int da850_evm_ui_expander_setup(struct i2c_client *client, unsigned gpio, | 467 | static int da850_evm_ui_expander_setup(struct i2c_client *client, unsigned gpio, |
456 | unsigned ngpio, void *c) | 468 | unsigned ngpio, void *c) |
457 | { | 469 | { |
@@ -497,6 +509,8 @@ static int da850_evm_ui_expander_setup(struct i2c_client *client, unsigned gpio, | |||
497 | 509 | ||
498 | da850_evm_setup_emac_rmii(sel_a); | 510 | da850_evm_setup_emac_rmii(sel_a); |
499 | 511 | ||
512 | da850_evm_setup_video_port(sel_c); | ||
513 | |||
500 | return 0; | 514 | return 0; |
501 | 515 | ||
502 | exp_setup_keys_fail: | 516 | exp_setup_keys_fail: |
@@ -1149,6 +1163,169 @@ static __init int da850_evm_init_cpufreq(void) | |||
1149 | static __init int da850_evm_init_cpufreq(void) { return 0; } | 1163 | static __init int da850_evm_init_cpufreq(void) { return 0; } |
1150 | #endif | 1164 | #endif |
1151 | 1165 | ||
1166 | #if defined(CONFIG_DA850_UI_SD_VIDEO_PORT) | ||
1167 | |||
1168 | #define TVP5147_CH0 "tvp514x-0" | ||
1169 | #define TVP5147_CH1 "tvp514x-1" | ||
1170 | |||
1171 | /* VPIF capture configuration */ | ||
1172 | static struct tvp514x_platform_data tvp5146_pdata = { | ||
1173 | .clk_polarity = 0, | ||
1174 | .hs_polarity = 1, | ||
1175 | .vs_polarity = 1, | ||
1176 | }; | ||
1177 | |||
1178 | #define TVP514X_STD_ALL (V4L2_STD_NTSC | V4L2_STD_PAL) | ||
1179 | |||
1180 | static const struct vpif_input da850_ch0_inputs[] = { | ||
1181 | { | ||
1182 | .input = { | ||
1183 | .index = 0, | ||
1184 | .name = "Composite", | ||
1185 | .type = V4L2_INPUT_TYPE_CAMERA, | ||
1186 | .capabilities = V4L2_IN_CAP_STD, | ||
1187 | .std = TVP514X_STD_ALL, | ||
1188 | }, | ||
1189 | .input_route = INPUT_CVBS_VI2B, | ||
1190 | .output_route = OUTPUT_10BIT_422_EMBEDDED_SYNC, | ||
1191 | .subdev_name = TVP5147_CH0, | ||
1192 | }, | ||
1193 | }; | ||
1194 | |||
1195 | static const struct vpif_input da850_ch1_inputs[] = { | ||
1196 | { | ||
1197 | .input = { | ||
1198 | .index = 0, | ||
1199 | .name = "S-Video", | ||
1200 | .type = V4L2_INPUT_TYPE_CAMERA, | ||
1201 | .capabilities = V4L2_IN_CAP_STD, | ||
1202 | .std = TVP514X_STD_ALL, | ||
1203 | }, | ||
1204 | .input_route = INPUT_SVIDEO_VI2C_VI1C, | ||
1205 | .output_route = OUTPUT_10BIT_422_EMBEDDED_SYNC, | ||
1206 | .subdev_name = TVP5147_CH1, | ||
1207 | }, | ||
1208 | }; | ||
1209 | |||
1210 | static struct vpif_subdev_info da850_vpif_capture_sdev_info[] = { | ||
1211 | { | ||
1212 | .name = TVP5147_CH0, | ||
1213 | .board_info = { | ||
1214 | I2C_BOARD_INFO("tvp5146", 0x5d), | ||
1215 | .platform_data = &tvp5146_pdata, | ||
1216 | }, | ||
1217 | }, | ||
1218 | { | ||
1219 | .name = TVP5147_CH1, | ||
1220 | .board_info = { | ||
1221 | I2C_BOARD_INFO("tvp5146", 0x5c), | ||
1222 | .platform_data = &tvp5146_pdata, | ||
1223 | }, | ||
1224 | }, | ||
1225 | }; | ||
1226 | |||
1227 | static struct vpif_capture_config da850_vpif_capture_config = { | ||
1228 | .subdev_info = da850_vpif_capture_sdev_info, | ||
1229 | .subdev_count = ARRAY_SIZE(da850_vpif_capture_sdev_info), | ||
1230 | .chan_config[0] = { | ||
1231 | .inputs = da850_ch0_inputs, | ||
1232 | .input_count = ARRAY_SIZE(da850_ch0_inputs), | ||
1233 | .vpif_if = { | ||
1234 | .if_type = VPIF_IF_BT656, | ||
1235 | .hd_pol = 1, | ||
1236 | .vd_pol = 1, | ||
1237 | .fid_pol = 0, | ||
1238 | }, | ||
1239 | }, | ||
1240 | .chan_config[1] = { | ||
1241 | .inputs = da850_ch1_inputs, | ||
1242 | .input_count = ARRAY_SIZE(da850_ch1_inputs), | ||
1243 | .vpif_if = { | ||
1244 | .if_type = VPIF_IF_BT656, | ||
1245 | .hd_pol = 1, | ||
1246 | .vd_pol = 1, | ||
1247 | .fid_pol = 0, | ||
1248 | }, | ||
1249 | }, | ||
1250 | .card_name = "DA850/OMAP-L138 Video Capture", | ||
1251 | }; | ||
1252 | |||
1253 | /* VPIF display configuration */ | ||
1254 | static struct vpif_subdev_info da850_vpif_subdev[] = { | ||
1255 | { | ||
1256 | .name = "adv7343", | ||
1257 | .board_info = { | ||
1258 | I2C_BOARD_INFO("adv7343", 0x2a), | ||
1259 | }, | ||
1260 | }, | ||
1261 | }; | ||
1262 | |||
1263 | static const struct vpif_output da850_ch0_outputs[] = { | ||
1264 | { | ||
1265 | .output = { | ||
1266 | .index = 0, | ||
1267 | .name = "Composite", | ||
1268 | .type = V4L2_OUTPUT_TYPE_ANALOG, | ||
1269 | .capabilities = V4L2_OUT_CAP_STD, | ||
1270 | .std = V4L2_STD_ALL, | ||
1271 | }, | ||
1272 | .subdev_name = "adv7343", | ||
1273 | .output_route = ADV7343_COMPOSITE_ID, | ||
1274 | }, | ||
1275 | { | ||
1276 | .output = { | ||
1277 | .index = 1, | ||
1278 | .name = "S-Video", | ||
1279 | .type = V4L2_OUTPUT_TYPE_ANALOG, | ||
1280 | .capabilities = V4L2_OUT_CAP_STD, | ||
1281 | .std = V4L2_STD_ALL, | ||
1282 | }, | ||
1283 | .subdev_name = "adv7343", | ||
1284 | .output_route = ADV7343_SVIDEO_ID, | ||
1285 | }, | ||
1286 | }; | ||
1287 | |||
1288 | static struct vpif_display_config da850_vpif_display_config = { | ||
1289 | .subdevinfo = da850_vpif_subdev, | ||
1290 | .subdev_count = ARRAY_SIZE(da850_vpif_subdev), | ||
1291 | .chan_config[0] = { | ||
1292 | .outputs = da850_ch0_outputs, | ||
1293 | .output_count = ARRAY_SIZE(da850_ch0_outputs), | ||
1294 | }, | ||
1295 | .card_name = "DA850/OMAP-L138 Video Display", | ||
1296 | }; | ||
1297 | |||
1298 | static __init void da850_vpif_init(void) | ||
1299 | { | ||
1300 | int ret; | ||
1301 | |||
1302 | ret = da850_register_vpif(); | ||
1303 | if (ret) | ||
1304 | pr_warn("da850_evm_init: VPIF setup failed: %d\n", ret); | ||
1305 | |||
1306 | ret = davinci_cfg_reg_list(da850_vpif_capture_pins); | ||
1307 | if (ret) | ||
1308 | pr_warn("da850_evm_init: VPIF capture mux setup failed: %d\n", | ||
1309 | ret); | ||
1310 | |||
1311 | ret = da850_register_vpif_capture(&da850_vpif_capture_config); | ||
1312 | if (ret) | ||
1313 | pr_warn("da850_evm_init: VPIF capture setup failed: %d\n", ret); | ||
1314 | |||
1315 | ret = davinci_cfg_reg_list(da850_vpif_display_pins); | ||
1316 | if (ret) | ||
1317 | pr_warn("da850_evm_init: VPIF display mux setup failed: %d\n", | ||
1318 | ret); | ||
1319 | |||
1320 | ret = da850_register_vpif_display(&da850_vpif_display_config); | ||
1321 | if (ret) | ||
1322 | pr_warn("da850_evm_init: VPIF display setup failed: %d\n", ret); | ||
1323 | } | ||
1324 | |||
1325 | #else | ||
1326 | static __init void da850_vpif_init(void) {} | ||
1327 | #endif | ||
1328 | |||
1152 | #ifdef CONFIG_DA850_WL12XX | 1329 | #ifdef CONFIG_DA850_WL12XX |
1153 | 1330 | ||
1154 | static void wl12xx_set_power(int index, bool power_on) | 1331 | static void wl12xx_set_power(int index, bool power_on) |
@@ -1375,6 +1552,8 @@ static __init void da850_evm_init(void) | |||
1375 | pr_warning("da850_evm_init: suspend registration failed: %d\n", | 1552 | pr_warning("da850_evm_init: suspend registration failed: %d\n", |
1376 | ret); | 1553 | ret); |
1377 | 1554 | ||
1555 | da850_vpif_init(); | ||
1556 | |||
1378 | ret = da8xx_register_spi(1, da850evm_spi_info, | 1557 | ret = da8xx_register_spi(1, da850evm_spi_info, |
1379 | ARRAY_SIZE(da850evm_spi_info)); | 1558 | ARRAY_SIZE(da850evm_spi_info)); |
1380 | if (ret) | 1559 | if (ret) |
diff --git a/arch/arm/mach-davinci/board-dm644x-evm.c b/arch/arm/mach-davinci/board-dm644x-evm.c index ca72fc4b8cca..f22572cee49d 100644 --- a/arch/arm/mach-davinci/board-dm644x-evm.c +++ b/arch/arm/mach-davinci/board-dm644x-evm.c | |||
@@ -23,6 +23,7 @@ | |||
23 | #include <linux/phy.h> | 23 | #include <linux/phy.h> |
24 | #include <linux/clk.h> | 24 | #include <linux/clk.h> |
25 | #include <linux/videodev2.h> | 25 | #include <linux/videodev2.h> |
26 | #include <linux/v4l2-dv-timings.h> | ||
26 | #include <linux/export.h> | 27 | #include <linux/export.h> |
27 | 28 | ||
28 | #include <media/tvp514x.h> | 29 | #include <media/tvp514x.h> |
@@ -620,7 +621,7 @@ static struct vpbe_enc_mode_info dm644xevm_enc_std_timing[] = { | |||
620 | { | 621 | { |
621 | .name = "ntsc", | 622 | .name = "ntsc", |
622 | .timings_type = VPBE_ENC_STD, | 623 | .timings_type = VPBE_ENC_STD, |
623 | .timings = {V4L2_STD_525_60}, | 624 | .std_id = V4L2_STD_525_60, |
624 | .interlaced = 1, | 625 | .interlaced = 1, |
625 | .xres = 720, | 626 | .xres = 720, |
626 | .yres = 480, | 627 | .yres = 480, |
@@ -632,7 +633,7 @@ static struct vpbe_enc_mode_info dm644xevm_enc_std_timing[] = { | |||
632 | { | 633 | { |
633 | .name = "pal", | 634 | .name = "pal", |
634 | .timings_type = VPBE_ENC_STD, | 635 | .timings_type = VPBE_ENC_STD, |
635 | .timings = {V4L2_STD_625_50}, | 636 | .std_id = V4L2_STD_625_50, |
636 | .interlaced = 1, | 637 | .interlaced = 1, |
637 | .xres = 720, | 638 | .xres = 720, |
638 | .yres = 576, | 639 | .yres = 576, |
@@ -647,8 +648,8 @@ static struct vpbe_enc_mode_info dm644xevm_enc_std_timing[] = { | |||
647 | static struct vpbe_enc_mode_info dm644xevm_enc_preset_timing[] = { | 648 | static struct vpbe_enc_mode_info dm644xevm_enc_preset_timing[] = { |
648 | { | 649 | { |
649 | .name = "480p59_94", | 650 | .name = "480p59_94", |
650 | .timings_type = VPBE_ENC_DV_PRESET, | 651 | .timings_type = VPBE_ENC_CUSTOM_TIMINGS, |
651 | .timings = {V4L2_DV_480P59_94}, | 652 | .dv_timings = V4L2_DV_BT_CEA_720X480P59_94, |
652 | .interlaced = 0, | 653 | .interlaced = 0, |
653 | .xres = 720, | 654 | .xres = 720, |
654 | .yres = 480, | 655 | .yres = 480, |
@@ -659,8 +660,8 @@ static struct vpbe_enc_mode_info dm644xevm_enc_preset_timing[] = { | |||
659 | }, | 660 | }, |
660 | { | 661 | { |
661 | .name = "576p50", | 662 | .name = "576p50", |
662 | .timings_type = VPBE_ENC_DV_PRESET, | 663 | .timings_type = VPBE_ENC_CUSTOM_TIMINGS, |
663 | .timings = {V4L2_DV_576P50}, | 664 | .dv_timings = V4L2_DV_BT_CEA_720X576P50, |
664 | .interlaced = 0, | 665 | .interlaced = 0, |
665 | .xres = 720, | 666 | .xres = 720, |
666 | .yres = 576, | 667 | .yres = 576, |
@@ -698,7 +699,7 @@ static struct vpbe_output dm644xevm_vpbe_outputs[] = { | |||
698 | .index = 1, | 699 | .index = 1, |
699 | .name = "Component", | 700 | .name = "Component", |
700 | .type = V4L2_OUTPUT_TYPE_ANALOG, | 701 | .type = V4L2_OUTPUT_TYPE_ANALOG, |
701 | .capabilities = V4L2_OUT_CAP_PRESETS, | 702 | .capabilities = V4L2_OUT_CAP_DV_TIMINGS, |
702 | }, | 703 | }, |
703 | .subdev_name = VPBE_VENC_SUBDEV_NAME, | 704 | .subdev_name = VPBE_VENC_SUBDEV_NAME, |
704 | .default_mode = "480p59_94", | 705 | .default_mode = "480p59_94", |
diff --git a/arch/arm/mach-davinci/board-dm646x-evm.c b/arch/arm/mach-davinci/board-dm646x-evm.c index 9944367b4931..1dbf85beed1b 100644 --- a/arch/arm/mach-davinci/board-dm646x-evm.c +++ b/arch/arm/mach-davinci/board-dm646x-evm.c | |||
@@ -26,6 +26,7 @@ | |||
26 | #include <linux/i2c/pcf857x.h> | 26 | #include <linux/i2c/pcf857x.h> |
27 | 27 | ||
28 | #include <media/tvp514x.h> | 28 | #include <media/tvp514x.h> |
29 | #include <media/adv7343.h> | ||
29 | 30 | ||
30 | #include <linux/mtd/mtd.h> | 31 | #include <linux/mtd/mtd.h> |
31 | #include <linux/mtd/nand.h> | 32 | #include <linux/mtd/nand.h> |
@@ -496,18 +497,49 @@ static struct vpif_subdev_info dm646x_vpif_subdev[] = { | |||
496 | }, | 497 | }, |
497 | }; | 498 | }; |
498 | 499 | ||
499 | static const char *output[] = { | 500 | static const struct vpif_output dm6467_ch0_outputs[] = { |
500 | "Composite", | 501 | { |
501 | "Component", | 502 | .output = { |
502 | "S-Video", | 503 | .index = 0, |
504 | .name = "Composite", | ||
505 | .type = V4L2_OUTPUT_TYPE_ANALOG, | ||
506 | .capabilities = V4L2_OUT_CAP_STD, | ||
507 | .std = V4L2_STD_ALL, | ||
508 | }, | ||
509 | .subdev_name = "adv7343", | ||
510 | .output_route = ADV7343_COMPOSITE_ID, | ||
511 | }, | ||
512 | { | ||
513 | .output = { | ||
514 | .index = 1, | ||
515 | .name = "Component", | ||
516 | .type = V4L2_OUTPUT_TYPE_ANALOG, | ||
517 | .capabilities = V4L2_OUT_CAP_CUSTOM_TIMINGS, | ||
518 | }, | ||
519 | .subdev_name = "adv7343", | ||
520 | .output_route = ADV7343_COMPONENT_ID, | ||
521 | }, | ||
522 | { | ||
523 | .output = { | ||
524 | .index = 2, | ||
525 | .name = "S-Video", | ||
526 | .type = V4L2_OUTPUT_TYPE_ANALOG, | ||
527 | .capabilities = V4L2_OUT_CAP_STD, | ||
528 | .std = V4L2_STD_ALL, | ||
529 | }, | ||
530 | .subdev_name = "adv7343", | ||
531 | .output_route = ADV7343_SVIDEO_ID, | ||
532 | }, | ||
503 | }; | 533 | }; |
504 | 534 | ||
505 | static struct vpif_display_config dm646x_vpif_display_config = { | 535 | static struct vpif_display_config dm646x_vpif_display_config = { |
506 | .set_clock = set_vpif_clock, | 536 | .set_clock = set_vpif_clock, |
507 | .subdevinfo = dm646x_vpif_subdev, | 537 | .subdevinfo = dm646x_vpif_subdev, |
508 | .subdev_count = ARRAY_SIZE(dm646x_vpif_subdev), | 538 | .subdev_count = ARRAY_SIZE(dm646x_vpif_subdev), |
509 | .output = output, | 539 | .chan_config[0] = { |
510 | .output_count = ARRAY_SIZE(output), | 540 | .outputs = dm6467_ch0_outputs, |
541 | .output_count = ARRAY_SIZE(dm6467_ch0_outputs), | ||
542 | }, | ||
511 | .card_name = "DM646x EVM", | 543 | .card_name = "DM646x EVM", |
512 | }; | 544 | }; |
513 | 545 | ||
@@ -601,15 +633,6 @@ static struct vpif_subdev_info vpif_capture_sdev_info[] = { | |||
601 | I2C_BOARD_INFO("tvp5146", 0x5d), | 633 | I2C_BOARD_INFO("tvp5146", 0x5d), |
602 | .platform_data = &tvp5146_pdata, | 634 | .platform_data = &tvp5146_pdata, |
603 | }, | 635 | }, |
604 | .input = INPUT_CVBS_VI2B, | ||
605 | .output = OUTPUT_10BIT_422_EMBEDDED_SYNC, | ||
606 | .can_route = 1, | ||
607 | .vpif_if = { | ||
608 | .if_type = VPIF_IF_BT656, | ||
609 | .hd_pol = 1, | ||
610 | .vd_pol = 1, | ||
611 | .fid_pol = 0, | ||
612 | }, | ||
613 | }, | 636 | }, |
614 | { | 637 | { |
615 | .name = TVP5147_CH1, | 638 | .name = TVP5147_CH1, |
@@ -617,15 +640,6 @@ static struct vpif_subdev_info vpif_capture_sdev_info[] = { | |||
617 | I2C_BOARD_INFO("tvp5146", 0x5c), | 640 | I2C_BOARD_INFO("tvp5146", 0x5c), |
618 | .platform_data = &tvp5146_pdata, | 641 | .platform_data = &tvp5146_pdata, |
619 | }, | 642 | }, |
620 | .input = INPUT_SVIDEO_VI2C_VI1C, | ||
621 | .output = OUTPUT_10BIT_422_EMBEDDED_SYNC, | ||
622 | .can_route = 1, | ||
623 | .vpif_if = { | ||
624 | .if_type = VPIF_IF_BT656, | ||
625 | .hd_pol = 1, | ||
626 | .vd_pol = 1, | ||
627 | .fid_pol = 0, | ||
628 | }, | ||
629 | }, | 643 | }, |
630 | }; | 644 | }; |
631 | 645 | ||
@@ -635,9 +649,12 @@ static const struct vpif_input dm6467_ch0_inputs[] = { | |||
635 | .index = 0, | 649 | .index = 0, |
636 | .name = "Composite", | 650 | .name = "Composite", |
637 | .type = V4L2_INPUT_TYPE_CAMERA, | 651 | .type = V4L2_INPUT_TYPE_CAMERA, |
652 | .capabilities = V4L2_IN_CAP_STD, | ||
638 | .std = TVP514X_STD_ALL, | 653 | .std = TVP514X_STD_ALL, |
639 | }, | 654 | }, |
640 | .subdev_name = TVP5147_CH0, | 655 | .subdev_name = TVP5147_CH0, |
656 | .input_route = INPUT_CVBS_VI2B, | ||
657 | .output_route = OUTPUT_10BIT_422_EMBEDDED_SYNC, | ||
641 | }, | 658 | }, |
642 | }; | 659 | }; |
643 | 660 | ||
@@ -647,9 +664,12 @@ static const struct vpif_input dm6467_ch1_inputs[] = { | |||
647 | .index = 0, | 664 | .index = 0, |
648 | .name = "S-Video", | 665 | .name = "S-Video", |
649 | .type = V4L2_INPUT_TYPE_CAMERA, | 666 | .type = V4L2_INPUT_TYPE_CAMERA, |
667 | .capabilities = V4L2_IN_CAP_STD, | ||
650 | .std = TVP514X_STD_ALL, | 668 | .std = TVP514X_STD_ALL, |
651 | }, | 669 | }, |
652 | .subdev_name = TVP5147_CH1, | 670 | .subdev_name = TVP5147_CH1, |
671 | .input_route = INPUT_SVIDEO_VI2C_VI1C, | ||
672 | .output_route = OUTPUT_10BIT_422_EMBEDDED_SYNC, | ||
653 | }, | 673 | }, |
654 | }; | 674 | }; |
655 | 675 | ||
@@ -661,10 +681,22 @@ static struct vpif_capture_config dm646x_vpif_capture_cfg = { | |||
661 | .chan_config[0] = { | 681 | .chan_config[0] = { |
662 | .inputs = dm6467_ch0_inputs, | 682 | .inputs = dm6467_ch0_inputs, |
663 | .input_count = ARRAY_SIZE(dm6467_ch0_inputs), | 683 | .input_count = ARRAY_SIZE(dm6467_ch0_inputs), |
684 | .vpif_if = { | ||
685 | .if_type = VPIF_IF_BT656, | ||
686 | .hd_pol = 1, | ||
687 | .vd_pol = 1, | ||
688 | .fid_pol = 0, | ||
689 | }, | ||
664 | }, | 690 | }, |
665 | .chan_config[1] = { | 691 | .chan_config[1] = { |
666 | .inputs = dm6467_ch1_inputs, | 692 | .inputs = dm6467_ch1_inputs, |
667 | .input_count = ARRAY_SIZE(dm6467_ch1_inputs), | 693 | .input_count = ARRAY_SIZE(dm6467_ch1_inputs), |
694 | .vpif_if = { | ||
695 | .if_type = VPIF_IF_BT656, | ||
696 | .hd_pol = 1, | ||
697 | .vd_pol = 1, | ||
698 | .fid_pol = 0, | ||
699 | }, | ||
668 | }, | 700 | }, |
669 | }; | 701 | }; |
670 | 702 | ||
diff --git a/arch/arm/mach-davinci/da850.c b/arch/arm/mach-davinci/da850.c index e517e1036b09..b90c172d5541 100644 --- a/arch/arm/mach-davinci/da850.c +++ b/arch/arm/mach-davinci/da850.c | |||
@@ -347,6 +347,13 @@ static struct clk spi1_clk = { | |||
347 | .flags = DA850_CLK_ASYNC3, | 347 | .flags = DA850_CLK_ASYNC3, |
348 | }; | 348 | }; |
349 | 349 | ||
350 | static struct clk vpif_clk = { | ||
351 | .name = "vpif", | ||
352 | .parent = &pll0_sysclk2, | ||
353 | .lpsc = DA850_LPSC1_VPIF, | ||
354 | .gpsc = 1, | ||
355 | }; | ||
356 | |||
350 | static struct clk sata_clk = { | 357 | static struct clk sata_clk = { |
351 | .name = "sata", | 358 | .name = "sata", |
352 | .parent = &pll0_sysclk2, | 359 | .parent = &pll0_sysclk2, |
@@ -397,6 +404,7 @@ static struct clk_lookup da850_clks[] = { | |||
397 | CLK(NULL, "usb20", &usb20_clk), | 404 | CLK(NULL, "usb20", &usb20_clk), |
398 | CLK("spi_davinci.0", NULL, &spi0_clk), | 405 | CLK("spi_davinci.0", NULL, &spi0_clk), |
399 | CLK("spi_davinci.1", NULL, &spi1_clk), | 406 | CLK("spi_davinci.1", NULL, &spi1_clk), |
407 | CLK("vpif", NULL, &vpif_clk), | ||
400 | CLK("ahci", NULL, &sata_clk), | 408 | CLK("ahci", NULL, &sata_clk), |
401 | CLK(NULL, NULL, NULL), | 409 | CLK(NULL, NULL, NULL), |
402 | }; | 410 | }; |
@@ -573,6 +581,46 @@ static const struct mux_config da850_pins[] = { | |||
573 | MUX_CFG(DA850, GPIO6_10, 13, 20, 15, 8, false) | 581 | MUX_CFG(DA850, GPIO6_10, 13, 20, 15, 8, false) |
574 | MUX_CFG(DA850, GPIO6_13, 13, 8, 15, 8, false) | 582 | MUX_CFG(DA850, GPIO6_13, 13, 8, 15, 8, false) |
575 | MUX_CFG(DA850, RTC_ALARM, 0, 28, 15, 2, false) | 583 | MUX_CFG(DA850, RTC_ALARM, 0, 28, 15, 2, false) |
584 | /* VPIF Capture */ | ||
585 | MUX_CFG(DA850, VPIF_DIN0, 15, 4, 15, 1, false) | ||
586 | MUX_CFG(DA850, VPIF_DIN1, 15, 0, 15, 1, false) | ||
587 | MUX_CFG(DA850, VPIF_DIN2, 14, 28, 15, 1, false) | ||
588 | MUX_CFG(DA850, VPIF_DIN3, 14, 24, 15, 1, false) | ||
589 | MUX_CFG(DA850, VPIF_DIN4, 14, 20, 15, 1, false) | ||
590 | MUX_CFG(DA850, VPIF_DIN5, 14, 16, 15, 1, false) | ||
591 | MUX_CFG(DA850, VPIF_DIN6, 14, 12, 15, 1, false) | ||
592 | MUX_CFG(DA850, VPIF_DIN7, 14, 8, 15, 1, false) | ||
593 | MUX_CFG(DA850, VPIF_DIN8, 16, 4, 15, 1, false) | ||
594 | MUX_CFG(DA850, VPIF_DIN9, 16, 0, 15, 1, false) | ||
595 | MUX_CFG(DA850, VPIF_DIN10, 15, 28, 15, 1, false) | ||
596 | MUX_CFG(DA850, VPIF_DIN11, 15, 24, 15, 1, false) | ||
597 | MUX_CFG(DA850, VPIF_DIN12, 15, 20, 15, 1, false) | ||
598 | MUX_CFG(DA850, VPIF_DIN13, 15, 16, 15, 1, false) | ||
599 | MUX_CFG(DA850, VPIF_DIN14, 15, 12, 15, 1, false) | ||
600 | MUX_CFG(DA850, VPIF_DIN15, 15, 8, 15, 1, false) | ||
601 | MUX_CFG(DA850, VPIF_CLKIN0, 14, 0, 15, 1, false) | ||
602 | MUX_CFG(DA850, VPIF_CLKIN1, 14, 4, 15, 1, false) | ||
603 | MUX_CFG(DA850, VPIF_CLKIN2, 19, 8, 15, 1, false) | ||
604 | MUX_CFG(DA850, VPIF_CLKIN3, 19, 16, 15, 1, false) | ||
605 | /* VPIF Display */ | ||
606 | MUX_CFG(DA850, VPIF_DOUT0, 17, 4, 15, 1, false) | ||
607 | MUX_CFG(DA850, VPIF_DOUT1, 17, 0, 15, 1, false) | ||
608 | MUX_CFG(DA850, VPIF_DOUT2, 16, 28, 15, 1, false) | ||
609 | MUX_CFG(DA850, VPIF_DOUT3, 16, 24, 15, 1, false) | ||
610 | MUX_CFG(DA850, VPIF_DOUT4, 16, 20, 15, 1, false) | ||
611 | MUX_CFG(DA850, VPIF_DOUT5, 16, 16, 15, 1, false) | ||
612 | MUX_CFG(DA850, VPIF_DOUT6, 16, 12, 15, 1, false) | ||
613 | MUX_CFG(DA850, VPIF_DOUT7, 16, 8, 15, 1, false) | ||
614 | MUX_CFG(DA850, VPIF_DOUT8, 18, 4, 15, 1, false) | ||
615 | MUX_CFG(DA850, VPIF_DOUT9, 18, 0, 15, 1, false) | ||
616 | MUX_CFG(DA850, VPIF_DOUT10, 17, 28, 15, 1, false) | ||
617 | MUX_CFG(DA850, VPIF_DOUT11, 17, 24, 15, 1, false) | ||
618 | MUX_CFG(DA850, VPIF_DOUT12, 17, 20, 15, 1, false) | ||
619 | MUX_CFG(DA850, VPIF_DOUT13, 17, 16, 15, 1, false) | ||
620 | MUX_CFG(DA850, VPIF_DOUT14, 17, 12, 15, 1, false) | ||
621 | MUX_CFG(DA850, VPIF_DOUT15, 17, 8, 15, 1, false) | ||
622 | MUX_CFG(DA850, VPIF_CLKO2, 19, 12, 15, 1, false) | ||
623 | MUX_CFG(DA850, VPIF_CLKO3, 19, 20, 15, 1, false) | ||
576 | #endif | 624 | #endif |
577 | }; | 625 | }; |
578 | 626 | ||
@@ -595,6 +643,26 @@ const short da850_lcdcntl_pins[] __initconst = { | |||
595 | -1 | 643 | -1 |
596 | }; | 644 | }; |
597 | 645 | ||
646 | const short da850_vpif_capture_pins[] __initdata = { | ||
647 | DA850_VPIF_DIN0, DA850_VPIF_DIN1, DA850_VPIF_DIN2, DA850_VPIF_DIN3, | ||
648 | DA850_VPIF_DIN4, DA850_VPIF_DIN5, DA850_VPIF_DIN6, DA850_VPIF_DIN7, | ||
649 | DA850_VPIF_DIN8, DA850_VPIF_DIN9, DA850_VPIF_DIN10, DA850_VPIF_DIN11, | ||
650 | DA850_VPIF_DIN12, DA850_VPIF_DIN13, DA850_VPIF_DIN14, DA850_VPIF_DIN15, | ||
651 | DA850_VPIF_CLKIN0, DA850_VPIF_CLKIN1, DA850_VPIF_CLKIN2, | ||
652 | DA850_VPIF_CLKIN3, | ||
653 | -1 | ||
654 | }; | ||
655 | |||
656 | const short da850_vpif_display_pins[] __initdata = { | ||
657 | DA850_VPIF_DOUT0, DA850_VPIF_DOUT1, DA850_VPIF_DOUT2, DA850_VPIF_DOUT3, | ||
658 | DA850_VPIF_DOUT4, DA850_VPIF_DOUT5, DA850_VPIF_DOUT6, DA850_VPIF_DOUT7, | ||
659 | DA850_VPIF_DOUT8, DA850_VPIF_DOUT9, DA850_VPIF_DOUT10, | ||
660 | DA850_VPIF_DOUT11, DA850_VPIF_DOUT12, DA850_VPIF_DOUT13, | ||
661 | DA850_VPIF_DOUT14, DA850_VPIF_DOUT15, DA850_VPIF_CLKO2, | ||
662 | DA850_VPIF_CLKO3, | ||
663 | -1 | ||
664 | }; | ||
665 | |||
598 | /* FIQ are pri 0-1; otherwise 2-7, with 7 lowest priority */ | 666 | /* FIQ are pri 0-1; otherwise 2-7, with 7 lowest priority */ |
599 | static u8 da850_default_priorities[DA850_N_CP_INTC_IRQ] = { | 667 | static u8 da850_default_priorities[DA850_N_CP_INTC_IRQ] = { |
600 | [IRQ_DA8XX_COMMTX] = 7, | 668 | [IRQ_DA8XX_COMMTX] = 7, |
@@ -1064,6 +1132,90 @@ no_ddrpll_mem: | |||
1064 | return ret; | 1132 | return ret; |
1065 | } | 1133 | } |
1066 | 1134 | ||
1135 | /* VPIF resource, platform data */ | ||
1136 | static u64 da850_vpif_dma_mask = DMA_BIT_MASK(32); | ||
1137 | |||
1138 | static struct resource da850_vpif_resource[] = { | ||
1139 | { | ||
1140 | .start = DA8XX_VPIF_BASE, | ||
1141 | .end = DA8XX_VPIF_BASE + 0xfff, | ||
1142 | .flags = IORESOURCE_MEM, | ||
1143 | } | ||
1144 | }; | ||
1145 | |||
1146 | static struct platform_device da850_vpif_dev = { | ||
1147 | .name = "vpif", | ||
1148 | .id = -1, | ||
1149 | .dev = { | ||
1150 | .dma_mask = &da850_vpif_dma_mask, | ||
1151 | .coherent_dma_mask = DMA_BIT_MASK(32), | ||
1152 | }, | ||
1153 | .resource = da850_vpif_resource, | ||
1154 | .num_resources = ARRAY_SIZE(da850_vpif_resource), | ||
1155 | }; | ||
1156 | |||
1157 | static struct resource da850_vpif_display_resource[] = { | ||
1158 | { | ||
1159 | .start = IRQ_DA850_VPIFINT, | ||
1160 | .end = IRQ_DA850_VPIFINT, | ||
1161 | .flags = IORESOURCE_IRQ, | ||
1162 | }, | ||
1163 | }; | ||
1164 | |||
1165 | static struct platform_device da850_vpif_display_dev = { | ||
1166 | .name = "vpif_display", | ||
1167 | .id = -1, | ||
1168 | .dev = { | ||
1169 | .dma_mask = &da850_vpif_dma_mask, | ||
1170 | .coherent_dma_mask = DMA_BIT_MASK(32), | ||
1171 | }, | ||
1172 | .resource = da850_vpif_display_resource, | ||
1173 | .num_resources = ARRAY_SIZE(da850_vpif_display_resource), | ||
1174 | }; | ||
1175 | |||
1176 | static struct resource da850_vpif_capture_resource[] = { | ||
1177 | { | ||
1178 | .start = IRQ_DA850_VPIFINT, | ||
1179 | .end = IRQ_DA850_VPIFINT, | ||
1180 | .flags = IORESOURCE_IRQ, | ||
1181 | }, | ||
1182 | { | ||
1183 | .start = IRQ_DA850_VPIFINT, | ||
1184 | .end = IRQ_DA850_VPIFINT, | ||
1185 | .flags = IORESOURCE_IRQ, | ||
1186 | }, | ||
1187 | }; | ||
1188 | |||
1189 | static struct platform_device da850_vpif_capture_dev = { | ||
1190 | .name = "vpif_capture", | ||
1191 | .id = -1, | ||
1192 | .dev = { | ||
1193 | .dma_mask = &da850_vpif_dma_mask, | ||
1194 | .coherent_dma_mask = DMA_BIT_MASK(32), | ||
1195 | }, | ||
1196 | .resource = da850_vpif_capture_resource, | ||
1197 | .num_resources = ARRAY_SIZE(da850_vpif_capture_resource), | ||
1198 | }; | ||
1199 | |||
1200 | int __init da850_register_vpif(void) | ||
1201 | { | ||
1202 | return platform_device_register(&da850_vpif_dev); | ||
1203 | } | ||
1204 | |||
1205 | int __init da850_register_vpif_display(struct vpif_display_config | ||
1206 | *display_config) | ||
1207 | { | ||
1208 | da850_vpif_display_dev.dev.platform_data = display_config; | ||
1209 | return platform_device_register(&da850_vpif_display_dev); | ||
1210 | } | ||
1211 | |||
1212 | int __init da850_register_vpif_capture(struct vpif_capture_config | ||
1213 | *capture_config) | ||
1214 | { | ||
1215 | da850_vpif_capture_dev.dev.platform_data = capture_config; | ||
1216 | return platform_device_register(&da850_vpif_capture_dev); | ||
1217 | } | ||
1218 | |||
1067 | static struct davinci_soc_info davinci_soc_info_da850 = { | 1219 | static struct davinci_soc_info davinci_soc_info_da850 = { |
1068 | .io_desc = da850_io_desc, | 1220 | .io_desc = da850_io_desc, |
1069 | .io_desc_num = ARRAY_SIZE(da850_io_desc), | 1221 | .io_desc_num = ARRAY_SIZE(da850_io_desc), |
diff --git a/arch/arm/mach-davinci/dm644x.c b/arch/arm/mach-davinci/dm644x.c index 0755d466221a..cd0c8b1e1ecf 100644 --- a/arch/arm/mach-davinci/dm644x.c +++ b/arch/arm/mach-davinci/dm644x.c | |||
@@ -701,7 +701,7 @@ static struct resource dm644x_venc_resources[] = { | |||
701 | #define DM644X_VPSS_DACCLKEN BIT(4) | 701 | #define DM644X_VPSS_DACCLKEN BIT(4) |
702 | 702 | ||
703 | static int dm644x_venc_setup_clock(enum vpbe_enc_timings_type type, | 703 | static int dm644x_venc_setup_clock(enum vpbe_enc_timings_type type, |
704 | unsigned int mode) | 704 | unsigned int pclock) |
705 | { | 705 | { |
706 | int ret = 0; | 706 | int ret = 0; |
707 | u32 v = DM644X_VPSS_VENCLKEN; | 707 | u32 v = DM644X_VPSS_VENCLKEN; |
@@ -711,27 +711,18 @@ static int dm644x_venc_setup_clock(enum vpbe_enc_timings_type type, | |||
711 | v |= DM644X_VPSS_DACCLKEN; | 711 | v |= DM644X_VPSS_DACCLKEN; |
712 | writel(v, DAVINCI_SYSMOD_VIRT(SYSMOD_VPSS_CLKCTL)); | 712 | writel(v, DAVINCI_SYSMOD_VIRT(SYSMOD_VPSS_CLKCTL)); |
713 | break; | 713 | break; |
714 | case VPBE_ENC_DV_PRESET: | 714 | case VPBE_ENC_CUSTOM_TIMINGS: |
715 | switch (mode) { | 715 | if (pclock <= 27000000) { |
716 | case V4L2_DV_480P59_94: | ||
717 | case V4L2_DV_576P50: | ||
718 | v |= DM644X_VPSS_MUXSEL_PLL2_MODE | | 716 | v |= DM644X_VPSS_MUXSEL_PLL2_MODE | |
719 | DM644X_VPSS_DACCLKEN; | 717 | DM644X_VPSS_DACCLKEN; |
720 | writel(v, DAVINCI_SYSMOD_VIRT(SYSMOD_VPSS_CLKCTL)); | 718 | writel(v, DAVINCI_SYSMOD_VIRT(SYSMOD_VPSS_CLKCTL)); |
721 | break; | 719 | } else { |
722 | case V4L2_DV_720P60: | ||
723 | case V4L2_DV_1080I60: | ||
724 | case V4L2_DV_1080P30: | ||
725 | /* | 720 | /* |
726 | * For HD, use external clock source since | 721 | * For HD, use external clock source since |
727 | * HD requires higher clock rate | 722 | * HD requires higher clock rate |
728 | */ | 723 | */ |
729 | v |= DM644X_VPSS_MUXSEL_VPBECLK_MODE; | 724 | v |= DM644X_VPSS_MUXSEL_VPBECLK_MODE; |
730 | writel(v, DAVINCI_SYSMOD_VIRT(SYSMOD_VPSS_CLKCTL)); | 725 | writel(v, DAVINCI_SYSMOD_VIRT(SYSMOD_VPSS_CLKCTL)); |
731 | break; | ||
732 | default: | ||
733 | ret = -EINVAL; | ||
734 | break; | ||
735 | } | 726 | } |
736 | break; | 727 | break; |
737 | default: | 728 | default: |
diff --git a/arch/arm/mach-davinci/include/mach/da8xx.h b/arch/arm/mach-davinci/include/mach/da8xx.h index c9ee723c56f3..aaccdc4528fc 100644 --- a/arch/arm/mach-davinci/include/mach/da8xx.h +++ b/arch/arm/mach-davinci/include/mach/da8xx.h | |||
@@ -17,6 +17,7 @@ | |||
17 | #include <linux/davinci_emac.h> | 17 | #include <linux/davinci_emac.h> |
18 | #include <linux/spi/spi.h> | 18 | #include <linux/spi/spi.h> |
19 | #include <linux/platform_data/davinci_asp.h> | 19 | #include <linux/platform_data/davinci_asp.h> |
20 | #include <linux/videodev2.h> | ||
20 | 21 | ||
21 | #include <mach/serial.h> | 22 | #include <mach/serial.h> |
22 | #include <mach/edma.h> | 23 | #include <mach/edma.h> |
@@ -26,6 +27,8 @@ | |||
26 | #include <linux/platform_data/usb-davinci.h> | 27 | #include <linux/platform_data/usb-davinci.h> |
27 | #include <linux/platform_data/spi-davinci.h> | 28 | #include <linux/platform_data/spi-davinci.h> |
28 | 29 | ||
30 | #include <media/davinci/vpif_types.h> | ||
31 | |||
29 | extern void __iomem *da8xx_syscfg0_base; | 32 | extern void __iomem *da8xx_syscfg0_base; |
30 | extern void __iomem *da8xx_syscfg1_base; | 33 | extern void __iomem *da8xx_syscfg1_base; |
31 | 34 | ||
@@ -63,6 +66,7 @@ extern unsigned int da850_max_speed; | |||
63 | #define DA8XX_PLL0_BASE 0x01c11000 | 66 | #define DA8XX_PLL0_BASE 0x01c11000 |
64 | #define DA8XX_TIMER64P0_BASE 0x01c20000 | 67 | #define DA8XX_TIMER64P0_BASE 0x01c20000 |
65 | #define DA8XX_TIMER64P1_BASE 0x01c21000 | 68 | #define DA8XX_TIMER64P1_BASE 0x01c21000 |
69 | #define DA8XX_VPIF_BASE 0x01e17000 | ||
66 | #define DA8XX_GPIO_BASE 0x01e26000 | 70 | #define DA8XX_GPIO_BASE 0x01e26000 |
67 | #define DA8XX_PSC1_BASE 0x01e27000 | 71 | #define DA8XX_PSC1_BASE 0x01e27000 |
68 | #define DA8XX_AEMIF_CS2_BASE 0x60000000 | 72 | #define DA8XX_AEMIF_CS2_BASE 0x60000000 |
@@ -92,6 +96,11 @@ int da8xx_register_cpuidle(void); | |||
92 | void __iomem * __init da8xx_get_mem_ctlr(void); | 96 | void __iomem * __init da8xx_get_mem_ctlr(void); |
93 | int da850_register_pm(struct platform_device *pdev); | 97 | int da850_register_pm(struct platform_device *pdev); |
94 | int __init da850_register_sata(unsigned long refclkpn); | 98 | int __init da850_register_sata(unsigned long refclkpn); |
99 | int __init da850_register_vpif(void); | ||
100 | int __init da850_register_vpif_display | ||
101 | (struct vpif_display_config *display_config); | ||
102 | int __init da850_register_vpif_capture | ||
103 | (struct vpif_capture_config *capture_config); | ||
95 | void da8xx_restart(char mode, const char *cmd); | 104 | void da8xx_restart(char mode, const char *cmd); |
96 | 105 | ||
97 | extern struct platform_device da8xx_serial_device; | 106 | extern struct platform_device da8xx_serial_device; |
@@ -126,6 +135,8 @@ extern const short da830_ecap1_pins[]; | |||
126 | extern const short da830_ecap2_pins[]; | 135 | extern const short da830_ecap2_pins[]; |
127 | extern const short da830_eqep0_pins[]; | 136 | extern const short da830_eqep0_pins[]; |
128 | extern const short da830_eqep1_pins[]; | 137 | extern const short da830_eqep1_pins[]; |
138 | extern const short da850_vpif_capture_pins[]; | ||
139 | extern const short da850_vpif_display_pins[]; | ||
129 | 140 | ||
130 | extern const short da850_i2c0_pins[]; | 141 | extern const short da850_i2c0_pins[]; |
131 | extern const short da850_i2c1_pins[]; | 142 | extern const short da850_i2c1_pins[]; |
diff --git a/arch/arm/mach-davinci/include/mach/mux.h b/arch/arm/mach-davinci/include/mach/mux.h index a7e92fca32e6..9e95b8a1edb6 100644 --- a/arch/arm/mach-davinci/include/mach/mux.h +++ b/arch/arm/mach-davinci/include/mach/mux.h | |||
@@ -928,6 +928,48 @@ enum davinci_da850_index { | |||
928 | DA850_GPIO6_10, | 928 | DA850_GPIO6_10, |
929 | DA850_GPIO6_13, | 929 | DA850_GPIO6_13, |
930 | DA850_RTC_ALARM, | 930 | DA850_RTC_ALARM, |
931 | |||
932 | /* VPIF Capture */ | ||
933 | DA850_VPIF_DIN0, | ||
934 | DA850_VPIF_DIN1, | ||
935 | DA850_VPIF_DIN2, | ||
936 | DA850_VPIF_DIN3, | ||
937 | DA850_VPIF_DIN4, | ||
938 | DA850_VPIF_DIN5, | ||
939 | DA850_VPIF_DIN6, | ||
940 | DA850_VPIF_DIN7, | ||
941 | DA850_VPIF_DIN8, | ||
942 | DA850_VPIF_DIN9, | ||
943 | DA850_VPIF_DIN10, | ||
944 | DA850_VPIF_DIN11, | ||
945 | DA850_VPIF_DIN12, | ||
946 | DA850_VPIF_DIN13, | ||
947 | DA850_VPIF_DIN14, | ||
948 | DA850_VPIF_DIN15, | ||
949 | DA850_VPIF_CLKIN0, | ||
950 | DA850_VPIF_CLKIN1, | ||
951 | DA850_VPIF_CLKIN2, | ||
952 | DA850_VPIF_CLKIN3, | ||
953 | |||
954 | /* VPIF Display */ | ||
955 | DA850_VPIF_DOUT0, | ||
956 | DA850_VPIF_DOUT1, | ||
957 | DA850_VPIF_DOUT2, | ||
958 | DA850_VPIF_DOUT3, | ||
959 | DA850_VPIF_DOUT4, | ||
960 | DA850_VPIF_DOUT5, | ||
961 | DA850_VPIF_DOUT6, | ||
962 | DA850_VPIF_DOUT7, | ||
963 | DA850_VPIF_DOUT8, | ||
964 | DA850_VPIF_DOUT9, | ||
965 | DA850_VPIF_DOUT10, | ||
966 | DA850_VPIF_DOUT11, | ||
967 | DA850_VPIF_DOUT12, | ||
968 | DA850_VPIF_DOUT13, | ||
969 | DA850_VPIF_DOUT14, | ||
970 | DA850_VPIF_DOUT15, | ||
971 | DA850_VPIF_CLKO2, | ||
972 | DA850_VPIF_CLKO3, | ||
931 | }; | 973 | }; |
932 | 974 | ||
933 | enum davinci_tnetv107x_index { | 975 | enum davinci_tnetv107x_index { |
diff --git a/arch/arm/mach-davinci/include/mach/psc.h b/arch/arm/mach-davinci/include/mach/psc.h index 405318e35bf6..40a0027838e8 100644 --- a/arch/arm/mach-davinci/include/mach/psc.h +++ b/arch/arm/mach-davinci/include/mach/psc.h | |||
@@ -166,6 +166,7 @@ | |||
166 | #define DA830_LPSC1_McASP1 8 | 166 | #define DA830_LPSC1_McASP1 8 |
167 | #define DA850_LPSC1_SATA 8 | 167 | #define DA850_LPSC1_SATA 8 |
168 | #define DA830_LPSC1_McASP2 9 | 168 | #define DA830_LPSC1_McASP2 9 |
169 | #define DA850_LPSC1_VPIF 9 | ||
169 | #define DA8XX_LPSC1_SPI1 10 | 170 | #define DA8XX_LPSC1_SPI1 10 |
170 | #define DA8XX_LPSC1_I2C 11 | 171 | #define DA8XX_LPSC1_I2C 11 |
171 | #define DA8XX_LPSC1_UART1 12 | 172 | #define DA8XX_LPSC1_UART1 12 |