12 #include <linux/serial_core.h>
13 #include <linux/input.h>
14 #include <linux/i2c.h>
29 #include <drm/exynos_drm.h>
49 #include <plat/clock.h>
62 #define NURI_UCON_DEFAULT (S3C2410_UCON_TXILEVEL | \
63 S3C2410_UCON_RXILEVEL | \
64 S3C2410_UCON_TXIRQMODE | \
65 S3C2410_UCON_RXIRQMODE | \
66 S3C2410_UCON_RXFIFO_TOI | \
67 S3C2443_UCON_RXERR_IRQEN)
69 #define NURI_ULCON_DEFAULT S3C2410_LCON_CS8
71 #define NURI_UFCON_DEFAULT (S3C2410_UFCON_FIFOMODE | \
72 S5PV210_UFCON_TXTRIG256 | \
73 S5PV210_UFCON_RXTRIG256)
127 .name =
"VMEM_VDD_2.8V",
130 .num_consumer_supplies =
ARRAY_SIZE(emmc_supplies),
131 .consumer_supplies = emmc_supplies,
135 .supply_name =
"MASSMEMORY_EN (inverted)",
136 .microvolts = 2800000,
138 .enable_high =
false,
139 .init_data = &emmc_fixed_voltage_init_data,
143 .name =
"reg-fixed-voltage",
146 .platform_data = &emmc_fixed_voltage_config,
156 .ext_cd_gpio_invert = 1,
168 static void __init nuri_sdhci_init(
void)
180 .desc =
"gpio-keys: KEY_VOLUMEUP",
183 .debounce_interval = 1,
187 .desc =
"gpio-keys: KEY_VOLUMEDOWN",
190 .debounce_interval = 1,
194 .desc =
"gpio-keys: KEY_POWER",
198 .debounce_interval = 1,
203 .buttons = nuri_gpio_keys_tables,
204 .nbuttons =
ARRAY_SIZE(nuri_gpio_keys_tables),
210 .platform_data = &nuri_gpio_keys_data,
214 #ifdef CONFIG_DRM_EXYNOS
244 .virtual_y = 2 * 600,
260 .win[0] = &nuri_fb_win0,
261 .vtiming = &nuri_lcd_timing,
269 static void nuri_lcd_power_on(
struct plat_lcd_data *pd,
unsigned int power)
278 static int nuri_bl_init(
struct device *
dev)
294 static void nuri_bl_exit(
struct device *dev)
302 .pwm_period_ns = 30000,
303 .max_brightness = 100,
304 .dft_brightness = 50,
305 .init = nuri_bl_init,
306 .notify = nuri_bl_notify,
307 .exit = nuri_bl_exit,
311 .name =
"pwm-backlight",
315 .platform_data = &nuri_backlight_data,
320 .set_power = nuri_lcd_power_on,
324 .name =
"platform-lcd",
327 .platform_data = &nuri_lcd_platform_data,
353 .frequency = 400 * 1000,
360 .platform_data = &mxt_platform_data,
365 static void __init nuri_tsp_init(
void)
457 .name =
"VADC_3.3V_C210",
466 .num_consumer_supplies =
ARRAY_SIZE(max8997_ldo1_),
467 .consumer_supplies = max8997_ldo1_,
472 .name =
"VALIVE_1.1V_C210",
485 .name =
"VUSB_1.1V_C210",
494 .num_consumer_supplies =
ARRAY_SIZE(max8997_ldo3_),
495 .consumer_supplies = max8997_ldo3_,
500 .name =
"VMIPI_1.8V",
509 .num_consumer_supplies =
ARRAY_SIZE(max8997_ldo4_),
510 .consumer_supplies = max8997_ldo4_,
515 .name =
"VHSIC_1.2V_C210",
524 .num_consumer_supplies =
ARRAY_SIZE(max8997_ldo5_),
525 .consumer_supplies = max8997_ldo5_,
530 .name =
"VCC_1.8V_PDA",
539 .num_consumer_supplies =
ARRAY_SIZE(nuri_max8997_ldo6_consumer),
540 .consumer_supplies = nuri_max8997_ldo6_consumer,
545 .name =
"CAM_ISP_1.8V",
554 .num_consumer_supplies =
ARRAY_SIZE(max8997_ldo7_),
555 .consumer_supplies = max8997_ldo7_,
560 .name =
"VUSB+VDAC_3.3V_C210",
569 .num_consumer_supplies =
ARRAY_SIZE(max8997_ldo8_),
570 .consumer_supplies = max8997_ldo8_,
575 .name =
"VCC_2.8V_PDA",
588 .name =
"VPLL_1.1V_C210",
601 .name =
"LVDS_VDD3.3V",
611 .num_consumer_supplies =
ARRAY_SIZE(max8997_ldo11_),
612 .consumer_supplies = max8997_ldo11_,
617 .name =
"VT_CAM_1.8V",
626 .num_consumer_supplies =
ARRAY_SIZE(max8997_ldo12_),
627 .consumer_supplies = max8997_ldo12_,
641 .num_consumer_supplies =
ARRAY_SIZE(max8997_ldo13_),
642 .consumer_supplies = max8997_ldo13_,
647 .name =
"VCC_3.0V_MOTOR",
656 .num_consumer_supplies =
ARRAY_SIZE(max8997_ldo14_),
657 .consumer_supplies = max8997_ldo14_,
662 .name =
"VTOUCH_ADVV2.8V",
671 .num_consumer_supplies =
ARRAY_SIZE(max8997_ldo15_),
672 .consumer_supplies = max8997_ldo15_,
677 .name =
"CAM_SENSOR_IO_1.8V",
686 .num_consumer_supplies =
ARRAY_SIZE(max8997_ldo16_),
687 .consumer_supplies = max8997_ldo16_,
692 .name =
"VTOUCH_VDD2.8V",
701 .num_consumer_supplies =
ARRAY_SIZE(max8997_ldo18_),
702 .consumer_supplies = max8997_ldo18_,
707 .name =
"VDDQ_M1M2_1.2V",
720 .name =
"VARM_1.2V_C210",
729 .num_consumer_supplies =
ARRAY_SIZE(max8997_buck1_),
730 .consumer_supplies = max8997_buck1_,
735 .name =
"VINT_1.1V_C210",
744 .num_consumer_supplies =
ARRAY_SIZE(max8997_buck2_),
745 .consumer_supplies = max8997_buck2_,
750 .name =
"VG3D_1.1V_C210",
759 .num_consumer_supplies =
ARRAY_SIZE(max8997_buck3_),
760 .consumer_supplies = max8997_buck3_,
765 .name =
"CAM_ISP_CORE_1.2V",
774 .num_consumer_supplies =
ARRAY_SIZE(max8997_buck4_),
775 .consumer_supplies = max8997_buck4_,
780 .name =
"VMEM_1.2V_C210",
793 .name =
"CAM_AF_2.8V",
801 .num_consumer_supplies =
ARRAY_SIZE(max8997_buck6_),
802 .consumer_supplies = max8997_buck6_,
807 .name =
"VCC_SUB_2.0V",
826 .num_consumer_supplies =
ARRAY_SIZE(max8997_32khz_ap_),
827 .consumer_supplies = max8997_32khz_ap_,
857 .num_consumer_supplies =
ARRAY_SIZE(max8997_esafeout1_),
858 .consumer_supplies = max8997_esafeout1_,
869 .num_consumer_supplies =
ARRAY_SIZE(max8997_esafeout2_),
870 .consumer_supplies = max8997_esafeout2_,
875 .name =
"CHARGER_CV",
891 .num_consumer_supplies =
ARRAY_SIZE(max8997_charger_),
892 .consumer_supplies = max8997_charger_,
897 .name =
"CHARGER TOPOFF",
902 .num_consumer_supplies =
ARRAY_SIZE(max8997_chg_toff_),
903 .consumer_supplies = max8997_chg_toff_,
949 .num_regulators =
ARRAY_SIZE(nuri_max8997_regulators),
950 .regulators = nuri_max8997_regulators,
954 .buck1_voltage[0] = 1350000,
955 .buck1_voltage[1] = 1300000,
956 .buck1_voltage[2] = 1250000,
957 .buck1_voltage[3] = 1200000,
958 .buck1_voltage[4] = 1150000,
959 .buck1_voltage[5] = 1100000,
960 .buck1_voltage[6] = 1000000,
961 .buck1_voltage[7] = 950000,
963 .buck2_voltage[0] = 1100000,
964 .buck2_voltage[1] = 1000000,
965 .buck2_voltage[2] = 950000,
966 .buck2_voltage[3] = 900000,
967 .buck2_voltage[4] = 1100000,
968 .buck2_voltage[5] = 1000000,
969 .buck2_voltage[6] = 950000,
970 .buck2_voltage[7] = 900000,
972 .buck5_voltage[0] = 1200000,
973 .buck5_voltage[1] = 1200000,
974 .buck5_voltage[2] = 1200000,
975 .buck5_voltage[3] = 1200000,
976 .buck5_voltage[4] = 1200000,
977 .buck5_voltage[5] = 1200000,
978 .buck5_voltage[6] = 1200000,
979 .buck5_voltage[7] = 1200000,
987 .platform_data = &nuri_max8997_pdata,
1003 .platform_data = &i2c9_gpio_data,
1010 .platform_data = &nuri_battery_platform_data,
1021 .name =
"VOUT_CHARGER",
1025 .num_consumer_supplies =
ARRAY_SIZE(supplies_max8903),
1026 .consumer_supplies = supplies_max8903,
1030 .supply_name =
"VOUT_CHARGER",
1031 .microvolts = 5000000,
1034 .enabled_at_boot = 1,
1035 .init_data = &max8903_charger_en_data,
1039 .name =
"reg-fixed-voltage",
1041 .dev = { .platform_data = &max8903_charger_en },
1060 .name =
"max8903-charger",
1062 .platform_data = &nuri_max8903,
1066 static void __init nuri_power_init(
void)
1081 gpio = nuri_max8903.
dok;
1087 gpio = nuri_max8903.
chg;
1091 gpio = nuri_max8903.
dcm;
1099 static void __init nuri_ehci_init(
void)
1115 .num_consumer_supplies = 1,
1116 .consumer_supplies = &cam_vt_cam15_supply,
1120 .supply_name =
"VT_CAM_1.5V",
1121 .microvolts = 1500000,
1124 .init_data = &cam_vt_cam15_reg_init_data,
1129 .dev = { .platform_data = &cam_vt_cam15_fixed_voltage_cfg },
1139 .num_consumer_supplies =
ARRAY_SIZE(cam_vdda_supply),
1140 .consumer_supplies = cam_vdda_supply,
1144 .supply_name =
"CAM_IO_EN",
1145 .microvolts = 2800000,
1148 .init_data = &cam_vdda_reg_init_data,
1153 .dev = { .platform_data = &cam_vdda_fixed_voltage_cfg },
1160 .num_consumer_supplies = 1,
1161 .consumer_supplies = &camera_8m_12v_supply,
1168 .supply_name =
"8M_1.2V",
1169 .microvolts = 1200000,
1172 .init_data = &cam_8m_12v_reg_init_data,
1177 .dev = { .platform_data = &cam_8m_12v_fixed_voltage_cfg },
1181 .clk_rate = 166000000
UL,
1186 #define GPIO_CAM_MEGA_RST EXYNOS4_GPY3(7)
1187 #define GPIO_CAM_8M_ISP_INT EXYNOS4_GPL2(5)
1188 #define GPIO_CAM_VT_NSTBY EXYNOS4_GPL2(0)
1189 #define GPIO_CAM_VT_NRST EXYNOS4_GPL2(1)
1192 .mclk_frequency = 24000000
UL,
1201 .platform_data = &s5k6aa_pldata,
1210 .platform_data = &m5mols_platdata,
1218 .board_info = &s5k6aa_board_info,
1219 .clk_frequency = 24000000
UL,
1225 .board_info = &m5mols_board_info,
1226 .clk_frequency = 24000000
UL,
1231 .isp_info = nuri_camera_sensors,
1232 .num_clients =
ARRAY_SIZE(nuri_camera_sensors),
1235 static struct gpio nuri_camera_gpios[] = {
1242 static void __init nuri_camera_init(
void)
1245 &s5p_device_mipi_csis0);
1247 &s5p_device_fimc_md);
1251 pr_err(
"%s: GPIO request failed\n", __func__);
1259 pr_err(
"%s: Failed to configure 8M_ISP_INT GPIO\n", __func__);
1267 pr_err(
"%s: Camera port A setup failed\n", __func__);
1275 .frequency = 400000
U,
1287 .name =
"exynos4210-busfreq",
1295 &emmc_fixed_voltage,
1323 &nuri_backlight_device,
1324 &max8903_fixed_reg_dev,
1325 &nuri_max8903_device,
1326 &cam_vt_cam15_fixed_rdev,
1327 &cam_vdda_fixed_rdev,
1328 &cam_8m_12v_fixed_rdev,
1329 &exynos4_bus_devfreq,
1330 #ifdef CONFIG_DRM_EXYNOS
1335 static void __init nuri_map_io(
void)
1342 static void __init nuri_reserve(
void)
1347 static void __init nuri_machine_init(
void)
1364 #ifdef CONFIG_DRM_EXYNOS
1382 .atag_offset = 0x100,
1385 .map_io = nuri_map_io,
1387 .init_machine = nuri_machine_init,
1390 .reserve = &nuri_reserve,