Skip to content

Commit

Permalink
Merge branch 'kirkwood/dt' into next/dt2
Browse files Browse the repository at this point in the history
This was part of the for-next branch earlier but for some reasons
a rebuild of the tree missed it, so I'm putting it back in now.

Signed-off-by: Arnd Bergmann <arnd@arndb.de>
  • Loading branch information
Arnd Bergmann committed Mar 24, 2012
2 parents f4eb283 + c899445 commit 7d1206b
Show file tree
Hide file tree
Showing 74 changed files with 2,034 additions and 570 deletions.
1 change: 1 addition & 0 deletions arch/arm/Kconfig
Original file line number Diff line number Diff line change
Expand Up @@ -1579,6 +1579,7 @@ config ARCH_NR_GPIO
int
default 1024 if ARCH_SHMOBILE || ARCH_TEGRA
default 350 if ARCH_U8500
default 264 if MACH_H4700
default 0
help
Maximum number of GPIOs in the system.
Expand Down
24 changes: 24 additions & 0 deletions arch/arm/boot/dts/kirkwood-dreamplug.dts
Original file line number Diff line number Diff line change
@@ -0,0 +1,24 @@
/dts-v1/;

/include/ "kirkwood.dtsi"

/ {
model = "Globalscale Technologies Dreamplug";
compatible = "globalscale,dreamplug-003-ds2001", "globalscale,dreamplug", "mrvl,kirkwood-88f6281", "mrvl,kirkwood";

memory {
device_type = "memory";
reg = <0x00000000 0x20000000>;
};

chosen {
bootargs = "console=ttyS0,115200n8 earlyprintk";
};

ocp@f1000000 {
serial@12000 {
clock-frequency = <200000000>;
status = "ok";
};
};
};
36 changes: 36 additions & 0 deletions arch/arm/boot/dts/kirkwood.dtsi
Original file line number Diff line number Diff line change
@@ -0,0 +1,36 @@
/include/ "skeleton.dtsi"

/ {
compatible = "mrvl,kirkwood";

ocp@f1000000 {
compatible = "simple-bus";
ranges = <0 0xf1000000 0x1000000>;
#address-cells = <1>;
#size-cells = <1>;

serial@12000 {
compatible = "ns16550a";
reg = <0x12000 0x100>;
reg-shift = <2>;
interrupts = <33>;
/* set clock-frequency in board dts */
status = "disabled";
};

serial@12100 {
compatible = "ns16550a";
reg = <0x12100 0x100>;
reg-shift = <2>;
interrupts = <34>;
/* set clock-frequency in board dts */
status = "disabled";
};

rtc@10300 {
compatible = "mrvl,kirkwood-rtc", "mrvl,orion-rtc";
reg = <0x10300 0x20>;
interrupts = <53>;
};
};
};
26 changes: 26 additions & 0 deletions arch/arm/boot/dts/tegra-paz00.dts
Original file line number Diff line number Diff line change
Expand Up @@ -42,6 +42,11 @@

i2c@7000d000 {
clock-frequency = <400000>;

adt7461@4c {
compatible = "adi,adt7461";
reg = <0x4c>;
};
};

i2s@70002a00 {
Expand Down Expand Up @@ -105,4 +110,25 @@
sdhci@c8000600 {
support-8bit;
};

gpio-keys {
compatible = "gpio-keys";

power {
label = "Power";
gpios = <&gpio 79 1>; /* gpio PJ7, active low */
linux,code = <116>; /* KEY_POWER */
gpio-key,wakeup;
};
};

gpio-leds {
compatible = "gpio-leds";

wifi {
label = "wifi-led";
gpios = <&gpio 24 0>;
linux,default-trigger = "rfkill0";
};
};
};
10 changes: 10 additions & 0 deletions arch/arm/mach-exynos/Kconfig
Original file line number Diff line number Diff line change
Expand Up @@ -183,7 +183,9 @@ config MACH_SMDKV310
select S5P_DEV_FIMC1
select S5P_DEV_FIMC2
select S5P_DEV_FIMC3
select S5P_DEV_G2D
select S5P_DEV_I2C_HDMIPHY
select S5P_DEV_JPEG
select S5P_DEV_MFC
select S5P_DEV_TV
select S5P_DEV_USB_EHCI
Expand Down Expand Up @@ -230,7 +232,9 @@ config MACH_UNIVERSAL_C210
select S5P_DEV_FIMC1
select S5P_DEV_FIMC2
select S5P_DEV_FIMC3
select S5P_DEV_G2D
select S5P_DEV_CSIS0
select S5P_DEV_JPEG
select S5P_DEV_FIMD0
select S3C_DEV_HSMMC
select S3C_DEV_HSMMC2
Expand Down Expand Up @@ -268,11 +272,14 @@ config MACH_NURI
select S3C_DEV_I2C1
select S3C_DEV_I2C3
select S3C_DEV_I2C5
select S3C_DEV_I2C6
select S5P_DEV_CSIS0
select S5P_DEV_JPEG
select S5P_DEV_FIMC0
select S5P_DEV_FIMC1
select S5P_DEV_FIMC2
select S5P_DEV_FIMC3
select S5P_DEV_G2D
select S5P_DEV_MFC
select S5P_DEV_USB_EHCI
select S5P_SETUP_MIPIPHY
Expand All @@ -283,6 +290,7 @@ config MACH_NURI
select EXYNOS4_SETUP_I2C1
select EXYNOS4_SETUP_I2C3
select EXYNOS4_SETUP_I2C5
select EXYNOS4_SETUP_I2C6
select EXYNOS4_SETUP_SDHCI
select EXYNOS4_SETUP_USB_PHY
select S5P_SETUP_MIPIPHY
Expand All @@ -303,7 +311,9 @@ config MACH_ORIGEN
select S5P_DEV_FIMC2
select S5P_DEV_FIMC3
select S5P_DEV_FIMD0
select S5P_DEV_G2D
select S5P_DEV_I2C_HDMIPHY
select S5P_DEV_JPEG
select S5P_DEV_MFC
select S5P_DEV_TV
select S5P_DEV_USB_EHCI
Expand Down
80 changes: 76 additions & 4 deletions arch/arm/mach-exynos/mach-nuri.c
Original file line number Diff line number Diff line change
Expand Up @@ -28,6 +28,7 @@

#include <video/platform_lcd.h>
#include <media/m5mols.h>
#include <media/s5k6aa.h>
#include <media/s5p_fimc.h>
#include <media/v4l2-mediabus.h>

Expand Down Expand Up @@ -75,6 +76,7 @@ enum fixed_regulator_id {
FIXED_REG_ID_MAX8903,
FIXED_REG_ID_CAM_A28V,
FIXED_REG_ID_CAM_12V,
FIXED_REG_ID_CAM_VT_15V,
};

static struct s3c2410_uartcfg nuri_uartcfgs[] __initdata = {
Expand Down Expand Up @@ -399,6 +401,9 @@ static struct regulator_consumer_supply __initdata max8997_ldo4_[] = {
static struct regulator_consumer_supply __initdata max8997_ldo5_[] = {
REGULATOR_SUPPLY("vhsic", "modemctl"), /* MODEM */
};
static struct regulator_consumer_supply nuri_max8997_ldo6_consumer[] = {
REGULATOR_SUPPLY("vdd_reg", "6-003c"), /* S5K6AA camera */
};
static struct regulator_consumer_supply __initdata max8997_ldo7_[] = {
REGULATOR_SUPPLY("dig_18", "0-001f"), /* HCD803 */
};
Expand Down Expand Up @@ -431,7 +436,7 @@ static struct regulator_consumer_supply __initdata max8997_buck1_[] = {
REGULATOR_SUPPLY("vdd_arm", NULL), /* CPUFREQ */
};
static struct regulator_consumer_supply __initdata max8997_buck2_[] = {
REGULATOR_SUPPLY("vdd_int", NULL), /* CPUFREQ */
REGULATOR_SUPPLY("vdd_int", "exynos4210-busfreq.0"), /* CPUFREQ */
};
static struct regulator_consumer_supply __initdata max8997_buck3_[] = {
REGULATOR_SUPPLY("vdd", "mali_dev.0"), /* G3D of Exynos 4 */
Expand Down Expand Up @@ -546,6 +551,8 @@ static struct regulator_init_data __initdata max8997_ldo6_data = {
.enabled = 1,
},
},
.num_consumer_supplies = ARRAY_SIZE(nuri_max8997_ldo6_consumer),
.consumer_supplies = nuri_max8997_ldo6_consumer,
};

static struct regulator_init_data __initdata max8997_ldo7_data = {
Expand Down Expand Up @@ -742,7 +749,7 @@ static struct regulator_init_data __initdata max8997_buck2_data = {
.constraints = {
.name = "VINT_1.1V_C210",
.min_uV = 900000,
.max_uV = 1100000,
.max_uV = 1200000,
.valid_ops_mask = REGULATOR_CHANGE_VOLTAGE,
.always_on = 1,
.state_mem = {
Expand Down Expand Up @@ -957,7 +964,6 @@ static struct max8997_platform_data __initdata nuri_max8997_pdata = {
.regulators = nuri_max8997_regulators,

.buck125_gpios = { EXYNOS4_GPX0(5), EXYNOS4_GPX0(6), EXYNOS4_GPL0(0) },
.buck2_gpiodvs = true,

.buck1_voltage[0] = 1350000, /* 1.35V */
.buck1_voltage[1] = 1300000, /* 1.3V */
Expand Down Expand Up @@ -1116,7 +1122,30 @@ static void __init nuri_ehci_init(void)
}

/* CAMERA */
static struct regulator_consumer_supply cam_vt_cam15_supply =
REGULATOR_SUPPLY("vdd_core", "6-003c");

static struct regulator_init_data cam_vt_cam15_reg_init_data = {
.constraints = { .valid_ops_mask = REGULATOR_CHANGE_STATUS },
.num_consumer_supplies = 1,
.consumer_supplies = &cam_vt_cam15_supply,
};

static struct fixed_voltage_config cam_vt_cam15_fixed_voltage_cfg = {
.supply_name = "VT_CAM_1.5V",
.microvolts = 1500000,
.gpio = EXYNOS4_GPE2(2), /* VT_CAM_1.5V_EN */
.enable_high = 1,
.init_data = &cam_vt_cam15_reg_init_data,
};

static struct platform_device cam_vt_cam15_fixed_rdev = {
.name = "reg-fixed-voltage", .id = FIXED_REG_ID_CAM_VT_15V,
.dev = { .platform_data = &cam_vt_cam15_fixed_voltage_cfg },
};

static struct regulator_consumer_supply cam_vdda_supply[] = {
REGULATOR_SUPPLY("vdda", "6-003c"),
REGULATOR_SUPPLY("a_sensor", "0-001f"),
};

Expand Down Expand Up @@ -1173,6 +1202,21 @@ static struct s5p_platform_mipi_csis mipi_csis_platdata = {

#define GPIO_CAM_MEGA_RST EXYNOS4_GPY3(7) /* ISP_RESET */
#define GPIO_CAM_8M_ISP_INT EXYNOS4_GPL2(5)
#define GPIO_CAM_VT_NSTBY EXYNOS4_GPL2(0)
#define GPIO_CAM_VT_NRST EXYNOS4_GPL2(1)

static struct s5k6aa_platform_data s5k6aa_pldata = {
.mclk_frequency = 24000000UL,
.gpio_reset = { GPIO_CAM_VT_NRST, 0 },
.gpio_stby = { GPIO_CAM_VT_NSTBY, 0 },
.bus_type = V4L2_MBUS_PARALLEL,
.horiz_flip = 1,
};

static struct i2c_board_info s5k6aa_board_info = {
I2C_BOARD_INFO("S5K6AA", 0x3c),
.platform_data = &s5k6aa_pldata,
};

static struct m5mols_platform_data m5mols_platdata = {
.gpio_reset = GPIO_CAM_MEGA_RST,
Expand All @@ -1185,6 +1229,13 @@ static struct i2c_board_info m5mols_board_info = {

static struct s5p_fimc_isp_info nuri_camera_sensors[] = {
{
.flags = V4L2_MBUS_PCLK_SAMPLE_RISING |
V4L2_MBUS_VSYNC_ACTIVE_LOW,
.bus_type = FIMC_ITU_601,
.board_info = &s5k6aa_board_info,
.clk_frequency = 24000000UL,
.i2c_bus_num = 6,
}, {
.flags = V4L2_MBUS_PCLK_SAMPLE_FALLING |
V4L2_MBUS_VSYNC_ACTIVE_LOW,
.bus_type = FIMC_MIPI_CSI2,
Expand All @@ -1200,11 +1251,13 @@ static struct s5p_platform_fimc fimc_md_platdata = {
};

static struct gpio nuri_camera_gpios[] = {
{ GPIO_CAM_VT_NSTBY, GPIOF_OUT_INIT_LOW, "CAM_VGA_NSTBY" },
{ GPIO_CAM_VT_NRST, GPIOF_OUT_INIT_LOW, "CAM_VGA_NRST" },
{ GPIO_CAM_8M_ISP_INT, GPIOF_IN, "8M_ISP_INT" },
{ GPIO_CAM_MEGA_RST, GPIOF_OUT_INIT_LOW, "CAM_8M_NRST" },
};

static void nuri_camera_init(void)
static void __init nuri_camera_init(void)
{
s3c_set_platdata(&mipi_csis_platdata, sizeof(mipi_csis_platdata),
&s5p_device_mipi_csis0);
Expand All @@ -1224,6 +1277,8 @@ static void nuri_camera_init(void)
pr_err("%s: Failed to configure 8M_ISP_INT GPIO\n", __func__);

/* Free GPIOs controlled directly by the sensor drivers. */
gpio_free(GPIO_CAM_VT_NRST);
gpio_free(GPIO_CAM_VT_NSTBY);
gpio_free(GPIO_CAM_MEGA_RST);

if (exynos4_fimc_setup_gpio(S5P_CAMPORT_A)) {
Expand All @@ -1234,15 +1289,27 @@ static void nuri_camera_init(void)
s5p_gpio_set_drvstr(EXYNOS4_GPJ1(3), S5P_GPIO_DRVSTR_LV4);
}

static struct s3c2410_platform_i2c nuri_i2c6_platdata __initdata = {
.frequency = 400000U,
.sda_delay = 200,
.bus_num = 6,
};

static struct s3c2410_platform_i2c nuri_i2c0_platdata __initdata = {
.frequency = 400000U,
.sda_delay = 200,
};

/* DEVFREQ controlling memory/bus */
static struct platform_device exynos4_bus_devfreq = {
.name = "exynos4210-busfreq",
};

static struct platform_device *nuri_devices[] __initdata = {
/* Samsung Platform Devices */
&s3c_device_i2c5, /* PMIC should initialize first */
&s3c_device_i2c0,
&s3c_device_i2c6,
&emmc_fixed_voltage,
&s5p_device_mipi_csis0,
&s5p_device_fimc0,
Expand All @@ -1259,6 +1326,8 @@ static struct platform_device *nuri_devices[] __initdata = {
&s3c_device_i2c3,
&i2c9_gpio,
&s3c_device_adc,
&s5p_device_g2d,
&s5p_device_jpeg,
&s3c_device_rtc,
&s5p_device_mfc,
&s5p_device_mfc_l,
Expand All @@ -1274,8 +1343,10 @@ static struct platform_device *nuri_devices[] __initdata = {
&nuri_backlight_device,
&max8903_fixed_reg_dev,
&nuri_max8903_device,
&cam_vt_cam15_fixed_rdev,
&cam_vdda_fixed_rdev,
&cam_8m_12v_fixed_rdev,
&exynos4_bus_devfreq,
};

static void __init nuri_map_io(void)
Expand Down Expand Up @@ -1305,6 +1376,7 @@ static void __init nuri_machine_init(void)
i2c_register_board_info(5, i2c5_devs, ARRAY_SIZE(i2c5_devs));
i2c9_devs[I2C9_MAX17042].irq = gpio_to_irq(EXYNOS4_GPX2(3));
i2c_register_board_info(9, i2c9_devs, ARRAY_SIZE(i2c9_devs));
s3c_i2c6_set_platdata(&nuri_i2c6_platdata);

s5p_fimd0_set_platdata(&nuri_fb_pdata);

Expand Down
Loading

0 comments on commit 7d1206b

Please sign in to comment.