Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit e190df24 authored by Arnd Bergmann's avatar Arnd Bergmann
Browse files

Merge tag 'omap-devel-board-for-v3.6' of...

Merge tag 'omap-devel-board-for-v3.6' of git://git.kernel.org/pub/scm/linux/kernel/git/tmlind/linux-omap into next/boards

From Tony Lindgren <tony@atomide.com>:
Board and platform data related changes for omaps

* tag 'omap-devel-board-for-v3.6' of git://git.kernel.org/pub/scm/linux/kernel/git/tmlind/linux-omap

:
  ARM: OMAP3: Fix omap3evm randconfig error introduced by VBUS support
  ARM: OMAP: board-omap4panda: MUX configuration for sys_nirq2
  ARM: OMAP: board-4430sdp: MUX configuration for sys_nirq2
  ARM: OMAP3530evm: set pendown_state and debounce time for ads7846
  ARM: omap3evm: enable VBUS switch for EHCI tranceiver
  ARM: OMAP3EVM: Adding USB internal LDOs board file
  ARM: OMAP3EVM: Add NAND flash definition
  ARM: OMAP3: cm-t35: add tvp5150 decoder support
  ARM: OMAP3: cm-t35: add mt9t001 camera sensor support
  omap2+: add drm device

Signed-off-by: default avatarArnd Bergmann <arnd@arndb.de>
parents 388d037c b103a2e2
Loading
Loading
Loading
Loading
+4 −0
Original line number Diff line number Diff line
@@ -189,6 +189,10 @@ endif
# OMAP2420 MSDI controller integration support ("MMC")
obj-$(CONFIG_SOC_OMAP2420)		+= msdi.o

ifneq ($(CONFIG_DRM_OMAP),)
obj-y					+= drm.o
endif

# Specific board support
obj-$(CONFIG_MACH_OMAP_GENERIC)		+= board-generic.o
obj-$(CONFIG_MACH_OMAP_H4)		+= board-h4.o
+3 −0
Original line number Diff line number Diff line
@@ -821,6 +821,9 @@ static void __init omap_4430sdp_display_init(void)
#ifdef CONFIG_OMAP_MUX
static struct omap_board_mux board_mux[] __initdata = {
	OMAP4_MUX(USBB2_ULPITLL_CLK, OMAP_MUX_MODE4 | OMAP_PIN_OUTPUT),
	/* NIRQ2 for twl6040 */
	OMAP4_MUX(SYS_NIRQ2, OMAP_MUX_MODE0 |
		  OMAP_PIN_INPUT_PULLUP | OMAP_PIN_OFF_WAKEUPENABLE),
	{ .reg_offset = OMAP_MUX_TERMINATOR },
};

+89 −0
Original line number Diff line number Diff line
@@ -490,6 +490,71 @@ static struct twl4030_platform_data cm_t35_twldata = {
	.power		= &cm_t35_power_data,
};

#if defined(CONFIG_VIDEO_OMAP3) || defined(CONFIG_VIDEO_OMAP3_MODULE)
#include <media/omap3isp.h>
#include "devices.h"

static struct i2c_board_info cm_t35_isp_i2c_boardinfo[] = {
	{
		I2C_BOARD_INFO("mt9t001", 0x5d),
	},
	{
		I2C_BOARD_INFO("tvp5150", 0x5c),
	},
};

static struct isp_subdev_i2c_board_info cm_t35_isp_primary_subdevs[] = {
	{
		.board_info = &cm_t35_isp_i2c_boardinfo[0],
		.i2c_adapter_id = 3,
	},
	{ NULL, 0, },
};

static struct isp_subdev_i2c_board_info cm_t35_isp_secondary_subdevs[] = {
	{
		.board_info = &cm_t35_isp_i2c_boardinfo[1],
		.i2c_adapter_id = 3,
	},
	{ NULL, 0, },
};

static struct isp_v4l2_subdevs_group cm_t35_isp_subdevs[] = {
	{
		.subdevs = cm_t35_isp_primary_subdevs,
		.interface = ISP_INTERFACE_PARALLEL,
		.bus = {
			.parallel = {
				.clk_pol = 1,
			},
		},
	},
	{
		.subdevs = cm_t35_isp_secondary_subdevs,
		.interface = ISP_INTERFACE_PARALLEL,
		.bus = {
			.parallel = {
				.clk_pol = 0,
			},
		},
	},
	{ NULL, 0, },
};

static struct isp_platform_data cm_t35_isp_pdata = {
	.subdevs = cm_t35_isp_subdevs,
};

static void __init cm_t35_init_camera(void)
{
	if (omap3_init_camera(&cm_t35_isp_pdata) < 0)
		pr_warn("CM-T3x: Failed registering camera device!\n");
}

#else
static inline void cm_t35_init_camera(void) {}
#endif /* CONFIG_VIDEO_OMAP3 */

static void __init cm_t35_init_i2c(void)
{
	omap3_pmic_get_config(&cm_t35_twldata, TWL_COMMON_PDATA_USB,
@@ -497,6 +562,8 @@ static void __init cm_t35_init_i2c(void)
			      TWL_COMMON_PDATA_AUDIO);

	omap3_pmic_init("tps65930", &cm_t35_twldata);

	omap_register_i2c_bus(3, 400, NULL, 0);
}

#ifdef CONFIG_OMAP_MUX
@@ -574,6 +641,27 @@ static struct omap_board_mux board_mux[] __initdata = {
	OMAP3_MUX(DSS_DATA16, OMAP_MUX_MODE0 | OMAP_PIN_OUTPUT),
	OMAP3_MUX(DSS_DATA17, OMAP_MUX_MODE0 | OMAP_PIN_OUTPUT),

	/* Camera */
	OMAP3_MUX(CAM_HS, OMAP_MUX_MODE0 | OMAP_PIN_INPUT),
	OMAP3_MUX(CAM_VS, OMAP_MUX_MODE0 | OMAP_PIN_INPUT),
	OMAP3_MUX(CAM_XCLKA, OMAP_MUX_MODE0 | OMAP_PIN_INPUT),
	OMAP3_MUX(CAM_PCLK, OMAP_MUX_MODE0 | OMAP_PIN_INPUT),
	OMAP3_MUX(CAM_FLD, OMAP_MUX_MODE0 | OMAP_PIN_INPUT),
	OMAP3_MUX(CAM_D0, OMAP_MUX_MODE0 | OMAP_PIN_INPUT),
	OMAP3_MUX(CAM_D1, OMAP_MUX_MODE0 | OMAP_PIN_INPUT),
	OMAP3_MUX(CAM_D2, OMAP_MUX_MODE0 | OMAP_PIN_INPUT),
	OMAP3_MUX(CAM_D3, OMAP_MUX_MODE0 | OMAP_PIN_INPUT),
	OMAP3_MUX(CAM_D4, OMAP_MUX_MODE0 | OMAP_PIN_INPUT),
	OMAP3_MUX(CAM_D5, OMAP_MUX_MODE0 | OMAP_PIN_INPUT),
	OMAP3_MUX(CAM_D6, OMAP_MUX_MODE0 | OMAP_PIN_INPUT),
	OMAP3_MUX(CAM_D7, OMAP_MUX_MODE0 | OMAP_PIN_INPUT),
	OMAP3_MUX(CAM_D8, OMAP_MUX_MODE0 | OMAP_PIN_INPUT_PULLDOWN),
	OMAP3_MUX(CAM_D9, OMAP_MUX_MODE0 | OMAP_PIN_INPUT_PULLDOWN),
	OMAP3_MUX(CAM_STROBE, OMAP_MUX_MODE0 | OMAP_PIN_INPUT),

	OMAP3_MUX(CAM_D10, OMAP_MUX_MODE4 | OMAP_PIN_INPUT_PULLDOWN),
	OMAP3_MUX(CAM_D11, OMAP_MUX_MODE4 | OMAP_PIN_INPUT_PULLDOWN),

	/* display controls */
	OMAP3_MUX(MCBSP1_FSR, OMAP_MUX_MODE4 | OMAP_PIN_OUTPUT),
	OMAP3_MUX(GPMC_NCS7, OMAP_MUX_MODE4 | OMAP_PIN_OUTPUT),
@@ -646,6 +734,7 @@ static void __init cm_t3x_common_init(void)

	usb_musb_init(NULL);
	cm_t35_init_usbh();
	cm_t35_init_camera();
}

static void __init cm_t35_init(void)
+77 −1
Original line number Diff line number Diff line
@@ -24,6 +24,10 @@
#include <linux/leds.h>
#include <linux/interrupt.h>

#include <linux/mtd/mtd.h>
#include <linux/mtd/partitions.h>
#include <linux/mtd/nand.h>

#include <linux/spi/spi.h>
#include <linux/spi/ads7846.h>
#include <linux/i2c/twl.h>
@@ -43,6 +47,7 @@

#include <plat/board.h>
#include <plat/usb.h>
#include <plat/nand.h>
#include "common.h"
#include <plat/mcspi.h>
#include <video/omapdss.h>
@@ -53,7 +58,6 @@
#include "hsmmc.h"
#include "common-board-devices.h"

#define OMAP3_EVM_TS_GPIO	175
#define OMAP3_EVM_EHCI_VBUS	22
#define OMAP3_EVM_EHCI_SELECT	61

@@ -355,6 +359,19 @@ static int omap3evm_twl_gpio_setup(struct device *dev,

	platform_device_register(&leds_gpio);

	/* Enable VBUS switch by setting TWL4030.GPIO2DIR as output
	 * for starting USB tranceiver
	 */
#ifdef CONFIG_TWL4030_CORE
	if (get_omap3_evm_rev() >= OMAP3EVM_BOARD_GEN_2) {
		u8 val;

		twl_i2c_read_u8(TWL4030_MODULE_GPIO, &val, REG_GPIODATADIR1);
		val |= 0x04; /* TWL4030.GPIO2DIR BIT at GPIODATADIR1(0x9B) */
		twl_i2c_write_u8(TWL4030_MODULE_GPIO, val, REG_GPIODATADIR1);
	}
#endif

	return 0;
}

@@ -461,6 +478,28 @@ struct wl12xx_platform_data omap3evm_wlan_data __initdata = {
};
#endif

/* VAUX2 for USB */
static struct regulator_consumer_supply omap3evm_vaux2_supplies[] = {
	REGULATOR_SUPPLY("VDD_CSIPHY1", "omap3isp"),	/* OMAP ISP */
	REGULATOR_SUPPLY("VDD_CSIPHY2", "omap3isp"),	/* OMAP ISP */
	REGULATOR_SUPPLY("hsusb1", "ehci-omap.0"),
	REGULATOR_SUPPLY("vaux2", NULL),
};

static struct regulator_init_data omap3evm_vaux2 = {
	.constraints = {
		.min_uV		= 2800000,
		.max_uV		= 2800000,
		.apply_uV	= true,
		.valid_modes_mask	= REGULATOR_MODE_NORMAL
					| REGULATOR_MODE_STANDBY,
		.valid_ops_mask		= REGULATOR_CHANGE_MODE
					| REGULATOR_CHANGE_STATUS,
	},
	.num_consumer_supplies		= ARRAY_SIZE(omap3evm_vaux2_supplies),
	.consumer_supplies		= omap3evm_vaux2_supplies,
};

static struct twl4030_platform_data omap3evm_twldata = {
	/* platform_data for children goes here */
	.keypad		= &omap3evm_kp_data,
@@ -607,6 +646,37 @@ static struct regulator_consumer_supply dummy_supplies[] = {
	REGULATOR_SUPPLY("vdd33a", "smsc911x.0"),
};

static struct mtd_partition omap3evm_nand_partitions[] = {
	/* All the partition sizes are listed in terms of NAND block size */
	{
		.name           = "X-Loader",
		.offset         = 0,
		.size           = 4*(SZ_128K),
		.mask_flags     = MTD_WRITEABLE
	},
	{
		.name           = "U-Boot",
		.offset         = MTDPART_OFS_APPEND,
		.size           = 14*(SZ_128K),
		.mask_flags     = MTD_WRITEABLE
	},
	{
		.name           = "U-Boot Env",
		.offset         = MTDPART_OFS_APPEND,
		.size           = 2*(SZ_128K)
	},
	{
		.name           = "Kernel",
		.offset         = MTDPART_OFS_APPEND,
		.size           = 40*(SZ_128K)
	},
	{
		.name           = "File system",
		.size           = MTDPART_SIZ_FULL,
		.offset         = MTDPART_OFS_APPEND,
	},
};

static void __init omap3_evm_init(void)
{
	struct omap_board_mux *obm;
@@ -623,6 +693,9 @@ static void __init omap3_evm_init(void)
	omap_mux_init_gpio(63, OMAP_PIN_INPUT);
	omap_hsmmc_init(mmc);

	if (get_omap3_evm_rev() >= OMAP3EVM_BOARD_GEN_2)
		omap3evm_twldata.vaux2 = &omap3evm_vaux2;

	omap3_evm_i2c_init();

	omap_display_init(&omap3_evm_dss_data);
@@ -656,6 +729,9 @@ static void __init omap3_evm_init(void)
	}
	usb_musb_init(&musb_board_data);
	usbhs_init(&usbhs_bdata);
	omap_nand_flash_init(NAND_BUSWIDTH_16, omap3evm_nand_partitions,
			     ARRAY_SIZE(omap3evm_nand_partitions));

	omap_ads7846_init(1, OMAP3_EVM_TS_GPIO, 310, NULL);
	omap3evm_init_smsc911x();
	omap3_evm_display_init();
+3 −0
Original line number Diff line number Diff line
@@ -379,6 +379,9 @@ static struct omap_board_mux board_mux[] __initdata = {
	OMAP4_MUX(DPM_EMU18, OMAP_PIN_OUTPUT | OMAP_MUX_MODE5),
	/* dispc2_data0 */
	OMAP4_MUX(DPM_EMU19, OMAP_PIN_OUTPUT | OMAP_MUX_MODE5),
	/* NIRQ2 for twl6040 */
	OMAP4_MUX(SYS_NIRQ2, OMAP_MUX_MODE0 |
		  OMAP_PIN_INPUT_PULLUP | OMAP_PIN_OFF_WAKEUPENABLE),
	{ .reg_offset = OMAP_MUX_TERMINATOR },
};

Loading