aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--arch/arm/mach-omap2/Makefile4
-rw-r--r--arch/arm/mach-omap2/board-4430sdp.c3
-rw-r--r--arch/arm/mach-omap2/board-cm-t35.c89
-rw-r--r--arch/arm/mach-omap2/board-omap3evm.c78
-rw-r--r--arch/arm/mach-omap2/board-omap4panda.c3
-rw-r--r--arch/arm/mach-omap2/common-board-devices.c18
-rw-r--r--arch/arm/mach-omap2/common-board-devices.h1
-rw-r--r--arch/arm/mach-omap2/drm.c61
-rw-r--r--drivers/staging/omapdrm/omap_drv.h2
-rw-r--r--include/linux/platform_data/omap_drm.h (renamed from drivers/staging/omapdrm/omap_priv.h)19
10 files changed, 263 insertions, 15 deletions
diff --git a/arch/arm/mach-omap2/Makefile b/arch/arm/mach-omap2/Makefile
index fa742f3c262..a636cdc0887 100644
--- a/arch/arm/mach-omap2/Makefile
+++ b/arch/arm/mach-omap2/Makefile
@@ -189,6 +189,10 @@ endif
189# OMAP2420 MSDI controller integration support ("MMC") 189# OMAP2420 MSDI controller integration support ("MMC")
190obj-$(CONFIG_SOC_OMAP2420) += msdi.o 190obj-$(CONFIG_SOC_OMAP2420) += msdi.o
191 191
192ifneq ($(CONFIG_DRM_OMAP),)
193obj-y += drm.o
194endif
195
192# Specific board support 196# Specific board support
193obj-$(CONFIG_MACH_OMAP_GENERIC) += board-generic.o 197obj-$(CONFIG_MACH_OMAP_GENERIC) += board-generic.o
194obj-$(CONFIG_MACH_OMAP_H4) += board-h4.o 198obj-$(CONFIG_MACH_OMAP_H4) += board-h4.o
diff --git a/arch/arm/mach-omap2/board-4430sdp.c b/arch/arm/mach-omap2/board-4430sdp.c
index 8e17284a803..ad8a7d94afc 100644
--- a/arch/arm/mach-omap2/board-4430sdp.c
+++ b/arch/arm/mach-omap2/board-4430sdp.c
@@ -821,6 +821,9 @@ static void __init omap_4430sdp_display_init(void)
821#ifdef CONFIG_OMAP_MUX 821#ifdef CONFIG_OMAP_MUX
822static struct omap_board_mux board_mux[] __initdata = { 822static struct omap_board_mux board_mux[] __initdata = {
823 OMAP4_MUX(USBB2_ULPITLL_CLK, OMAP_MUX_MODE4 | OMAP_PIN_OUTPUT), 823 OMAP4_MUX(USBB2_ULPITLL_CLK, OMAP_MUX_MODE4 | OMAP_PIN_OUTPUT),
824 /* NIRQ2 for twl6040 */
825 OMAP4_MUX(SYS_NIRQ2, OMAP_MUX_MODE0 |
826 OMAP_PIN_INPUT_PULLUP | OMAP_PIN_OFF_WAKEUPENABLE),
824 { .reg_offset = OMAP_MUX_TERMINATOR }, 827 { .reg_offset = OMAP_MUX_TERMINATOR },
825}; 828};
826 829
diff --git a/arch/arm/mach-omap2/board-cm-t35.c b/arch/arm/mach-omap2/board-cm-t35.c
index ded100c80a9..97d719047af 100644
--- a/arch/arm/mach-omap2/board-cm-t35.c
+++ b/arch/arm/mach-omap2/board-cm-t35.c
@@ -490,6 +490,71 @@ static struct twl4030_platform_data cm_t35_twldata = {
490 .power = &cm_t35_power_data, 490 .power = &cm_t35_power_data,
491}; 491};
492 492
493#if defined(CONFIG_VIDEO_OMAP3) || defined(CONFIG_VIDEO_OMAP3_MODULE)
494#include <media/omap3isp.h>
495#include "devices.h"
496
497static struct i2c_board_info cm_t35_isp_i2c_boardinfo[] = {
498 {
499 I2C_BOARD_INFO("mt9t001", 0x5d),
500 },
501 {
502 I2C_BOARD_INFO("tvp5150", 0x5c),
503 },
504};
505
506static struct isp_subdev_i2c_board_info cm_t35_isp_primary_subdevs[] = {
507 {
508 .board_info = &cm_t35_isp_i2c_boardinfo[0],
509 .i2c_adapter_id = 3,
510 },
511 { NULL, 0, },
512};
513
514static struct isp_subdev_i2c_board_info cm_t35_isp_secondary_subdevs[] = {
515 {
516 .board_info = &cm_t35_isp_i2c_boardinfo[1],
517 .i2c_adapter_id = 3,
518 },
519 { NULL, 0, },
520};
521
522static struct isp_v4l2_subdevs_group cm_t35_isp_subdevs[] = {
523 {
524 .subdevs = cm_t35_isp_primary_subdevs,
525 .interface = ISP_INTERFACE_PARALLEL,
526 .bus = {
527 .parallel = {
528 .clk_pol = 1,
529 },
530 },
531 },
532 {
533 .subdevs = cm_t35_isp_secondary_subdevs,
534 .interface = ISP_INTERFACE_PARALLEL,
535 .bus = {
536 .parallel = {
537 .clk_pol = 0,
538 },
539 },
540 },
541 { NULL, 0, },
542};
543
544static struct isp_platform_data cm_t35_isp_pdata = {
545 .subdevs = cm_t35_isp_subdevs,
546};
547
548static void __init cm_t35_init_camera(void)
549{
550 if (omap3_init_camera(&cm_t35_isp_pdata) < 0)
551 pr_warn("CM-T3x: Failed registering camera device!\n");
552}
553
554#else
555static inline void cm_t35_init_camera(void) {}
556#endif /* CONFIG_VIDEO_OMAP3 */
557
493static void __init cm_t35_init_i2c(void) 558static void __init cm_t35_init_i2c(void)
494{ 559{
495 omap3_pmic_get_config(&cm_t35_twldata, TWL_COMMON_PDATA_USB, 560 omap3_pmic_get_config(&cm_t35_twldata, TWL_COMMON_PDATA_USB,
@@ -497,6 +562,8 @@ static void __init cm_t35_init_i2c(void)
497 TWL_COMMON_PDATA_AUDIO); 562 TWL_COMMON_PDATA_AUDIO);
498 563
499 omap3_pmic_init("tps65930", &cm_t35_twldata); 564 omap3_pmic_init("tps65930", &cm_t35_twldata);
565
566 omap_register_i2c_bus(3, 400, NULL, 0);
500} 567}
501 568
502#ifdef CONFIG_OMAP_MUX 569#ifdef CONFIG_OMAP_MUX
@@ -574,6 +641,27 @@ static struct omap_board_mux board_mux[] __initdata = {
574 OMAP3_MUX(DSS_DATA16, OMAP_MUX_MODE0 | OMAP_PIN_OUTPUT), 641 OMAP3_MUX(DSS_DATA16, OMAP_MUX_MODE0 | OMAP_PIN_OUTPUT),
575 OMAP3_MUX(DSS_DATA17, OMAP_MUX_MODE0 | OMAP_PIN_OUTPUT), 642 OMAP3_MUX(DSS_DATA17, OMAP_MUX_MODE0 | OMAP_PIN_OUTPUT),
576 643
644 /* Camera */
645 OMAP3_MUX(CAM_HS, OMAP_MUX_MODE0 | OMAP_PIN_INPUT),
646 OMAP3_MUX(CAM_VS, OMAP_MUX_MODE0 | OMAP_PIN_INPUT),
647 OMAP3_MUX(CAM_XCLKA, OMAP_MUX_MODE0 | OMAP_PIN_INPUT),
648 OMAP3_MUX(CAM_PCLK, OMAP_MUX_MODE0 | OMAP_PIN_INPUT),
649 OMAP3_MUX(CAM_FLD, OMAP_MUX_MODE0 | OMAP_PIN_INPUT),
650 OMAP3_MUX(CAM_D0, OMAP_MUX_MODE0 | OMAP_PIN_INPUT),
651 OMAP3_MUX(CAM_D1, OMAP_MUX_MODE0 | OMAP_PIN_INPUT),
652 OMAP3_MUX(CAM_D2, OMAP_MUX_MODE0 | OMAP_PIN_INPUT),
653 OMAP3_MUX(CAM_D3, OMAP_MUX_MODE0 | OMAP_PIN_INPUT),
654 OMAP3_MUX(CAM_D4, OMAP_MUX_MODE0 | OMAP_PIN_INPUT),
655 OMAP3_MUX(CAM_D5, OMAP_MUX_MODE0 | OMAP_PIN_INPUT),
656 OMAP3_MUX(CAM_D6, OMAP_MUX_MODE0 | OMAP_PIN_INPUT),
657 OMAP3_MUX(CAM_D7, OMAP_MUX_MODE0 | OMAP_PIN_INPUT),
658 OMAP3_MUX(CAM_D8, OMAP_MUX_MODE0 | OMAP_PIN_INPUT_PULLDOWN),
659 OMAP3_MUX(CAM_D9, OMAP_MUX_MODE0 | OMAP_PIN_INPUT_PULLDOWN),
660 OMAP3_MUX(CAM_STROBE, OMAP_MUX_MODE0 | OMAP_PIN_INPUT),
661
662 OMAP3_MUX(CAM_D10, OMAP_MUX_MODE4 | OMAP_PIN_INPUT_PULLDOWN),
663 OMAP3_MUX(CAM_D11, OMAP_MUX_MODE4 | OMAP_PIN_INPUT_PULLDOWN),
664
577 /* display controls */ 665 /* display controls */
578 OMAP3_MUX(MCBSP1_FSR, OMAP_MUX_MODE4 | OMAP_PIN_OUTPUT), 666 OMAP3_MUX(MCBSP1_FSR, OMAP_MUX_MODE4 | OMAP_PIN_OUTPUT),
579 OMAP3_MUX(GPMC_NCS7, OMAP_MUX_MODE4 | OMAP_PIN_OUTPUT), 667 OMAP3_MUX(GPMC_NCS7, OMAP_MUX_MODE4 | OMAP_PIN_OUTPUT),
@@ -646,6 +734,7 @@ static void __init cm_t3x_common_init(void)
646 734
647 usb_musb_init(NULL); 735 usb_musb_init(NULL);
648 cm_t35_init_usbh(); 736 cm_t35_init_usbh();
737 cm_t35_init_camera();
649} 738}
650 739
651static void __init cm_t35_init(void) 740static void __init cm_t35_init(void)
diff --git a/arch/arm/mach-omap2/board-omap3evm.c b/arch/arm/mach-omap2/board-omap3evm.c
index 639bd07ea38..ef230a0eb5e 100644
--- a/arch/arm/mach-omap2/board-omap3evm.c
+++ b/arch/arm/mach-omap2/board-omap3evm.c
@@ -24,6 +24,10 @@
24#include <linux/leds.h> 24#include <linux/leds.h>
25#include <linux/interrupt.h> 25#include <linux/interrupt.h>
26 26
27#include <linux/mtd/mtd.h>
28#include <linux/mtd/partitions.h>
29#include <linux/mtd/nand.h>
30
27#include <linux/spi/spi.h> 31#include <linux/spi/spi.h>
28#include <linux/spi/ads7846.h> 32#include <linux/spi/ads7846.h>
29#include <linux/i2c/twl.h> 33#include <linux/i2c/twl.h>
@@ -43,6 +47,7 @@
43 47
44#include <plat/board.h> 48#include <plat/board.h>
45#include <plat/usb.h> 49#include <plat/usb.h>
50#include <plat/nand.h>
46#include "common.h" 51#include "common.h"
47#include <plat/mcspi.h> 52#include <plat/mcspi.h>
48#include <video/omapdss.h> 53#include <video/omapdss.h>
@@ -53,7 +58,6 @@
53#include "hsmmc.h" 58#include "hsmmc.h"
54#include "common-board-devices.h" 59#include "common-board-devices.h"
55 60
56#define OMAP3_EVM_TS_GPIO 175
57#define OMAP3_EVM_EHCI_VBUS 22 61#define OMAP3_EVM_EHCI_VBUS 22
58#define OMAP3_EVM_EHCI_SELECT 61 62#define OMAP3_EVM_EHCI_SELECT 61
59 63
@@ -355,6 +359,19 @@ static int omap3evm_twl_gpio_setup(struct device *dev,
355 359
356 platform_device_register(&leds_gpio); 360 platform_device_register(&leds_gpio);
357 361
362 /* Enable VBUS switch by setting TWL4030.GPIO2DIR as output
363 * for starting USB tranceiver
364 */
365#ifdef CONFIG_TWL4030_CORE
366 if (get_omap3_evm_rev() >= OMAP3EVM_BOARD_GEN_2) {
367 u8 val;
368
369 twl_i2c_read_u8(TWL4030_MODULE_GPIO, &val, REG_GPIODATADIR1);
370 val |= 0x04; /* TWL4030.GPIO2DIR BIT at GPIODATADIR1(0x9B) */
371 twl_i2c_write_u8(TWL4030_MODULE_GPIO, val, REG_GPIODATADIR1);
372 }
373#endif
374
358 return 0; 375 return 0;
359} 376}
360 377
@@ -461,6 +478,28 @@ struct wl12xx_platform_data omap3evm_wlan_data __initdata = {
461}; 478};
462#endif 479#endif
463 480
481/* VAUX2 for USB */
482static struct regulator_consumer_supply omap3evm_vaux2_supplies[] = {
483 REGULATOR_SUPPLY("VDD_CSIPHY1", "omap3isp"), /* OMAP ISP */
484 REGULATOR_SUPPLY("VDD_CSIPHY2", "omap3isp"), /* OMAP ISP */
485 REGULATOR_SUPPLY("hsusb1", "ehci-omap.0"),
486 REGULATOR_SUPPLY("vaux2", NULL),
487};
488
489static struct regulator_init_data omap3evm_vaux2 = {
490 .constraints = {
491 .min_uV = 2800000,
492 .max_uV = 2800000,
493 .apply_uV = true,
494 .valid_modes_mask = REGULATOR_MODE_NORMAL
495 | REGULATOR_MODE_STANDBY,
496 .valid_ops_mask = REGULATOR_CHANGE_MODE
497 | REGULATOR_CHANGE_STATUS,
498 },
499 .num_consumer_supplies = ARRAY_SIZE(omap3evm_vaux2_supplies),
500 .consumer_supplies = omap3evm_vaux2_supplies,
501};
502
464static struct twl4030_platform_data omap3evm_twldata = { 503static struct twl4030_platform_data omap3evm_twldata = {
465 /* platform_data for children goes here */ 504 /* platform_data for children goes here */
466 .keypad = &omap3evm_kp_data, 505 .keypad = &omap3evm_kp_data,
@@ -607,6 +646,37 @@ static struct regulator_consumer_supply dummy_supplies[] = {
607 REGULATOR_SUPPLY("vdd33a", "smsc911x.0"), 646 REGULATOR_SUPPLY("vdd33a", "smsc911x.0"),
608}; 647};
609 648
649static struct mtd_partition omap3evm_nand_partitions[] = {
650 /* All the partition sizes are listed in terms of NAND block size */
651 {
652 .name = "X-Loader",
653 .offset = 0,
654 .size = 4*(SZ_128K),
655 .mask_flags = MTD_WRITEABLE
656 },
657 {
658 .name = "U-Boot",
659 .offset = MTDPART_OFS_APPEND,
660 .size = 14*(SZ_128K),
661 .mask_flags = MTD_WRITEABLE
662 },
663 {
664 .name = "U-Boot Env",
665 .offset = MTDPART_OFS_APPEND,
666 .size = 2*(SZ_128K)
667 },
668 {
669 .name = "Kernel",
670 .offset = MTDPART_OFS_APPEND,
671 .size = 40*(SZ_128K)
672 },
673 {
674 .name = "File system",
675 .size = MTDPART_SIZ_FULL,
676 .offset = MTDPART_OFS_APPEND,
677 },
678};
679
610static void __init omap3_evm_init(void) 680static void __init omap3_evm_init(void)
611{ 681{
612 struct omap_board_mux *obm; 682 struct omap_board_mux *obm;
@@ -623,6 +693,9 @@ static void __init omap3_evm_init(void)
623 omap_mux_init_gpio(63, OMAP_PIN_INPUT); 693 omap_mux_init_gpio(63, OMAP_PIN_INPUT);
624 omap_hsmmc_init(mmc); 694 omap_hsmmc_init(mmc);
625 695
696 if (get_omap3_evm_rev() >= OMAP3EVM_BOARD_GEN_2)
697 omap3evm_twldata.vaux2 = &omap3evm_vaux2;
698
626 omap3_evm_i2c_init(); 699 omap3_evm_i2c_init();
627 700
628 omap_display_init(&omap3_evm_dss_data); 701 omap_display_init(&omap3_evm_dss_data);
@@ -656,6 +729,9 @@ static void __init omap3_evm_init(void)
656 } 729 }
657 usb_musb_init(&musb_board_data); 730 usb_musb_init(&musb_board_data);
658 usbhs_init(&usbhs_bdata); 731 usbhs_init(&usbhs_bdata);
732 omap_nand_flash_init(NAND_BUSWIDTH_16, omap3evm_nand_partitions,
733 ARRAY_SIZE(omap3evm_nand_partitions));
734
659 omap_ads7846_init(1, OMAP3_EVM_TS_GPIO, 310, NULL); 735 omap_ads7846_init(1, OMAP3_EVM_TS_GPIO, 310, NULL);
660 omap3evm_init_smsc911x(); 736 omap3evm_init_smsc911x();
661 omap3_evm_display_init(); 737 omap3_evm_display_init();
diff --git a/arch/arm/mach-omap2/board-omap4panda.c b/arch/arm/mach-omap2/board-omap4panda.c
index 982fb2622ab..b627cdc12b8 100644
--- a/arch/arm/mach-omap2/board-omap4panda.c
+++ b/arch/arm/mach-omap2/board-omap4panda.c
@@ -379,6 +379,9 @@ static struct omap_board_mux board_mux[] __initdata = {
379 OMAP4_MUX(DPM_EMU18, OMAP_PIN_OUTPUT | OMAP_MUX_MODE5), 379 OMAP4_MUX(DPM_EMU18, OMAP_PIN_OUTPUT | OMAP_MUX_MODE5),
380 /* dispc2_data0 */ 380 /* dispc2_data0 */
381 OMAP4_MUX(DPM_EMU19, OMAP_PIN_OUTPUT | OMAP_MUX_MODE5), 381 OMAP4_MUX(DPM_EMU19, OMAP_PIN_OUTPUT | OMAP_MUX_MODE5),
382 /* NIRQ2 for twl6040 */
383 OMAP4_MUX(SYS_NIRQ2, OMAP_MUX_MODE0 |
384 OMAP_PIN_INPUT_PULLUP | OMAP_PIN_OFF_WAKEUPENABLE),
382 { .reg_offset = OMAP_MUX_TERMINATOR }, 385 { .reg_offset = OMAP_MUX_TERMINATOR },
383}; 386};
384 387
diff --git a/arch/arm/mach-omap2/common-board-devices.c b/arch/arm/mach-omap2/common-board-devices.c
index 1706ebcec08..4ba070e1288 100644
--- a/arch/arm/mach-omap2/common-board-devices.c
+++ b/arch/arm/mach-omap2/common-board-devices.c
@@ -35,6 +35,16 @@ static struct omap2_mcspi_device_config ads7846_mcspi_config = {
35 .turbo_mode = 0, 35 .turbo_mode = 0,
36}; 36};
37 37
38/*
39 * ADS7846 driver maybe request a gpio according to the value
40 * of pdata->get_pendown_state, but we have done this. So set
41 * get_pendown_state to avoid twice gpio requesting.
42 */
43static int omap3_get_pendown_state(void)
44{
45 return !gpio_get_value(OMAP3_EVM_TS_GPIO);
46}
47
38static struct ads7846_platform_data ads7846_config = { 48static struct ads7846_platform_data ads7846_config = {
39 .x_max = 0x0fff, 49 .x_max = 0x0fff,
40 .y_max = 0x0fff, 50 .y_max = 0x0fff,
@@ -45,6 +55,7 @@ static struct ads7846_platform_data ads7846_config = {
45 .debounce_rep = 1, 55 .debounce_rep = 1,
46 .gpio_pendown = -EINVAL, 56 .gpio_pendown = -EINVAL,
47 .keep_vref_on = 1, 57 .keep_vref_on = 1,
58 .get_pendown_state = &omap3_get_pendown_state,
48}; 59};
49 60
50static struct spi_board_info ads7846_spi_board_info __initdata = { 61static struct spi_board_info ads7846_spi_board_info __initdata = {
@@ -63,14 +74,17 @@ void __init omap_ads7846_init(int bus_num, int gpio_pendown, int gpio_debounce,
63 struct spi_board_info *spi_bi = &ads7846_spi_board_info; 74 struct spi_board_info *spi_bi = &ads7846_spi_board_info;
64 int err; 75 int err;
65 76
66 if (board_pdata && board_pdata->get_pendown_state) { 77 if (gpio_pendown) {
67 err = gpio_request_one(gpio_pendown, GPIOF_IN, "TSPenDown"); 78 err = gpio_request_one(gpio_pendown, GPIOF_IN, "TSPenDown");
68 if (err) { 79 if (err) {
69 pr_err("Couldn't obtain gpio for TSPenDown: %d\n", err); 80 pr_err("Couldn't obtain gpio for TSPenDown: %d\n", err);
70 return; 81 return;
71 } 82 }
72 gpio_export(gpio_pendown, 0);
73 83
84 /* TS GPIOPendown doesn't allow user to change the direction */
85 gpio_export(gpio_pendown, false);
86
87 /* Set proper debouce time for ads7846. */
74 if (gpio_debounce) 88 if (gpio_debounce)
75 gpio_set_debounce(gpio_pendown, gpio_debounce); 89 gpio_set_debounce(gpio_pendown, gpio_debounce);
76 } 90 }
diff --git a/arch/arm/mach-omap2/common-board-devices.h b/arch/arm/mach-omap2/common-board-devices.h
index a0b4a42836a..4c4ef6a6166 100644
--- a/arch/arm/mach-omap2/common-board-devices.h
+++ b/arch/arm/mach-omap2/common-board-devices.h
@@ -4,6 +4,7 @@
4#include "twl-common.h" 4#include "twl-common.h"
5 5
6#define NAND_BLOCK_SIZE SZ_128K 6#define NAND_BLOCK_SIZE SZ_128K
7#define OMAP3_EVM_TS_GPIO 175
7 8
8struct mtd_partition; 9struct mtd_partition;
9struct ads7846_platform_data; 10struct ads7846_platform_data;
diff --git a/arch/arm/mach-omap2/drm.c b/arch/arm/mach-omap2/drm.c
new file mode 100644
index 00000000000..72e0f01b715
--- /dev/null
+++ b/arch/arm/mach-omap2/drm.c
@@ -0,0 +1,61 @@
1/*
2 * DRM/KMS device registration for TI OMAP platforms
3 *
4 * Copyright (C) 2012 Texas Instruments
5 * Author: Rob Clark <rob.clark@linaro.org>
6 *
7 * This program is free software; you can redistribute it and/or modify it
8 * under the terms of the GNU General Public License version 2 as published by
9 * the Free Software Foundation.
10 *
11 * This program is distributed in the hope that it will be useful, but WITHOUT
12 * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
13 * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for
14 * more details.
15 *
16 * You should have received a copy of the GNU General Public License along with
17 * this program. If not, see <http://www.gnu.org/licenses/>.
18 */
19
20#include <linux/module.h>
21#include <linux/kernel.h>
22#include <linux/mm.h>
23#include <linux/init.h>
24#include <linux/platform_device.h>
25#include <linux/dma-mapping.h>
26
27#include <plat/omap_device.h>
28#include <plat/omap_hwmod.h>
29
30#if defined(CONFIG_DRM_OMAP) || (CONFIG_DRM_OMAP_MODULE)
31
32static struct platform_device omap_drm_device = {
33 .dev = {
34 .coherent_dma_mask = DMA_BIT_MASK(32),
35 },
36 .name = "omapdrm",
37 .id = 0,
38};
39
40static int __init omap_init_drm(void)
41{
42 struct omap_hwmod *oh = NULL;
43 struct platform_device *pdev;
44
45 /* lookup and populate the DMM information, if present - OMAP4+ */
46 oh = omap_hwmod_lookup("dmm");
47
48 if (oh) {
49 pdev = omap_device_build(oh->name, -1, oh, NULL, 0, NULL, 0,
50 false);
51 WARN(IS_ERR(pdev), "Could not build omap_device for %s\n",
52 oh->name);
53 }
54
55 return platform_device_register(&omap_drm_device);
56
57}
58
59arch_initcall(omap_init_drm);
60
61#endif
diff --git a/drivers/staging/omapdrm/omap_drv.h b/drivers/staging/omapdrm/omap_drv.h
index f238d574da0..2092a9167d2 100644
--- a/drivers/staging/omapdrm/omap_drv.h
+++ b/drivers/staging/omapdrm/omap_drv.h
@@ -25,8 +25,8 @@
25#include <linux/types.h> 25#include <linux/types.h>
26#include <drm/drmP.h> 26#include <drm/drmP.h>
27#include <drm/drm_crtc_helper.h> 27#include <drm/drm_crtc_helper.h>
28#include <linux/platform_data/omap_drm.h>
28#include "omap_drm.h" 29#include "omap_drm.h"
29#include "omap_priv.h"
30 30
31#define DBG(fmt, ...) DRM_DEBUG(fmt"\n", ##__VA_ARGS__) 31#define DBG(fmt, ...) DRM_DEBUG(fmt"\n", ##__VA_ARGS__)
32#define VERB(fmt, ...) if (0) DRM_DEBUG(fmt, ##__VA_ARGS__) /* verbose debug */ 32#define VERB(fmt, ...) if (0) DRM_DEBUG(fmt, ##__VA_ARGS__) /* verbose debug */
diff --git a/drivers/staging/omapdrm/omap_priv.h b/include/linux/platform_data/omap_drm.h
index ef644144714..3da73bdc203 100644
--- a/drivers/staging/omapdrm/omap_priv.h
+++ b/include/linux/platform_data/omap_drm.h
@@ -1,8 +1,8 @@
1/* 1/*
2 * include/drm/omap_priv.h 2 * DRM/KMS platform data for TI OMAP platforms
3 * 3 *
4 * Copyright (C) 2011 Texas Instruments 4 * Copyright (C) 2012 Texas Instruments
5 * Author: Rob Clark <rob@ti.com> 5 * Author: Rob Clark <rob.clark@linaro.org>
6 * 6 *
7 * This program is free software; you can redistribute it and/or modify it 7 * This program is free software; you can redistribute it and/or modify it
8 * under the terms of the GNU General Public License version 2 as published by 8 * under the terms of the GNU General Public License version 2 as published by
@@ -17,13 +17,11 @@
17 * this program. If not, see <http://www.gnu.org/licenses/>. 17 * this program. If not, see <http://www.gnu.org/licenses/>.
18 */ 18 */
19 19
20#ifndef __OMAP_PRIV_H__ 20#ifndef __PLATFORM_DATA_OMAP_DRM_H__
21#define __OMAP_PRIV_H__ 21#define __PLATFORM_DATA_OMAP_DRM_H__
22 22
23/* Non-userspace facing APIs 23/*
24 */ 24 * Optional platform data to configure the default configuration of which
25
26/* optional platform data to configure the default configuration of which
27 * pipes/overlays/CRTCs are used.. if this is not provided, then instead the 25 * pipes/overlays/CRTCs are used.. if this is not provided, then instead the
28 * first CONFIG_DRM_OMAP_NUM_CRTCS are used, and they are each connected to 26 * first CONFIG_DRM_OMAP_NUM_CRTCS are used, and they are each connected to
29 * one manager, with priority given to managers that are connected to 27 * one manager, with priority given to managers that are connected to
@@ -49,7 +47,6 @@ struct omap_kms_platform_data {
49 47
50struct omap_drm_platform_data { 48struct omap_drm_platform_data {
51 struct omap_kms_platform_data *kms_pdata; 49 struct omap_kms_platform_data *kms_pdata;
52 struct omap_dmm_platform_data *dmm_pdata;
53}; 50};
54 51
55#endif /* __OMAP_DRM_H__ */ 52#endif /* __PLATFORM_DATA_OMAP_DRM_H__ */