Beispiel #1
0
static struct regulator_consumer_supply hdmi_fixed_consumer =
	REGULATOR_SUPPLY("hdmi-en", "exynos4-hdmi");

static struct regulator_init_data hdmi_fixed_voltage_init_data = {
	.constraints		= {
		.name		= "HDMI_5V",
		.valid_ops_mask	= REGULATOR_CHANGE_STATUS,
	},
	.num_consumer_supplies	= 1,
	.consumer_supplies	= &hdmi_fixed_consumer,
};

static struct fixed_voltage_config hdmi_fixed_voltage_config = {
	.supply_name		= "HDMI_EN1",
	.microvolts		= 5000000,
	.gpio			= EXYNOS4_GPE0(1),
	.enable_high		= true,
	.init_data		= &hdmi_fixed_voltage_init_data,
};

static struct platform_device hdmi_fixed_voltage = {
	.name			= "reg-fixed-voltage",
	.id			= FIXED_REG_ID_HDMI_5V,
	.dev			= {
		.platform_data	= &hdmi_fixed_voltage_config,
	},
};

/* GPIO I2C 5 (PMIC) */
static struct i2c_board_info i2c5_devs[] __initdata = {
	{
		},
	}, {
		.chip	= {
			.base	= EXYNOS4_GPD0(0),
			.ngpio	= EXYNOS4_GPIO_D0_NR,
			.label	= "GPD0",
		},
	}, {
		.chip	= {
			.base	= EXYNOS4_GPD1(0),
			.ngpio	= EXYNOS4_GPIO_D1_NR,
			.label	= "GPD1",
		},
	}, {
		.chip	= {
			.base	= EXYNOS4_GPE0(0),
			.ngpio	= EXYNOS4_GPIO_E0_NR,
			.label	= "GPE0",
		},
	}, {
		.chip	= {
			.base	= EXYNOS4_GPE1(0),
			.ngpio	= EXYNOS4_GPIO_E1_NR,
			.label	= "GPE1",
		},
	}, {
		.chip	= {
			.base	= EXYNOS4_GPE2(0),
			.ngpio	= EXYNOS4_GPIO_E2_NR,
			.label	= "GPE2",
		},