code:
// SPDX-License-Identifier: GPL-2.0
/*
 * Samsung's S5PV210 based Galaxy Aries board device tree source
 */

/dts-v1/;
#include <dt-bindings/gpio/gpio.h>
#include <dt-bindings/interrupt-controller/irq.h>
#include "s5pv210.dtsi"

/ {
	compatible = "samsung,aries", "samsung,s5pv210";

	aliases: aliases {
		i2c4 = &i2c_sound;
		i2c5 = &i2c_accel;
		i2c6 = &i2c_pmic;
		i2c7 = &i2c_musb;
		i2c9 = &i2c_fuel;
		i2c10 = &i2c_touchkey;
		i2c11 = &i2c_prox;
		i2c12 = &i2c_magnetometer;
	};

	memory@30000000 {
		device_type = "memory";
		reg = <0x30000000 0x05000000>,
			<0x40000000 0x10000000>,
			<0x50000000 0x08000000>;
	};

	reserved-memory {
		#address-cells = <1>;
		#size-cells = <1>;
		ranges;

		mfc_left: region@43000000 {
			compatible = "shared-dma-pool";
			no-map;
			reg = <0x43000000 0x2000000>;
		};

		mfc_right: region@51000000 {
			compatible = "shared-dma-pool";
			no-map;
			reg = <0x51000000 0x2000000>;
		};
	};

	pmic_ap_clk: clock-0 {
		/* Workaround for missing clock on PMIC */
		compatible = "fixed-clock";
		#clock-cells = <0>;
		clock-frequency = <32768>;
	};

	bt_codec: bt-sco {
		compatible = "linux,bt-sco";
		#sound-dai-cells = <0>;
	};

	vibrator_pwr: regulator-fixed-0 {
		compatible = "regulator-fixed";
		regulator-name = "vibrator-en";
		enable-active-high;
		gpio = <&gpj1 1 GPIO_ACTIVE_HIGH>;

		pinctrl-names = "default";
		pinctrl-0 = <&vibrator_ena>;
	};

	touchkey_vdd: regulator-fixed-1 {
		compatible = "regulator-fixed";
		regulator-name = "VTOUCH_3.3V";
		regulator-min-microvolt = <3300000>;
		regulator-max-microvolt = <3300000>;
		enable-active-high;
		gpio = <&gpj3 2 GPIO_ACTIVE_HIGH>;

		pinctrl-names = "default";
		pinctrl-0 = <&touchkey_vdd_ena>;
	};

	gp2a_vled: regulator-fixed-2 {
		compatible = "regulator-fixed";
		regulator-name = "VLED";
		enable-active-high;
		gpio = <&gpj1 4 GPIO_ACTIVE_HIGH>;
		regulator-min-microvolt = <2800000>;
		regulator-max-microvolt = <2800000>;

		pinctrl-names = "default";
		pinctrl-0 = <&gp2a_power>;
	};

	wifi_pwrseq: wifi-pwrseq {
		compatible = "mmc-pwrseq-simple";
		reset-gpios = <&gpg1 2 GPIO_ACTIVE_LOW>;
		pinctrl-names = "default";
		pinctrl-0 = <&wlan_gpio_rst>;
		post-power-on-delay-ms = <500>;
		power-off-delay-us = <500>;
	};

	i2c_sound: i2c-gpio-0 {
		compatible = "i2c-gpio";
		sda-gpios = <&mp05 3 (GPIO_ACTIVE_HIGH | GPIO_OPEN_DRAIN)>;
		scl-gpios = <&mp05 2 (GPIO_ACTIVE_HIGH | GPIO_OPEN_DRAIN)>;
		i2c-gpio,delay-us = <2>;
		#address-cells = <1>;
		#size-cells = <0>;

		pinctrl-names = "default";
		pinctrl-0 = <&sound_i2c_pins>;

		wm8994: audio-codec@1a {
			compatible = "wlf,wm8994";
			reg = <0x1a>;

			#sound-dai-cells = <0>;

			gpio-controller;
			#gpio-cells = <2>;

			clocks = <&clocks MOUT_CLKOUT>;
			clock-names = "MCLK1";

			AVDD2-supply = <&buck3_reg>;
			DBVDD-supply = <&buck3_reg>;
			CPVDD-supply = <&buck3_reg>;
			SPKVDD1-supply = <&buck3_reg>;
			SPKVDD2-supply = <&buck3_reg>;

			wlf,gpio-cfg = <0xa101 0x8100 0x0100 0x0100 0x8100
					0xa101 0x0100 0x8100 0x0100 0x0100
					0x0100>;

			wlf,ldo1ena = <&gpf3 4 GPIO_ACTIVE_HIGH>;
			wlf,ldo2ena = <&gpf3 4 GPIO_ACTIVE_HIGH>;

			wlf,lineout1-se;
			wlf,lineout2-se;

			assigned-clocks = <&clocks MOUT_CLKOUT>;
			assigned-clock-rates = <0>;
			assigned-clock-parents = <&xusbxti>;

			pinctrl-names = "default";
			pinctrl-0 = <&codec_ldo>;
		};
	};

	i2c_accel: i2c-gpio-1 {
		compatible = "i2c-gpio";
		sda-gpios = <&gpj3 6 (GPIO_ACTIVE_HIGH | GPIO_OPEN_DRAIN)>;
		scl-gpios = <&gpj3 7 (GPIO_ACTIVE_HIGH | GPIO_OPEN_DRAIN)>;
		i2c-gpio,delay-us = <2>;
		#address-cells = <1>;
		#size-cells = <0>;

		pinctrl-names = "default";
		pinctrl-0 = <&accel_i2c_pins>;

		accelerometer@38 {
			compatible = "bosch,bma023";
			reg = <0x38>;

			vdd-supply = <&ldo9_reg>;
			vddio-supply = <&ldo9_reg>;
		};
	};

	i2c_pmic: i2c-gpio-2 {
		compatible = "i2c-gpio";
		sda-gpios = <&gpj4 0 (GPIO_ACTIVE_HIGH | GPIO_OPEN_DRAIN)>;
		scl-gpios = <&gpj4 3 (GPIO_ACTIVE_HIGH | GPIO_OPEN_DRAIN)>;
		i2c-gpio,delay-us = <2>;
		#address-cells = <1>;
		#size-cells = <0>;

		pinctrl-names = "default";
		pinctrl-0 = <&pmic_i2c_pins>;

		pmic@66 {
			compatible = "maxim,max8998";
			reg = <0x66>;
			interrupt-parent = <&gph0>;
			interrupts = <7 IRQ_TYPE_EDGE_FALLING>;

			max8998,pmic-buck1-default-dvs-idx = <1>;
			max8998,pmic-buck1-dvs-gpios = <&gph0 3 GPIO_ACTIVE_HIGH>,
							<&gph0 4 GPIO_ACTIVE_HIGH>;
			max8998,pmic-buck1-dvs-voltage = <1275000>, <1200000>,
							<1050000>, <950000>;

			max8998,pmic-buck2-default-dvs-idx = <0>;
			max8998,pmic-buck2-dvs-gpio = <&gph0 5 GPIO_ACTIVE_HIGH>;
			max8998,pmic-buck2-dvs-voltage = <1100000>, <1000000>;

			pinctrl-names = "default";
			pinctrl-0 = <&pmic_dvs_pins &pmic_irq>;

			regulators {
				ldo2_reg: LDO2 {
					regulator-name = "VALIVE_1.2V";
					regulator-min-microvolt = <1200000>;
					regulator-max-microvolt = <1200000>;
					regulator-always-on;

					regulator-state-mem {
						regulator-on-in-suspend;
					};
				};

				ldo3_reg: LDO3 {
					regulator-name = "VUSB_1.1V";
					regulator-min-microvolt = <1100000>;
					regulator-max-microvolt = <1100000>;

					regulator-state-mem {
						regulator-off-in-suspend;
					};
				};

				ldo4_reg: LDO4 {
					regulator-name = "VADC_3.3V";
					regulator-min-microvolt = <3300000>;
					regulator-max-microvolt = <3300000>;

					regulator-state-mem {
						regulator-off-in-suspend;
					};
				};

				ldo5_reg: LDO5 {
					regulator-name = "VTF_2.8V";
					regulator-min-microvolt = <2800000>;
					regulator-max-microvolt = <2800000>;

					regulator-state-mem {
						regulator-off-in-suspend;
					};
				};

				ldo6_reg: LDO6 {
					regulator-name = "LDO6";
					regulator-min-microvolt = <1600000>;
					regulator-max-microvolt = <3600000>;
				};

				ldo7_reg: LDO7 {
					regulator-name = "VLCD_1.8V";
					regulator-min-microvolt = <1800000>;
					regulator-max-microvolt = <1800000>;

					regulator-state-mem {
						regulator-off-in-suspend;
					};
				};

				ldo8_reg: LDO8 {
					regulator-name = "VUSB_3.3V";
					regulator-min-microvolt = <3300000>;
					regulator-max-microvolt = <3300000>;

					regulator-state-mem {
						regulator-off-in-suspend;
					};
				};

				ldo9_reg: LDO9 {
					regulator-name = "VCC_2.8V_PDA";
					regulator-min-microvolt = <2800000>;
					regulator-max-microvolt = <2800000>;
					regulator-always-on;
				};

				ldo10_reg: LDO10 {
					regulator-name = "VPLL_1.2V";
					regulator-min-microvolt = <1200000>;
					regulator-max-microvolt = <1200000>;
					regulator-always-on;

					regulator-state-mem {
						regulator-on-in-suspend;
					};
				};

				ldo11_reg: LDO11 {
					regulator-name = "CAM_AF_3.0V";
					regulator-min-microvolt = <3000000>;
					regulator-max-microvolt = <3000000>;

					regulator-state-mem {
						regulator-off-in-suspend;
					};
				};

				ldo12_reg: LDO12 {
					regulator-name = "CAM_SENSOR_CORE_1.2V";
					regulator-min-microvolt = <1200000>;
					regulator-max-microvolt = <1200000>;

					regulator-state-mem {
						regulator-off-in-suspend;
					};
				};

				ldo13_reg: LDO13 {
					regulator-name = "VGA_VDDIO_2.8V";
					regulator-min-microvolt = <2800000>;
					regulator-max-microvolt = <2800000>;

					regulator-state-mem {
						regulator-off-in-suspend;
					};
				};

				ldo14_reg: LDO14 {
					regulator-name = "VGA_DVDD_1.8V";
					regulator-min-microvolt = <1800000>;
					regulator-max-microvolt = <1800000>;

					regulator-state-mem {
						regulator-off-in-suspend;
					};
				};

				ldo15_reg: LDO15 {
					regulator-name = "CAM_ISP_HOST_2.8V";
					regulator-min-microvolt = <2800000>;
					regulator-max-microvolt = <2800000>;

					regulator-state-mem {
						regulator-off-in-suspend;
					};
				};

				ldo16_reg: LDO16 {
					regulator-name = "VGA_AVDD_2.8V";
					regulator-min-microvolt = <2800000>;
					regulator-max-microvolt = <2800000>;

					regulator-state-mem {
						regulator-off-in-suspend;
					};
				};

				ldo17_reg: LDO17 {
					regulator-name = "VCC_3.0V_LCD";
					regulator-min-microvolt = <3000000>;
					regulator-max-microvolt = <3000000>;

					regulator-state-mem {
						regulator-off-in-suspend;
					};
				};

				buck1_reg: BUCK1 {
					regulator-name = "vddarm";
					regulator-min-microvolt = <750000>;
					regulator-max-microvolt = <1500000>;

					regulator-state-mem {
						regulator-off-in-suspend;
						regulator-suspend-microvolt = <1250000>;
					};
				};

				buck2_reg: BUCK2 {
					regulator-name = "vddint";
					regulator-min-microvolt = <750000>;
					regulator-max-microvolt = <1500000>;

					regulator-state-mem {
						regulator-off-in-suspend;
						regulator-suspend-microvolt = <1100000>;
					};
				};

				buck3_reg: BUCK3 {
					regulator-name = "VCC_1.8V";
					regulator-min-microvolt = <1800000>;
					regulator-max-microvolt = <1800000>;
					regulator-always-on;
				};

				buck4_reg: BUCK4 {
					regulator-name = "CAM_ISP_CORE_1.2V";
					regulator-min-microvolt = <1200000>;
					regulator-max-microvolt = <1200000>;

					regulator-state-mem {
						regulator-off-in-suspend;
					};
				};

				ap32khz_reg: EN32KHz-AP {
					regulator-name = "32KHz AP";
					regulator-always-on;
				};

				cp32khz_reg: EN32KHz-CP {
					regulator-name = "32KHz CP";
				};

				vichg_reg: ENVICHG {
					regulator-name = "VICHG";
					regulator-always-on;
				};

				safe1_sreg: ESAFEOUT1 {
					regulator-name = "SAFEOUT1";
				};

				safe2_sreg: ESAFEOUT2 {
					regulator-name = "SAFEOUT2";
				};
			};
		};
	};

	i2c_musb: i2c-gpio-3 {
		compatible = "i2c-gpio";
		sda-gpios = <&gpj3 4 (GPIO_ACTIVE_HIGH | GPIO_OPEN_DRAIN)>;
		scl-gpios = <&gpj3 5 (GPIO_ACTIVE_HIGH | GPIO_OPEN_DRAIN)>;
		i2c-gpio,delay-us = <2>;
		#address-cells = <1>;
		#size-cells = <0>;

		pinctrl-names = "default";
		pinctrl-0 = <&musb_i2c_pins>;

		fsa9480: musb@25 {
			compatible = "fcs,fsa9480";
			reg = <0x25>;
			interrupt-parent = <&gph2>;
			interrupts = <7 IRQ_TYPE_EDGE_FALLING>;

			pinctrl-names = "default";
			pinctrl-0 = <&musb_irq>;
		};
	};

	i2c_fuel: i2c-gpio-4 {
		compatible = "i2c-gpio";
		sda-gpios = <&mp05 1 (GPIO_ACTIVE_HIGH | GPIO_OPEN_DRAIN)>;
		scl-gpios = <&mp05 0 (GPIO_ACTIVE_HIGH | GPIO_OPEN_DRAIN)>;
		i2c-gpio,delay-us = <2>;
		#address-cells = <1>;
		#size-cells = <0>;

		pinctrl-names = "default";
		pinctrl-0 = <&fg_i2c_pins>;

		fg: fuelgauge@36 {
			compatible = "maxim,max17040";
			reg = <0x36>;
		};
	};

	i2c_touchkey: i2c-gpio-5 {
		compatible = "i2c-gpio";
		sda-gpios = <&gpj3 0 (GPIO_ACTIVE_HIGH | GPIO_OPEN_DRAIN)>;
		scl-gpios = <&gpj3 1 (GPIO_ACTIVE_HIGH | GPIO_OPEN_DRAIN)>;
		i2c-gpio,delay-us = <2>;
		#address-cells = <1>;
		#size-cells = <0>;

		pinctrl-names = "default";
		pinctrl-0 = <&touchkey_i2c_pins>;

		touchkey@20 {
			compatible = "cypress,aries-touchkey";
			reg = <0x20>;
			vdd-supply = <&touchkey_vdd>;
			vcc-supply = <&buck3_reg>;
			linux,keycodes = <KEY_MENU KEY_BACK
					  KEY_HOMEPAGE KEY_SEARCH>;
			interrupt-parent = <&gpj4>;
			interrupts = <1 IRQ_TYPE_LEVEL_LOW>;

			pinctrl-names = "default";
			pinctrl-0 = <&touchkey_irq>;
		};
	};

	i2c_prox: i2c-gpio-6 {
		compatible = "i2c-gpio";
		sda-gpios = <&gpg2 2 (GPIO_ACTIVE_HIGH | GPIO_OPEN_DRAIN)>;
		scl-gpios = <&gpg0 2 (GPIO_ACTIVE_HIGH | GPIO_OPEN_DRAIN)>;
		i2c-gpio,delay-us = <2>;
		#address-cells = <1>;
		#size-cells = <0>;

		pinctrl-names = "default";
		pinctrl-0 = <&prox_i2c_pins>;

		light-sensor@44 {
			compatible = "sharp,gp2ap002a00f";
			reg = <0x44>;
			interrupt-parent = <&gph0>;
			interrupts = <2 IRQ_TYPE_EDGE_FALLING>;
			vdd-supply = <&gp2a_vled>;
			vio-supply = <&gp2a_vled>;
			io-channels = <&gp2a_shunt>;
			io-channel-names = "alsout";
			sharp,proximity-far-hysteresis = /bits/ 8 <0x40>;
			sharp,proximity-close-hysteresis = /bits/ 8 <0x20>;

			pinctrl-names = "default";
			pinctrl-0 = <&gp2a_irq>;
		};
	};

	i2c_magnetometer: i2c-gpio-7 {
		compatible = "i2c-gpio";
		sda-gpios = <&gpj0 1 (GPIO_ACTIVE_HIGH | GPIO_OPEN_DRAIN)>;
		scl-gpios = <&gpj0 0 (GPIO_ACTIVE_HIGH | GPIO_OPEN_DRAIN)>;
		i2c-gpio,delay-us = <2>;
		#address-cells = <1>;
		#size-cells = <0>;

		pinctrl-names = "default";
		pinctrl-0 = <&magnetometer_i2c_pins>;

		status = "disabled";

		/* Yamaha yas529 magnetometer, no mainline binding */
	};

	vibrator: pwm-vibrator {
		compatible = "pwm-vibrator";
		pwms = <&pwm 1 44642 0>;
		pwm-names = "enable";
		vcc-supply = <&vibrator_pwr>;
		pinctrl-names = "default";
		pinctrl-0 = <&pwm1_out>;
	};

	poweroff: syscon-poweroff {
		compatible = "syscon-poweroff";
		regmap = <&pmu_syscon>;
		offset = <0x681c>; /* PS_HOLD_CONTROL */
		value = <0x5200>;
	};

	spi_lcd: spi-2 {
		compatible = "spi-gpio";
		#address-cells = <1>;
		#size-cells = <0>;

		sck-gpios = <&mp04 1 GPIO_ACTIVE_HIGH>;
		mosi-gpios = <&mp04 3 GPIO_ACTIVE_HIGH>;
		cs-gpios = <&mp01 1 GPIO_ACTIVE_HIGH>;
		num-chipselects = <1>;

		pinctrl-names = "default";
		pinctrl-0 = <&lcd_spi_pins>;

		panel@0 {
			compatible = "samsung,s6e63m0";
			reg = <0>;
			reset-gpios = <&mp05 5 GPIO_ACTIVE_LOW>;
			vdd3-supply = <&ldo7_reg>;
			vci-supply = <&ldo17_reg>;
			spi-max-frequency = <1200000>;

			pinctrl-names = "default";
			pinctrl-0 = <&panel_rst>;

			port {
				lcd_ep: endpoint {
					remote-endpoint = <&fimd_ep>;
				};
			};
		};
	};
};

&adc {
	vdd-supply = <&ldo4_reg>;

	status = "okay";

	gp2a_shunt: current-sense-shunt {
		compatible = "current-sense-shunt";
		io-channels = <&adc 9>;
		shunt-resistor-micro-ohms = <47000000>; /* 47 ohms */
		#io-channel-cells = <0>;
	};
};

&fimd {
	pinctrl-names = "default";
	pinctrl-0 = <&lcd_clk &lcd_data24>;
	status = "okay";

	samsung,invert-vden;
	samsung,invert-vclk;

	#address-cells = <1>;
	#size-cells = <0>;

	port@3 {
		reg = <3>;
		fimd_ep: endpoint {
			remote-endpoint = <&lcd_ep>;
		};
	};
};

&hsotg {
	vusb_a-supply = <&ldo8_reg>;
	vusb_d-supply = <&ldo3_reg>;
	dr_mode = "peripheral";
	status = "okay";
};

&i2c2 {
	samsung,i2c-sda-delay = <100>;
	samsung,i2c-max-bus-freq = <400000>;
	samsung,i2c-slave-addr = <0x10>;
	status = "okay";

	touchscreen@4a {
		compatible = "atmel,maxtouch";
		reg = <0x4a>;
		interrupt-parent = <&gpj0>;
		interrupts = <5 IRQ_TYPE_EDGE_FALLING>;
		pinctrl-names = "default";
		pinctrl-0 = <&ts_irq>;
		reset-gpios = <&gpj1 3 GPIO_ACTIVE_LOW>;
	};
};

&i2s0 {
	dmas = <&pdma0 10>, <&pdma0 9>, <&pdma0 11>;
	status = "okay";
};

&mfc {
	memory-region = <&mfc_left>, <&mfc_right>;
};

&pinctrl0 {
	bt_reset: bt-reset-pins {
		samsung,pins = "gpb-3";
		samsung,pin-function = <S5PV210_PIN_FUNC_OUTPUT>;
		samsung,pin-pud = <S5PV210_PIN_PULL_NONE>;
		samsung,pin-drv = <S5PV210_PIN_DRV_LV1>;
	};

	wlan_bt_en: wlan-bt-en-pins {
		samsung,pins = "gpb-5";
		samsung,pin-function = <S5PV210_PIN_FUNC_OUTPUT>;
		samsung,pin-pud = <S5PV210_PIN_PULL_NONE>;
		samsung,pin-val = <1>;
	};

	codec_ldo: codec-ldo-pins {
		samsung,pins = "gpf3-4";
		samsung,pin-function = <S5PV210_PIN_FUNC_OUTPUT>;
		samsung,pin-pud = <S5PV210_PIN_PULL_NONE>;
	};

	prox_i2c_pins: gp2a-i2c-pins {
		samsung,pins = "gpg0-2", "gpg2-2";
		samsung,pin-pud = <S5PV210_PIN_PULL_NONE>;
		samsung,pin-drv = <S5PV210_PIN_DRV_LV1>;
	};

	wlan_gpio_rst: wlan-gpio-rst-pins {
		samsung,pins = "gpg1-2";
		samsung,pin-function = <S5PV210_PIN_FUNC_OUTPUT>;
		samsung,pin-pud = <S5PV210_PIN_PULL_NONE>;
	};

	bt_wake: bt-wake-pins {
		samsung,pins = "gpg3-4";
		samsung,pin-function = <S5PV210_PIN_FUNC_OUTPUT>;
		samsung,pin-pud = <S5PV210_PIN_PULL_NONE>;
	};

	gp2a_irq: gp2a-irq-pins {
		samsung,pins = "gph0-2";
		samsung,pin-function = <S5PV210_PIN_FUNC_F>;
		samsung,pin-pud = <S5PV210_PIN_PULL_DOWN>;
		samsung,pin-drv = <S5PV210_PIN_DRV_LV1>;
	};

	pmic_dvs_pins: pmic-dvs-pins {
		samsung,pins = "gph0-3", "gph0-4", "gph0-5";
		samsung,pin-function = <S5PV210_PIN_FUNC_OUTPUT>;
		samsung,pin-pud = <S5PV210_PIN_PULL_NONE>;
		samsung,pin-drv = <S5PV210_PIN_DRV_LV1>;
		samsung,pin-val = <0>;
	};

	pmic_irq: pmic-irq-pins {
		samsung,pins = "gph0-7";
		samsung,pin-function = <S5PV210_PIN_FUNC_F>;
		samsung,pin-pud = <S5PV210_PIN_PULL_NONE>;
		samsung,pin-drv = <S5PV210_PIN_DRV_LV1>;
	};

	wifi_host_wake: wifi-host-wake-pins {
		samsung,pins = "gph2-4";
		samsung,pin-function = <S5PV210_PIN_FUNC_INPUT>;
		samsung,pin-pud = <S5PV210_PIN_PULL_DOWN>;
		samsung,pin-drv = <S5PV210_PIN_DRV_LV1>;
	};

	bt_host_wake: bt-host-wake-pins {
		samsung,pins = "gph2-5";
		samsung,pin-function = <S5PV210_PIN_FUNC_INPUT>;
		samsung,pin-pud = <S5PV210_PIN_PULL_DOWN>;
		samsung,pin-drv = <S5PV210_PIN_DRV_LV1>;
	};

	musb_irq: musq-irq-pins {
		samsung,pins = "gph2-7";
		samsung,pin-function = <S5PV210_PIN_FUNC_INPUT>;
		samsung,pin-pud = <S5PV210_PIN_PULL_NONE>;
		samsung,pin-drv = <S5PV210_PIN_DRV_LV1>;
	};

	tf_detect: tf-detect-pins {
		samsung,pins = "gph3-4";
		samsung,pin-function = <S5PV210_PIN_FUNC_INPUT>;
		samsung,pin-pud = <S5PV210_PIN_PULL_DOWN>;
		samsung,pin-drv = <S5PV210_PIN_DRV_LV1>;
	};

	wifi_wake: wifi-wake-pins {
		samsung,pins = "gph3-5";
		samsung,pin-function = <S5PV210_PIN_FUNC_OUTPUT>;
		samsung,pin-pud = <S5PV210_PIN_PULL_NONE>;
	};

	magnetometer_i2c_pins: yas529-i2c-pins {
		samsung,pins = "gpj0-0", "gpj0-1";
		samsung,pin-pud = <S5PV210_PIN_PULL_NONE>;
		samsung,pin-drv = <S5PV210_PIN_DRV_LV1>;
	};

	ts_irq: ts-irq-pins {
		samsung,pins = "gpj0-5";
		samsung,pin-function = <S5PV210_PIN_FUNC_INPUT>;
		samsung,pin-pud = <S5PV210_PIN_PULL_NONE>;
		samsung,pin-drv = <S5PV210_PIN_DRV_LV1>;
	};

	vibrator_ena: vibrator-ena-pins {
		samsung,pins = "gpj1-1";
		samsung,pin-pud = <S5PV210_PIN_PULL_NONE>;
		samsung,pin-drv = <S5PV210_PIN_DRV_LV1>;
	};

	gp2a_power: gp2a-power-pins {
		samsung,pins = "gpj1-4";
		samsung,pin-function = <S5PV210_PIN_FUNC_OUTPUT>;
		samsung,pin-pud = <S5PV210_PIN_PULL_NONE>;
		samsung,pin-drv = <S5PV210_PIN_DRV_LV1>;
	};

	touchkey_i2c_pins: touchkey-i2c-pins {
		samsung,pins = "gpj3-0", "gpj3-1";
		samsung,pin-pud = <S5PV210_PIN_PULL_NONE>;
		samsung,pin-drv = <S5PV210_PIN_DRV_LV1>;
	};

	touchkey_vdd_ena: touchkey-vdd-ena-pins {
		samsung,pins = "gpj3-2";
		samsung,pin-pud = <S5PV210_PIN_PULL_NONE>;
		samsung,pin-drv = <S5PV210_PIN_DRV_LV1>;
	};

	musb_i2c_pins: musb-i2c-pins {
		samsung,pins = "gpj3-4", "gpj3-5";
		samsung,pin-pud = <S5PV210_PIN_PULL_NONE>;
		samsung,pin-drv = <S5PV210_PIN_DRV_LV1>;
	};

	accel_i2c_pins: accel-i2c-pins {
		samsung,pins = "gpj3-6", "gpj3-7";
		samsung,pin-pud = <S5PV210_PIN_PULL_NONE>;
		samsung,pin-drv = <S5PV210_PIN_DRV_LV1>;
	};

	pmic_i2c_pins: pmic-i2c-pins {
		samsung,pins = "gpj4-0", "gpj4-3";
		samsung,pin-pud = <S5PV210_PIN_PULL_NONE>;
		samsung,pin-drv = <S5PV210_PIN_DRV_LV1>;
	};

	touchkey_irq: touchkey-irq-pins {
		samsung,pins = "gpj4-1";
		samsung,pin-function = <S5PV210_PIN_FUNC_INPUT>;
		samsung,pin-pud = <S5PV210_PIN_PULL_UP>;
		samsung,pin-drv = <S5PV210_PIN_DRV_LV1>;
	};

	lcd_spi_pins: spi-lcd-pins {
		samsung,pins = "mp01-1", "mp04-1", "mp04-3";
		samsung,pin-pud = <S5PV210_PIN_PULL_NONE>;
		samsung,pin-drv = <S5PV210_PIN_DRV_LV1>;
	};

	fg_i2c_pins: fg-i2c-pins {
		samsung,pins = "mp05-0", "mp05-1";
		samsung,pin-pud = <S5PV210_PIN_PULL_NONE>;
		samsung,pin-drv = <S5PV210_PIN_DRV_LV1>;
	};

	sound_i2c_pins: sound-i2c-pins {
		samsung,pins = "mp05-2", "mp05-3";
		samsung,pin-pud = <S5PV210_PIN_PULL_NONE>;
		samsung,pin-drv = <S5PV210_PIN_DRV_LV1>;
	};

	panel_rst: panel-rst-pins {
		samsung,pins = "mp05-5";
		samsung,pin-pud = <S5PV210_PIN_PULL_NONE>;
		samsung,pin-drv = <S5PV210_PIN_DRV_LV1>;
	};
};

&pwm {
	samsung,pwm-outputs = <1>;
};

&rtc {
	clocks = <&clocks CLK_RTC>, <&pmic_ap_clk>;
	clock-names = "rtc", "rtc_src";
};

&sdhci1 {
	#address-cells = <1>;
	#size-cells = <0>;

	bus-width = <4>;
	max-frequency = <38400000>;
	pinctrl-0 = <&sd1_clk &sd1_cmd &sd1_bus4 &wifi_wake &wifi_host_wake &wlan_bt_en>;
	pinctrl-names = "default";
	cap-sd-highspeed;
	cap-mmc-highspeed;
	keep-power-in-suspend;

	mmc-pwrseq = <&wifi_pwrseq>;
	non-removable;
	status = "okay";

	assigned-clocks = <&clocks MOUT_MMC1>, <&clocks SCLK_MMC1>;
	assigned-clock-rates = <0>, <50000000>;
	assigned-clock-parents = <&clocks MOUT_MPLL>;

	wlan@1 {
		reg = <1>;
		compatible = "brcm,bcm4329-fmac";
		interrupt-parent = <&gph2>;
		interrupts = <4 IRQ_TYPE_LEVEL_HIGH>;
		interrupt-names = "host-wake";
	};
};

&sdhci2 {
	bus-width = <4>;
	cd-gpios = <&gph3 4 GPIO_ACTIVE_LOW>;
	vmmc-supply = <&ldo5_reg>;
	pinctrl-0 = <&sd2_clk &sd2_cmd &sd2_bus4 &tf_detect>;
	pinctrl-names = "default";
	status = "okay";

	assigned-clocks = <&clocks MOUT_MMC2>, <&clocks SCLK_MMC2>;
	assigned-clock-rates = <0>, <50000000>;
	assigned-clock-parents = <&clocks MOUT_MPLL>;
};

&uart0 {
	assigned-clocks = <&clocks MOUT_UART0>, <&clocks SCLK_UART0>;
	assigned-clock-rates = <0>, <111166667>;
	assigned-clock-parents = <&clocks MOUT_MPLL>;

	status = "okay";

	bluetooth {
		compatible = "brcm,bcm4329-bt";
		max-speed = <3000000>;
		pinctrl-names = "default";
		pinctrl-0 = <&uart0_data &uart0_fctl &bt_host_wake
			     &bt_reset &bt_wake>;
		shutdown-gpios = <&gpb 3 GPIO_ACTIVE_HIGH>;
		device-wakeup-gpios = <&gpg3 4 GPIO_ACTIVE_HIGH>;
		interrupt-parent = <&gph2>;
		interrupts = <5 IRQ_TYPE_LEVEL_HIGH>;
		interrupt-names = "host-wakeup";
	};
};

&uart1 {
	status = "okay";
};

&uart2 {
	status = "okay";
};

&usbphy {
	status = "okay";
	vbus-supply = <&safe1_sreg>;
};

&xusbxti {
	clock-frequency = <24000000>;
};


code:
// SPDX-License-Identifier: GPL-2.0

/dts-v1/;
#include <dt-bindings/gpio/gpio.h>
#include <dt-bindings/input/input.h>
#include "s5pv210-aries.dtsi"

/ {
	model = "Samsung Galaxy S Fascinate 4G (SGH-T959P) based on S5PV210";
	compatible = "samsung,fascinate4g", "samsung,aries", "samsung,s5pv210";
	chassis-type = "handset";

	chosen {
		stdout-path = &uart2;
	};

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

		key-power {
			label = "power";
			gpios = <&gph2 6 GPIO_ACTIVE_LOW>;
			linux,code = <KEY_POWER>;
			wakeup-source;
		};

		key-vol-down {
			label = "volume_down";
			gpios = <&gph3 2 GPIO_ACTIVE_LOW>;
			linux,code = <KEY_VOLUMEDOWN>;
		};

		key-vol-up {
			label = "volume_up";
			gpios = <&gph3 1 GPIO_ACTIVE_LOW>;
			linux,code = <KEY_VOLUMEUP>;
		};
	};

	headset_micbias_reg: regulator-fixed-3 {
		compatible = "regulator-fixed";
		regulator-name = "Headset_Micbias";
		gpio = <&gpj2 5 GPIO_ACTIVE_HIGH>;
		enable-active-high;

		pinctrl-names = "default";
		pinctrl-0 = <&headset_micbias_ena>;
	};

	main_micbias_reg: regulator-fixed-4 {
		compatible = "regulator-fixed";
		regulator-name = "Main_Micbias";
		gpio = <&gpj4 2 GPIO_ACTIVE_HIGH>;
		enable-active-high;

		pinctrl-names = "default";
		pinctrl-0 = <&main_micbias_ena>;
	};

	sound {
		compatible = "samsung,fascinate4g-wm8994";

		model = "Fascinate4G";

		extcon = <&fsa9480>;

		main-micbias-supply = <&main_micbias_reg>;
		headset-micbias-supply = <&headset_micbias_reg>;

		earpath-sel-gpios = <&gpj2 6 GPIO_ACTIVE_HIGH>;

		io-channels = <&adc 3>;
		io-channel-names = "headset-detect";
		headset-detect-gpios = <&gph0 6 GPIO_ACTIVE_HIGH>;
		headset-key-gpios = <&gph3 6 GPIO_ACTIVE_HIGH>;

		samsung,audio-routing =
			"HP", "HPOUT1L",
			"HP", "HPOUT1R",

			"SPK", "SPKOUTLN",
			"SPK", "SPKOUTLP",

			"RCV", "HPOUT2N",
			"RCV", "HPOUT2P",

			"LINE", "LINEOUT2N",
			"LINE", "LINEOUT2P",

			"IN1LP", "Main Mic",
			"IN1LN", "Main Mic",

			"IN1RP", "Headset Mic",
			"IN1RN", "Headset Mic",

			"Modem Out", "Modem TX",
			"Modem RX", "Modem In",

			"Bluetooth SPK", "TX",
			"RX", "Bluetooth Mic";

		pinctrl-names = "default";
		pinctrl-0 = <&headset_det &earpath_sel>;

		cpu {
			sound-dai = <&i2s0>, <&bt_codec>;
		};

		codec {
			sound-dai = <&wm8994>;
		};
	};
};

&fg {
	compatible = "maxim,max77836-battery";

	interrupt-parent = <&gph3>;
	interrupts = <3 IRQ_TYPE_LEVEL_LOW>;

	pinctrl-names = "default";
	pinctrl-0 = <&fg_irq>;
};

&pinctrl0 {
	pinctrl-names = "default";
	pinctrl-0 = <&sleep_cfg>;

	headset_det: headset-det-pins {
		samsung,pins = "gph0-6", "gph3-6";
		samsung,pin-function = <S5PV210_PIN_FUNC_F>;
		samsung,pin-pud = <S5PV210_PIN_PULL_NONE>;
	};

	fg_irq: fg-irq-pins {
		samsung,pins = "gph3-3";
		samsung,pin-function = <S5PV210_PIN_FUNC_F>;
		samsung,pin-pud = <S5PV210_PIN_PULL_NONE>;
		samsung,pin-drv = <S5PV210_PIN_DRV_LV1>;
	};

	headset_micbias_ena: headset-micbias-ena-pins {
		samsung,pins = "gpj2-5";
		samsung,pin-pud = <S5PV210_PIN_PULL_NONE>;
		samsung,pin-drv = <S5PV210_PIN_DRV_LV1>;
	};

	earpath_sel: earpath-sel-pins {
		samsung,pins = "gpj2-6";
		samsung,pin-pud = <S5PV210_PIN_PULL_NONE>;
		samsung,pin-drv = <S5PV210_PIN_DRV_LV1>;
	};

	main_micbias_ena: main-micbias-ena-pins {
		samsung,pins = "gpj4-2";
		samsung,pin-pud = <S5PV210_PIN_PULL_NONE>;
		samsung,pin-drv = <S5PV210_PIN_DRV_LV1>;
	};

	/* Based on vendor kernel v2.6.35.7 */
	sleep_cfg: sleep-state {
		PIN_SLP(gpa0-0, PREV, NONE);
		PIN_SLP(gpa0-1, PREV, NONE);
		PIN_SLP(gpa0-2, PREV, NONE);
		PIN_SLP(gpa0-3, OUT1, NONE);
		PIN_SLP(gpa0-4, PREV, NONE);
		PIN_SLP(gpa0-5, PREV, NONE);
		PIN_SLP(gpa0-6, PREV, NONE);
		PIN_SLP(gpa0-7, PREV, NONE);

		PIN_SLP(gpa1-0, INPUT, DOWN);
		PIN_SLP(gpa1-1, OUT0, NONE);
		PIN_SLP(gpa1-2, INPUT, DOWN);
		PIN_SLP(gpa1-3, OUT0, NONE);

		PIN_SLP(gpb-0, OUT0, NONE);
		PIN_SLP(gpb-1, OUT1, NONE);
		PIN_SLP(gpb-2, OUT0, NONE);
		PIN_SLP(gpb-3, PREV, NONE);
		PIN_SLP(gpb-4, INPUT, NONE);
		PIN_SLP(gpb-5, PREV, NONE);
		PIN_SLP(gpb-6, INPUT, DOWN);
		PIN_SLP(gpb-7, OUT0, NONE);

		PIN_SLP(gpc0-0, OUT0, NONE);
		PIN_SLP(gpc0-1, INPUT, DOWN);
		PIN_SLP(gpc0-2, OUT0, NONE);
		PIN_SLP(gpc0-3, INPUT, DOWN);
		PIN_SLP(gpc0-4, OUT0, NONE);

		PIN_SLP(gpc1-0, INPUT, DOWN);
		PIN_SLP(gpc1-1, INPUT, DOWN);
		PIN_SLP(gpc1-2, INPUT, DOWN);
		PIN_SLP(gpc1-3, INPUT, DOWN);
		PIN_SLP(gpc1-4, INPUT, DOWN);

		PIN_SLP(gpd0-0, INPUT, DOWN);
		PIN_SLP(gpd0-1, OUT0, NONE);
		PIN_SLP(gpd0-2, INPUT, DOWN);
		PIN_SLP(gpd0-3, INPUT, DOWN);

		PIN_SLP(gpd1-0, INPUT, NONE);
		PIN_SLP(gpd1-1, INPUT, NONE);
		PIN_SLP(gpd1-2, INPUT, DOWN);
		PIN_SLP(gpd1-3, INPUT, DOWN);
		PIN_SLP(gpd1-4, INPUT, DOWN);
		PIN_SLP(gpd1-5, INPUT, DOWN);

		PIN_SLP(gpe0-0, INPUT, DOWN);
		PIN_SLP(gpe0-1, INPUT, DOWN);
		PIN_SLP(gpe0-2, INPUT, DOWN);
		PIN_SLP(gpe0-3, INPUT, DOWN);
		PIN_SLP(gpe0-4, INPUT, DOWN);
		PIN_SLP(gpe0-5, INPUT, DOWN);
		PIN_SLP(gpe0-6, INPUT, DOWN);
		PIN_SLP(gpe0-7, INPUT, DOWN);

		PIN_SLP(gpe1-0, INPUT, DOWN);
		PIN_SLP(gpe1-1, INPUT, DOWN);
		PIN_SLP(gpe1-2, INPUT, DOWN);
		PIN_SLP(gpe1-3, OUT0, NONE);
		PIN_SLP(gpe1-4, INPUT, DOWN);

		PIN_SLP(gpf0-0, OUT0, NONE);
		PIN_SLP(gpf0-1, OUT0, NONE);
		PIN_SLP(gpf0-2, OUT0, NONE);
		PIN_SLP(gpf0-3, OUT0, NONE);
		PIN_SLP(gpf0-4, OUT0, NONE);
		PIN_SLP(gpf0-5, OUT0, NONE);
		PIN_SLP(gpf0-6, OUT0, NONE);
		PIN_SLP(gpf0-7, OUT0, NONE);

		PIN_SLP(gpf1-0, OUT0, NONE);
		PIN_SLP(gpf1-1, OUT0, NONE);
		PIN_SLP(gpf1-2, OUT0, NONE);
		PIN_SLP(gpf1-3, OUT0, NONE);
		PIN_SLP(gpf1-4, OUT0, NONE);
		PIN_SLP(gpf1-5, OUT0, NONE);
		PIN_SLP(gpf1-6, OUT0, NONE);
		PIN_SLP(gpf1-7, OUT0, NONE);

		PIN_SLP(gpf2-0, OUT0, NONE);
		PIN_SLP(gpf2-1, OUT0, NONE);
		PIN_SLP(gpf2-2, OUT0, NONE);
		PIN_SLP(gpf2-3, OUT0, NONE);
		PIN_SLP(gpf2-4, OUT0, NONE);
		PIN_SLP(gpf2-5, OUT0, NONE);
		PIN_SLP(gpf2-6, OUT0, NONE);
		PIN_SLP(gpf2-7, OUT0, NONE);

		PIN_SLP(gpf3-0, OUT0, NONE);
		PIN_SLP(gpf3-1, OUT0, NONE);
		PIN_SLP(gpf3-2, OUT0, NONE);
		PIN_SLP(gpf3-3, OUT0, NONE);
		PIN_SLP(gpf3-4, PREV, NONE);
		PIN_SLP(gpf3-5, INPUT, DOWN);

		PIN_SLP(gpg0-0, INPUT, DOWN);
		PIN_SLP(gpg0-1, INPUT, DOWN);
		PIN_SLP(gpg0-2, INPUT, NONE);
		PIN_SLP(gpg0-3, INPUT, DOWN);
		PIN_SLP(gpg0-4, INPUT, DOWN);
		PIN_SLP(gpg0-5, INPUT, DOWN);
		PIN_SLP(gpg0-6, INPUT, DOWN);

		PIN_SLP(gpg1-0, OUT0, NONE);
		PIN_SLP(gpg1-1, OUT1, NONE);
		PIN_SLP(gpg1-2, PREV, NONE);
		PIN_SLP(gpg1-3, OUT1, NONE);
		PIN_SLP(gpg1-4, OUT1, NONE);
		PIN_SLP(gpg1-5, OUT1, NONE);
		PIN_SLP(gpg1-6, OUT1, NONE);

		PIN_SLP(gpg2-0, OUT0, NONE);
		PIN_SLP(gpg2-1, OUT0, NONE);
		PIN_SLP(gpg2-2, INPUT, NONE);
		PIN_SLP(gpg2-3, OUT0, NONE);
		PIN_SLP(gpg2-4, OUT0, NONE);
		PIN_SLP(gpg2-5, OUT0, NONE);
		PIN_SLP(gpg2-6, OUT0, NONE);

		PIN_SLP(gpg3-0, PREV, UP);
		PIN_SLP(gpg3-1, PREV, UP);
		PIN_SLP(gpg3-2, INPUT, NONE);
		PIN_SLP(gpg3-3, INPUT, DOWN);
		PIN_SLP(gpg3-4, OUT0, NONE);
		PIN_SLP(gpg3-5, OUT0, NONE);
		PIN_SLP(gpg3-6, INPUT, DOWN);

		PIN_SLP(gpi-0, PREV, NONE);
		PIN_SLP(gpi-1, INPUT, DOWN);
		PIN_SLP(gpi-2, PREV, NONE);
		PIN_SLP(gpi-3, PREV, NONE);
		PIN_SLP(gpi-4, PREV, NONE);
		PIN_SLP(gpi-5, INPUT, DOWN);
		PIN_SLP(gpi-6, INPUT, DOWN);

		PIN_SLP(gpj0-0, INPUT, NONE);
		PIN_SLP(gpj0-1, INPUT, NONE);
		PIN_SLP(gpj0-2, INPUT, NONE);
		PIN_SLP(gpj0-3, INPUT, NONE);
		PIN_SLP(gpj0-4, INPUT, NONE);
		PIN_SLP(gpj0-5, INPUT, DOWN);
		PIN_SLP(gpj0-6, OUT0, NONE);
		PIN_SLP(gpj0-7, INPUT, NONE);

		PIN_SLP(gpj1-0, OUT1, NONE);
		PIN_SLP(gpj1-1, OUT0, NONE);
		PIN_SLP(gpj1-2, INPUT, DOWN);
		PIN_SLP(gpj1-3, PREV, NONE);
		PIN_SLP(gpj1-4, PREV, NONE);
		PIN_SLP(gpj1-5, OUT0, NONE);

		PIN_SLP(gpj2-0, INPUT, DOWN);
		PIN_SLP(gpj2-1, INPUT, DOWN);
		PIN_SLP(gpj2-2, OUT0, NONE);
		PIN_SLP(gpj2-3, INPUT, DOWN);
		PIN_SLP(gpj2-4, INPUT, DOWN);
		PIN_SLP(gpj2-5, PREV, NONE);
		PIN_SLP(gpj2-6, PREV, NONE);
		PIN_SLP(gpj2-7, INPUT, DOWN);

		PIN_SLP(gpj3-0, INPUT, NONE);
		PIN_SLP(gpj3-1, INPUT, NONE);
		PIN_SLP(gpj3-2, OUT0, NONE);
		PIN_SLP(gpj3-3, INPUT, DOWN);
		PIN_SLP(gpj3-4, INPUT, NONE);
		PIN_SLP(gpj3-5, INPUT, NONE);
		PIN_SLP(gpj3-6, INPUT, NONE);
		PIN_SLP(gpj3-7, INPUT, NONE);

		PIN_SLP(gpj4-0, INPUT, NONE);
		PIN_SLP(gpj4-1, INPUT, DOWN);
		PIN_SLP(gpj4-2, PREV, NONE);
		PIN_SLP(gpj4-3, INPUT, NONE);
		PIN_SLP(gpj4-4, INPUT, DOWN);

		PIN_SLP(mp01-0, OUT1, NONE);
		PIN_SLP(mp01-1, OUT0, NONE);
		PIN_SLP(mp01-2, INPUT, DOWN);
		PIN_SLP(mp01-3, INPUT, DOWN);
		PIN_SLP(mp01-4, OUT1, NONE);
		PIN_SLP(mp01-5, INPUT, DOWN);
		PIN_SLP(mp01-6, INPUT, DOWN);
		PIN_SLP(mp01-7, INPUT, DOWN);

		PIN_SLP(mp02-0, INPUT, DOWN);
		PIN_SLP(mp02-1, INPUT, DOWN);
		PIN_SLP(mp02-2, INPUT, NONE);
		PIN_SLP(mp02-3, INPUT, DOWN);

		PIN_SLP(mp03-0, INPUT, DOWN);
		PIN_SLP(mp03-1, INPUT, DOWN);
		PIN_SLP(mp03-2, OUT1, NONE);
		PIN_SLP(mp03-3, OUT0, NONE);
		PIN_SLP(mp03-4, INPUT, NONE);
		PIN_SLP(mp03-5, OUT0, NONE);
		PIN_SLP(mp03-6, INPUT, DOWN);
		PIN_SLP(mp03-7, INPUT, DOWN);

		PIN_SLP(mp04-0, INPUT, DOWN);
		PIN_SLP(mp04-1, OUT0, NONE);
		PIN_SLP(mp04-2, INPUT, DOWN);
		PIN_SLP(mp04-3, OUT0, NONE);
		PIN_SLP(mp04-4, INPUT, DOWN);
		PIN_SLP(mp04-5, INPUT, DOWN);
		PIN_SLP(mp04-6, OUT0, NONE);
		PIN_SLP(mp04-7, INPUT, DOWN);

		PIN_SLP(mp05-0, INPUT, NONE);
		PIN_SLP(mp05-1, INPUT, NONE);
		PIN_SLP(mp05-2, INPUT, NONE);
		PIN_SLP(mp05-3, INPUT, NONE);
		PIN_SLP(mp05-4, INPUT, DOWN);
		PIN_SLP(mp05-5, OUT0, NONE);
		PIN_SLP(mp05-6, INPUT, DOWN);
		PIN_SLP(mp05-7, PREV, NONE);

		PIN_SLP(mp06-0, INPUT, DOWN);
		PIN_SLP(mp06-1, INPUT, DOWN);
		PIN_SLP(mp06-2, INPUT, DOWN);
		PIN_SLP(mp06-3, INPUT, DOWN);
		PIN_SLP(mp06-4, INPUT, DOWN);
		PIN_SLP(mp06-5, INPUT, DOWN);
		PIN_SLP(mp06-6, INPUT, DOWN);
		PIN_SLP(mp06-7, INPUT, DOWN);

		PIN_SLP(mp07-0, INPUT, DOWN);
		PIN_SLP(mp07-1, INPUT, DOWN);
		PIN_SLP(mp07-2, INPUT, DOWN);
		PIN_SLP(mp07-3, INPUT, DOWN);
		PIN_SLP(mp07-4, INPUT, DOWN);
		PIN_SLP(mp07-5, INPUT, DOWN);
		PIN_SLP(mp07-6, INPUT, DOWN);
		PIN_SLP(mp07-7, INPUT, DOWN);
	};
};

&wm8994 {
	/* GPIO3 (BCLK2) and GPIO4 (LRCLK2) as outputs */
	wlf,gpio-cfg = <0xa101 0x8100 0x8100 0x8100 0x8100 0xa101
			0x0100 0x8100 0x0100 0x0100 0x0100>;
};

repo_name: angery/linux


code:
// SPDX-License-Identifier: GPL-2.0

/dts-v1/;
#include <dt-bindings/gpio/gpio.h>
#include <dt-bindings/input/input.h>
#include "s5pv210-aries.dtsi"

/ {
	model = "Samsung Galaxy S1 (GT-I9000) based on S5PV210";
	compatible = "samsung,galaxys", "samsung,aries", "samsung,s5pv210";
	chassis-type = "handset";

	chosen {
		stdout-path = &uart2;
	};

	nand_pwrseq: nand-pwrseq {
		compatible = "mmc-pwrseq-simple";
		reset-gpios = <&gpj2 7 GPIO_ACTIVE_LOW>;
		pinctrl-names = "default";
		pinctrl-0 = <&massmemory_en>;
	};

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

		key-power {
			label = "power";
			gpios = <&gph2 6 GPIO_ACTIVE_LOW>;
			linux,code = <KEY_POWER>;
			wakeup-source;
		};

		key-vol-down {
			label = "volume_down";
			gpios = <&gph3 1 GPIO_ACTIVE_LOW>;
			linux,code = <KEY_VOLUMEDOWN>;
		};

		key-vol-up {
			label = "volume_up";
			gpios = <&gph3 2 GPIO_ACTIVE_LOW>;
			linux,code = <KEY_VOLUMEUP>;
		};

		key-home {
			label = "home";
			gpios = <&gph3 5 GPIO_ACTIVE_LOW>;
			linux,code = <KEY_HOME>;
			wakeup-source;
		};
	};

	i2c_fmradio: i2c-gpio-8 {
		compatible = "i2c-gpio";
		sda-gpios = <&gpd1 2 (GPIO_ACTIVE_HIGH | GPIO_OPEN_DRAIN)>;
		scl-gpios = <&gpd1 3 (GPIO_ACTIVE_HIGH | GPIO_OPEN_DRAIN)>;
		i2c-gpio,delay-us = <2>;
		#address-cells = <1>;
		#size-cells = <0>;

		pinctrl-names = "default";
		pinctrl-0 = <&fm_i2c_pins>;

		fmradio@10 {
			compatible = "silabs,si470x";
			reg = <0x10>;
			interrupt-parent = <&gpj2>;
			interrupts = <4 IRQ_TYPE_EDGE_FALLING>;
			reset-gpios = <&gpj2 5 GPIO_ACTIVE_HIGH>;

			pinctrl-names = "default";
			pinctrl-0 = <&fm_irq &fm_rst>;
		};
	};

	micbias_reg: regulator-fixed-3 {
		compatible = "regulator-fixed";
		regulator-name = "MICBIAS";
		gpio = <&gpj4 2 GPIO_ACTIVE_HIGH>;
		enable-active-high;

		pinctrl-names = "default";
		pinctrl-0 = <&micbias_reg_ena>;
	};

	sound {
		compatible = "samsung,aries-wm8994";

		model = "Aries";

		extcon = <&fsa9480>;

		main-micbias-supply = <&micbias_reg>;
		headset-micbias-supply = <&micbias_reg>;

		earpath-sel-gpios = <&gpj2 6 GPIO_ACTIVE_HIGH>;

		io-channels = <&adc 3>;
		io-channel-names = "headset-detect";
		headset-detect-gpios = <&gph0 6 GPIO_ACTIVE_LOW>;
		headset-key-gpios = <&gph3 6 GPIO_ACTIVE_HIGH>;

		samsung,audio-routing =
			"HP", "HPOUT1L",
			"HP", "HPOUT1R",

			"SPK", "SPKOUTLN",
			"SPK", "SPKOUTLP",

			"RCV", "HPOUT2N",
			"RCV", "HPOUT2P",

			"LINE", "LINEOUT2N",
			"LINE", "LINEOUT2P",

			"IN1LP", "Main Mic",
			"IN1LN", "Main Mic",

			"IN1RP", "Headset Mic",
			"IN1RN", "Headset Mic",

			"IN2LN", "FM In",
			"IN2RN", "FM In",

			"Modem Out", "Modem TX",
			"Modem RX", "Modem In",

			"Bluetooth SPK", "TX",
			"RX", "Bluetooth Mic";

		pinctrl-names = "default";
		pinctrl-0 = <&headset_det &earpath_sel>;

		cpu {
			sound-dai = <&i2s0>, <&bt_codec>;
		};

		codec {
			sound-dai = <&wm8994>;
		};
	};
};

&aliases {
	i2c8 = &i2c_fmradio;
};

&pinctrl0 {
	pinctrl-names = "default";
	pinctrl-0 = <&sleep_cfg>;

	fm_i2c_pins: fm-i2c-pins {
		samsung,pins = "gpd1-2", "gpd1-3";
		samsung,pin-pud = <S5PV210_PIN_PULL_NONE>;
		samsung,pin-drv = <S5PV210_PIN_DRV_LV1>;
	};

	headset_det: headset-det-pins {
		samsung,pins = "gph0-6", "gph3-6";
		samsung,pin-function = <S5PV210_PIN_FUNC_F>;
		samsung,pin-pud = <S5PV210_PIN_PULL_NONE>;
	};

	fm_irq: fm-irq-pins {
		samsung,pins = "gpj2-4";
		samsung,pin-function = <S5PV210_PIN_FUNC_INPUT>;
		samsung,pin-pud = <S5PV210_PIN_PULL_UP>;
		samsung,pin-drv = <S5PV210_PIN_DRV_LV1>;
	};

	fm_rst: fm-rst-pins {
		samsung,pins = "gpj2-5";
		samsung,pin-function = <S5PV210_PIN_FUNC_OUTPUT>;
		samsung,pin-pud = <S5PV210_PIN_PULL_NONE>;
		samsung,pin-drv = <S5PV210_PIN_DRV_LV1>;
	};

	earpath_sel: earpath-sel-pins {
		samsung,pins = "gpj2-6";
		samsung,pin-pud = <S5PV210_PIN_PULL_NONE>;
		samsung,pin-drv = <S5PV210_PIN_DRV_LV1>;
	};

	massmemory_en: massmemory-en-pins {
		samsung,pins = "gpj2-7";
		samsung,pin-function = <S5PV210_PIN_FUNC_OUTPUT>;
		samsung,pin-pud = <S5PV210_PIN_PULL_NONE>;
		samsung,pin-drv = <S5PV210_PIN_DRV_LV1>;
	};

	micbias_reg_ena: micbias-reg-ena-pins {
		samsung,pins = "gpj4-2";
		samsung,pin-pud = <S5PV210_PIN_PULL_NONE>;
		samsung,pin-drv = <S5PV210_PIN_DRV_LV1>;
	};

	/* Based on CyanogenMod 3.0.101 kernel */
	sleep_cfg: sleep-state {
		PIN_SLP(gpa0-0, PREV, NONE);
		PIN_SLP(gpa0-1, PREV, NONE);
		PIN_SLP(gpa0-2, PREV, NONE);
		PIN_SLP(gpa0-3, OUT1, NONE);
		PIN_SLP(gpa0-4, INPUT, DOWN);
		PIN_SLP(gpa0-5, OUT0, NONE);
		PIN_SLP(gpa0-6, INPUT, DOWN);
		PIN_SLP(gpa0-7, OUT1, NONE);

		PIN_SLP(gpa1-0, INPUT, DOWN);
		PIN_SLP(gpa1-1, OUT0, NONE);
		PIN_SLP(gpa1-2, INPUT, NONE);
		PIN_SLP(gpa1-3, OUT0, NONE);

		PIN_SLP(gpb-0, OUT0, NONE);
		PIN_SLP(gpb-1, OUT1, NONE);
		PIN_SLP(gpb-2, OUT0, NONE);
		PIN_SLP(gpb-3, PREV, NONE);
		PIN_SLP(gpb-4, INPUT, NONE);
		PIN_SLP(gpb-5, PREV, NONE);
		PIN_SLP(gpb-6, INPUT, DOWN);
		PIN_SLP(gpb-7, OUT0, NONE);

		PIN_SLP(gpc0-0, OUT0, NONE);
		PIN_SLP(gpc0-1, INPUT, DOWN);
		PIN_SLP(gpc0-2, OUT0, NONE);
		PIN_SLP(gpc0-3, INPUT, NONE);
		PIN_SLP(gpc0-4, OUT0, NONE);

		PIN_SLP(gpc1-0, INPUT, DOWN);
		PIN_SLP(gpc1-1, INPUT, DOWN);
		PIN_SLP(gpc1-2, INPUT, DOWN);
		PIN_SLP(gpc1-3, INPUT, DOWN);
		PIN_SLP(gpc1-4, INPUT, DOWN);

		PIN_SLP(gpd0-0, INPUT, DOWN);
		PIN_SLP(gpd0-1, OUT0, NONE);
		PIN_SLP(gpd0-2, INPUT, DOWN);
		PIN_SLP(gpd0-3, INPUT, DOWN);

		PIN_SLP(gpd1-0, INPUT, NONE);
		PIN_SLP(gpd1-1, INPUT, NONE);
		PIN_SLP(gpd1-2, INPUT, NONE);
		PIN_SLP(gpd1-3, INPUT, NONE);
		PIN_SLP(gpd1-4, INPUT, DOWN);
		PIN_SLP(gpd1-5, INPUT, DOWN);

		PIN_SLP(gpe0-0, INPUT, DOWN);
		PIN_SLP(gpe0-1, INPUT, DOWN);
		PIN_SLP(gpe0-2, INPUT, DOWN);
		PIN_SLP(gpe0-3, INPUT, DOWN);
		PIN_SLP(gpe0-4, INPUT, DOWN);
		PIN_SLP(gpe0-5, INPUT, DOWN);
		PIN_SLP(gpe0-6, INPUT, DOWN);
		PIN_SLP(gpe0-7, INPUT, DOWN);

		PIN_SLP(gpe1-0, INPUT, DOWN);
		PIN_SLP(gpe1-1, INPUT, DOWN);
		PIN_SLP(gpe1-2, INPUT, DOWN);
		PIN_SLP(gpe1-3, OUT0, NONE);
		PIN_SLP(gpe1-4, INPUT, DOWN);

		PIN_SLP(gpf0-0, OUT0, NONE);
		PIN_SLP(gpf0-1, OUT0, NONE);
		PIN_SLP(gpf0-2, OUT0, NONE);
		PIN_SLP(gpf0-3, OUT0, NONE);
		PIN_SLP(gpf0-4, OUT0, NONE);
		PIN_SLP(gpf0-5, OUT0, NONE);
		PIN_SLP(gpf0-6, OUT0, NONE);
		PIN_SLP(gpf0-7, OUT0, NONE);

		PIN_SLP(gpf1-0, OUT0, NONE);
		PIN_SLP(gpf1-1, OUT0, NONE);
		PIN_SLP(gpf1-2, OUT0, NONE);
		PIN_SLP(gpf1-3, OUT0, NONE);
		PIN_SLP(gpf1-4, OUT0, NONE);
		PIN_SLP(gpf1-5, OUT0, NONE);
		PIN_SLP(gpf1-6, OUT0, NONE);
		PIN_SLP(gpf1-7, OUT0, NONE);

		PIN_SLP(gpf2-0, OUT0, NONE);
		PIN_SLP(gpf2-1, OUT0, NONE);
		PIN_SLP(gpf2-2, OUT0, NONE);
		PIN_SLP(gpf2-3, OUT0, NONE);
		PIN_SLP(gpf2-4, OUT0, NONE);
		PIN_SLP(gpf2-5, OUT0, NONE);
		PIN_SLP(gpf2-6, OUT0, NONE);
		PIN_SLP(gpf2-7, OUT0, NONE);

		PIN_SLP(gpf3-0, OUT0, NONE);
		PIN_SLP(gpf3-1, OUT0, NONE);
		PIN_SLP(gpf3-2, OUT0, NONE);
		PIN_SLP(gpf3-3, OUT0, NONE);
		PIN_SLP(gpf3-4, PREV, NONE);
		PIN_SLP(gpf3-5, INPUT, DOWN);

		PIN_SLP(gpg0-0, OUT0, NONE);
		PIN_SLP(gpg0-1, INPUT, NONE);
		PIN_SLP(gpg0-2, INPUT, NONE);
		PIN_SLP(gpg0-3, INPUT, NONE);
		PIN_SLP(gpg0-4, INPUT, NONE);
		PIN_SLP(gpg0-5, INPUT, NONE);
		PIN_SLP(gpg0-6, INPUT, NONE);

		PIN_SLP(gpg1-0, OUT0, NONE);
		PIN_SLP(gpg1-1, OUT1, NONE);
		PIN_SLP(gpg1-2, PREV, NONE);
		PIN_SLP(gpg1-3, OUT1, NONE);
		PIN_SLP(gpg1-4, OUT1, NONE);
		PIN_SLP(gpg1-5, OUT1, NONE);
		PIN_SLP(gpg1-6, OUT1, NONE);

		PIN_SLP(gpg2-0, OUT0, NONE);
		PIN_SLP(gpg2-1, OUT0, NONE);
		PIN_SLP(gpg2-2, INPUT, NONE);
		PIN_SLP(gpg2-3, OUT0, NONE);
		PIN_SLP(gpg2-4, OUT0, NONE);
		PIN_SLP(gpg2-5, OUT0, NONE);
		PIN_SLP(gpg2-6, OUT0, NONE);

		PIN_SLP(gpg3-0, OUT1, NONE);
		PIN_SLP(gpg3-1, OUT0, NONE);
		PIN_SLP(gpg3-2, INPUT, NONE);
		PIN_SLP(gpg3-3, INPUT, DOWN);
		PIN_SLP(gpg3-4, OUT0, NONE);
		PIN_SLP(gpg3-5, OUT0, NONE);
		PIN_SLP(gpg3-6, INPUT, DOWN);

		PIN_SLP(gpi-0, PREV, NONE);
		PIN_SLP(gpi-1, INPUT, DOWN);
		PIN_SLP(gpi-2, PREV, NONE);
		PIN_SLP(gpi-3, PREV, NONE);
		PIN_SLP(gpi-4, PREV, NONE);
		PIN_SLP(gpi-5, INPUT, DOWN);
		PIN_SLP(gpi-6, INPUT, DOWN);

		PIN_SLP(gpj0-0, INPUT, NONE);
		PIN_SLP(gpj0-1, INPUT, NONE);
		PIN_SLP(gpj0-2, INPUT, NONE);
		PIN_SLP(gpj0-3, INPUT, NONE);
		PIN_SLP(gpj0-4, INPUT, NONE);
		PIN_SLP(gpj0-5, INPUT, DOWN);
		PIN_SLP(gpj0-6, OUT0, NONE);
		PIN_SLP(gpj0-7, INPUT, NONE);

		PIN_SLP(gpj1-0, INPUT, DOWN);
		PIN_SLP(gpj1-1, OUT0, NONE);
		PIN_SLP(gpj1-2, INPUT, DOWN);
		PIN_SLP(gpj1-3, PREV, NONE);
		PIN_SLP(gpj1-4, PREV, NONE);
		PIN_SLP(gpj1-5, OUT0, NONE);

		PIN_SLP(gpj2-0, INPUT, DOWN);
		PIN_SLP(gpj2-1, INPUT, DOWN);
		PIN_SLP(gpj2-2, OUT0, NONE);
		PIN_SLP(gpj2-3, INPUT, DOWN);
		PIN_SLP(gpj2-4, INPUT, UP);
		PIN_SLP(gpj2-5, PREV, NONE);
		PIN_SLP(gpj2-6, PREV, NONE);
		PIN_SLP(gpj2-7, OUT1, NONE);

		PIN_SLP(gpj3-0, INPUT, NONE);
		PIN_SLP(gpj3-1, INPUT, NONE);
		PIN_SLP(gpj3-2, OUT0, NONE);
		PIN_SLP(gpj3-3, INPUT, DOWN);
		PIN_SLP(gpj3-4, INPUT, NONE);
		PIN_SLP(gpj3-5, INPUT, NONE);
		PIN_SLP(gpj3-6, INPUT, NONE);
		PIN_SLP(gpj3-7, INPUT, NONE);

		PIN_SLP(gpj4-0, INPUT, NONE);
		PIN_SLP(gpj4-1, INPUT, DOWN);
		PIN_SLP(gpj4-2, PREV, NONE);
		PIN_SLP(gpj4-3, INPUT, NONE);
		PIN_SLP(gpj4-4, INPUT, DOWN);

		PIN_SLP(mp01-0, INPUT, DOWN);
		PIN_SLP(mp01-1, OUT0, NONE);
		PIN_SLP(mp01-2, INPUT, DOWN);
		PIN_SLP(mp01-3, INPUT, DOWN);
		PIN_SLP(mp01-4, OUT1, NONE);
		PIN_SLP(mp01-5, INPUT, DOWN);
		PIN_SLP(mp01-6, INPUT, DOWN);
		PIN_SLP(mp01-7, INPUT, DOWN);

		PIN_SLP(mp02-0, INPUT, DOWN);
		PIN_SLP(mp02-1, INPUT, DOWN);
		PIN_SLP(mp02-2, INPUT, NONE);
		PIN_SLP(mp02-3, INPUT, DOWN);

		PIN_SLP(mp03-0, INPUT, DOWN);
		PIN_SLP(mp03-1, INPUT, DOWN);
		PIN_SLP(mp03-2, OUT1, NONE);
		PIN_SLP(mp03-3, OUT0, NONE);
		PIN_SLP(mp03-4, INPUT, NONE);
		PIN_SLP(mp03-5, OUT1, NONE);
		PIN_SLP(mp03-6, INPUT, DOWN);
		PIN_SLP(mp03-7, INPUT, DOWN);

		PIN_SLP(mp04-0, INPUT, DOWN);
		PIN_SLP(mp04-1, OUT0, NONE);
		PIN_SLP(mp04-2, INPUT, DOWN);
		PIN_SLP(mp04-3, OUT0, NONE);
		PIN_SLP(mp04-4, INPUT, DOWN);
		PIN_SLP(mp04-5, INPUT, DOWN);
		PIN_SLP(mp04-6, OUT0, NONE);
		PIN_SLP(mp04-7, INPUT, DOWN);

		PIN_SLP(mp05-0, INPUT, NONE);
		PIN_SLP(mp05-1, INPUT, NONE);
		PIN_SLP(mp05-2, INPUT, NONE);
		PIN_SLP(mp05-3, INPUT, NONE);
		PIN_SLP(mp05-4, INPUT, DOWN);
		PIN_SLP(mp05-5, OUT0, NONE);
		PIN_SLP(mp05-6, INPUT, DOWN);
		PIN_SLP(mp05-7, PREV, NONE);

		PIN_SLP(mp06-0, INPUT, DOWN);
		PIN_SLP(mp06-1, INPUT, DOWN);
		PIN_SLP(mp06-2, INPUT, DOWN);
		PIN_SLP(mp06-3, INPUT, DOWN);
		PIN_SLP(mp06-4, INPUT, DOWN);
		PIN_SLP(mp06-5, INPUT, DOWN);
		PIN_SLP(mp06-6, INPUT, DOWN);
		PIN_SLP(mp06-7, INPUT, DOWN);

		PIN_SLP(mp07-0, INPUT, DOWN);
		PIN_SLP(mp07-1, INPUT, DOWN);
		PIN_SLP(mp07-2, INPUT, DOWN);
		PIN_SLP(mp07-3, INPUT, DOWN);
		PIN_SLP(mp07-4, INPUT, DOWN);
		PIN_SLP(mp07-5, INPUT, DOWN);
		PIN_SLP(mp07-6, INPUT, DOWN);
		PIN_SLP(mp07-7, INPUT, DOWN);
	};
};

&sdhci0 {
	bus-width = <4>;
	non-removable;
	mmc-pwrseq = <&nand_pwrseq>;
	pinctrl-0 = <&sd0_clk &sd0_cmd &sd0_bus4>;
	pinctrl-names = "default";
	status = "okay";

	assigned-clocks = <&clocks MOUT_MMC0>, <&clocks SCLK_MMC0>;
	assigned-clock-rates = <0>, <52000000>;
	assigned-clock-parents = <&clocks MOUT_MPLL>;
};


code:
// SPDX-License-Identifier: GPL-2.0
/*
 * Samsung's S5PV210 SoC device tree source
 *
 * Copyright (c) 2013-2014 Samsung Electronics, Co. Ltd.
 *
 * Mateusz Krawczuk <m.krawczuk@partner.samsung.com>
 * Tomasz Figa <t.figa@samsung.com>
 *
 * Board device tree source for Samsung Goni board.
 */

/dts-v1/;
#include <dt-bindings/gpio/gpio.h>
#include <dt-bindings/interrupt-controller/irq.h>
#include <dt-bindings/input/input.h>
#include "s5pv210.dtsi"

/ {
	model = "Samsung Goni based on S5PC110";
	compatible = "samsung,goni", "samsung,s5pv210";

	aliases {
		i2c3 = &i2c_pmic;
	};

	chosen {
		bootargs = "console=ttySAC0,115200n8 root=/dev/mmcblk0p5 rw rootwait ignore_loglevel earlyprintk";
	};

	memory@30000000 {
		device_type = "memory";
		reg = <0x30000000 0x05000000>,
			<0x40000000 0x10000000>,
			<0x50000000 0x08000000>;
	};

	pmic_ap_clk: clock-0 {
		/* Workaround for missing clock on PMIC */
		compatible = "fixed-clock";
		#clock-cells = <0>;
		clock-frequency = <32768>;
	};

	vtf_reg: regulator-0 {
		compatible = "regulator-fixed";
		regulator-name = "V_TF_2.8V";
		regulator-min-microvolt = <2800000>;
		regulator-max-microvolt = <2800000>;
		gpio = <&mp05 4 GPIO_ACTIVE_HIGH>;
		enable-active-high;
	};

	pda_reg: regulator-1 {
		compatible = "regulator-fixed";
		regulator-name = "VCC_1.8V_PDA";
		regulator-min-microvolt = <1800000>;
		regulator-max-microvolt = <1800000>;
	};

	bat_reg: regulator-2 {
		compatible = "regulator-fixed";
		regulator-name = "V_BAT";
		regulator-min-microvolt = <3700000>;
		regulator-max-microvolt = <3700000>;
	};

	tsp_reg: regulator-3 {
		compatible = "regulator-fixed";
		regulator-name = "TSP_VDD";
		regulator-min-microvolt = <2800000>;
		regulator-max-microvolt = <2800000>;
		gpio = <&gpj1 3 GPIO_ACTIVE_HIGH>;
		enable-active-high;
	};

	i2c_pmic: i2c-pmic {
		compatible = "i2c-gpio";
		sda-gpios = <&gpj4 0 GPIO_ACTIVE_HIGH>;
		scl-gpios = <&gpj4 3 GPIO_ACTIVE_HIGH>;
		i2c-gpio,delay-us = <2>;        /* ~100 kHz */
		#address-cells = <1>;
		#size-cells = <0>;

		pmic@66 {
			compatible = "national,lp3974";
			reg = <0x66>;

			max8998,pmic-buck1-default-dvs-idx = <0>;
			max8998,pmic-buck1-dvs-gpios = <&gph0 3 GPIO_ACTIVE_HIGH>,
							<&gph0 4 GPIO_ACTIVE_HIGH>;
			max8998,pmic-buck1-dvs-voltage = <1200000>, <1200000>,
							<1200000>, <1200000>;

			max8998,pmic-buck2-default-dvs-idx = <0>;
			max8998,pmic-buck2-dvs-gpio = <&gph0 5 GPIO_ACTIVE_HIGH>;
			max8998,pmic-buck2-dvs-voltage = <1200000>, <1200000>;

			regulators {
				ldo2_reg: LDO2 {
					regulator-name = "VALIVE_1.1V";
					regulator-min-microvolt = <1100000>;
					regulator-max-microvolt = <1100000>;
					regulator-always-on;
				};

				ldo3_reg: LDO3 {
					regulator-name = "VUSB+MIPI_1.1V";
					regulator-min-microvolt = <1100000>;
					regulator-max-microvolt = <1100000>;
					regulator-always-on;
				};

				ldo4_reg: LDO4 {
					regulator-name = "VADC_3.3V";
					regulator-min-microvolt = <3300000>;
					regulator-max-microvolt = <3300000>;
				};

				ldo5_reg: LDO5 {
					regulator-name = "VTF_2.8V";
					regulator-min-microvolt = <2800000>;
					regulator-max-microvolt = <2800000>;
				};

				ldo6_reg: LDO6 {
					regulator-name = "VCC_3.3V";
					regulator-min-microvolt = <3300000>;
					regulator-max-microvolt = <3300000>;
				};

				ldo7_reg: LDO7 {
					regulator-name = "VLCD_1.8V";
					regulator-min-microvolt = <1800000>;
					regulator-max-microvolt = <1800000>;
					regulator-always-on;
				};

				ldo8_reg: LDO8 {
					regulator-name = "VUSB+VDAC_3.3V";
					regulator-min-microvolt = <3300000>;
					regulator-max-microvolt = <3300000>;
				};

				ldo9_reg: LDO9 {
					regulator-name = "VCC+VCAM_2.8V";
					regulator-min-microvolt = <2800000>;
					regulator-max-microvolt = <2800000>;
				};

				ldo10_reg: LDO10 {
					regulator-name = "VPLL_1.1V";
					regulator-min-microvolt = <1100000>;
					regulator-max-microvolt = <1100000>;
					regulator-boot-on;
				};

				ldo11_reg: LDO11 {
					regulator-name = "CAM_IO_2.8V";
					regulator-min-microvolt = <2800000>;
					regulator-max-microvolt = <2800000>;
				};

				ldo12_reg: LDO12 {
					regulator-name = "CAM_ISP_1.2V";
					regulator-min-microvolt = <1200000>;
					regulator-max-microvolt = <1200000>;
				};

				ldo13_reg: LDO13 {
					regulator-name = "CAM_A_2.8V";
					regulator-min-microvolt = <2800000>;
					regulator-max-microvolt = <2800000>;
				};

				ldo14_reg: LDO14 {
					regulator-name = "CAM_CIF_1.8V";
					regulator-min-microvolt = <1800000>;
					regulator-max-microvolt = <1800000>;
				};

				ldo15_reg: LDO15 {
					regulator-name = "CAM_AF_3.3V";
					regulator-min-microvolt = <3300000>;
					regulator-max-microvolt = <3300000>;
				};

				ldo16_reg: LDO16 {
					regulator-name = "VMIPI_1.8V";
					regulator-min-microvolt = <1800000>;
					regulator-max-microvolt = <1800000>;
				};

				ldo17_reg: LDO17 {
					regulator-name = "CAM_8M_1.8V";
					regulator-min-microvolt = <1800000>;
					regulator-max-microvolt = <1800000>;
					regulator-always-on;
				};

				buck1_reg: BUCK1 {
					regulator-name = "VARM_1.2V";
					regulator-min-microvolt = <1200000>;
					regulator-max-microvolt = <1200000>;
				};

				buck2_reg: BUCK2 {
					regulator-name = "VINT_1.2V";
					regulator-min-microvolt = <1200000>;
					regulator-max-microvolt = <1200000>;
				};

				buck3_reg: BUCK3 {
					regulator-name = "VCC_1.8V";
					regulator-min-microvolt = <1800000>;
					regulator-max-microvolt = <1800000>;
					regulator-always-on;
				};

				buck4_reg: BUCK4 {
					regulator-name = "CAM_CORE_1.2V";
					regulator-min-microvolt = <1200000>;
					regulator-max-microvolt = <1200000>;
					regulator-always-on;
				};

				ap32khz_reg: EN32KHz-AP {
					regulator-name = "32KHz AP";
					regulator-always-on;
				};
			};
		};
	};

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

		power-key {
			gpios = <&gph2 6 1>;
			linux,code = <KEY_POWER>;
			label = "power";
			debounce-interval = <1>;
			wakeup-source;
		};
	};
};

&xusbxti {
	clock-frequency = <24000000>;
};

&keypad {
	linux,input-no-autorepeat;
	wakeup-source;
	samsung,keypad-num-rows = <3>;
	samsung,keypad-num-columns = <3>;
	pinctrl-names = "default";
	pinctrl-0 = <&keypad_row0>, <&keypad_row1>, <&keypad_row2>,
			<&keypad_col0>, <&keypad_col1>, <&keypad_col2>;
	status = "okay";

	key-1 {
		keypad,row = <0>;
		keypad,column = <1>;
		linux,code = <KEY_CONNECT>;
	};

	key-2 {
		keypad,row = <0>;
		keypad,column = <2>;
		linux,code = <KEY_BACK>;
	};

	key-3 {
		keypad,row = <1>;
		keypad,column = <1>;
		linux,code = <KEY_CAMERA_FOCUS>;
	};

	key-4 {
		keypad,row = <1>;
		keypad,column = <2>;
		linux,code = <KEY_VOLUMEUP>;
	};

	key-5 {
		keypad,row = <2>;
		keypad,column = <1>;
		linux,code = <KEY_CAMERA>;
	};

	key-6 {
		keypad,row = <2>;
		keypad,column = <2>;
		linux,code = <KEY_VOLUMEDOWN>;
	};
};

&uart0 {
	status = "okay";
};

&uart1 {
	status = "okay";
};

&uart2 {
	status = "okay";
};

&uart3 {
	status = "okay";
};

&rtc {
	clocks = <&clocks CLK_RTC>, <&pmic_ap_clk>;
	clock-names = "rtc", "rtc_src";
};

&sdhci0 {
	bus-width = <4>;
	non-removable;
	vmmc-supply = <&ldo5_reg>;
	pinctrl-0 = <&sd0_clk &sd0_cmd &sd0_cd &sd0_bus1 &sd0_bus4>;
	pinctrl-names = "default";
	status = "okay";
};

&sdhci2 {
	bus-width = <4>;
	cd-gpios = <&gph3 4 1>;
	vmmc-supply = <&vtf_reg>;
	cd-inverted;
	pinctrl-0 = <&sd2_clk &sd2_cmd &sd2_bus4>;
	pinctrl-names = "default";
	status = "okay";
};

&hsotg {
	vusb_a-supply = <&ldo3_reg>;
	vusb_d-supply = <&ldo8_reg>;
	dr_mode = "peripheral";
	status = "okay";
};

&usbphy {
	status = "okay";
};

&i2c2 {
	samsung,i2c-sda-delay = <100>;
	samsung,i2c-max-bus-freq = <400000>;
	samsung,i2c-slave-addr = <0x10>;
	status = "okay";

	touchscreen@4a {
		compatible = "atmel,maxtouch";
		reg = <0x4a>;
		interrupt-parent = <&gpj0>;
		interrupts = <5 IRQ_TYPE_EDGE_FALLING>;
		vdd-supply = <&tsp_reg>;
	};
};

&i2c0 {
	samsung,i2c-sda-delay = <100>;
	samsung,i2c-max-bus-freq = <100000>;
	samsung,i2c-slave-addr = <0x10>;
	status = "okay";

	noon010pc30: sensor@30 {
		compatible = "siliconfile,noon010pc30";
		reg = <0x30>;
		vddio-supply = <&ldo11_reg>;
		vdda-supply = <&ldo13_reg>;
		vdd_core-supply = <&ldo14_reg>;

		clock-frequency = <16000000>;
		clocks = <&camera 0>;
		clock-names = "mclk";
		nreset-gpios = <&gpb 2 GPIO_ACTIVE_HIGH>;
		nstby-gpios = <&gpb 0 GPIO_ACTIVE_HIGH>;

		port {
			noon010pc30_ep: endpoint {
				remote-endpoint = <&fimc0_ep>;
				bus-width = <8>;
				hsync-active = <0>;
				vsync-active = <1>;
				pclk-sample = <1>;
			};
		};
	};
};

&camera {
	pinctrl-0 = <&cam_port_a_io &cam_port_a_clk_active>;
	pinctrl-1 = <&cam_port_a_io &cam_port_a_clk_idle>;
	pinctrl-names = "default", "idle";

	parallel-ports {
		#address-cells = <1>;
		#size-cells = <0>;

		/* camera A input */
		port@1 {
			reg = <1>;
			fimc0_ep: endpoint {
				remote-endpoint = <&noon010pc30_ep>;
				bus-width = <8>;
				hsync-active = <1>;
				vsync-active = <1>;
				pclk-sample = <0>;
			};
		};
	};
};

&fimd {
	pinctrl-0 = <&lcd_clk &lcd_data24>;
	pinctrl-names = "default";
	status = "okay";

	display-timings {
		native-mode = <&timing0>;
		timing0: timing {
			/* 480x800@55Hz */
			clock-frequency = <23439570>;
			hactive = <480>;
			hfront-porch = <16>;
			hback-porch = <16>;
			hsync-len = <2>;
			vactive = <800>;
			vback-porch = <2>;
			vfront-porch = <28>;
			vsync-len = <1>;
			hsync-active = <0>;
			vsync-active = <0>;
			de-active = <0>;
			pixelclk-active = <0>;
		};
	};
};

&onenand {
	status = "okay";
};


code:
// SPDX-License-Identifier: GPL-2.0
/*
 * Samsung's S5PV210 SoC device tree source
 *
 * Copyright (c) 2013-2014 Samsung Electronics, Co. Ltd.
 *
 * Mateusz Krawczuk <m.krawczuk@partner.samsung.com>
 * Tomasz Figa <t.figa@samsung.com>
 *
 * Samsung's S5PV210 SoC device nodes are listed in this file. S5PV210
 * based board files can include this file and provide values for board specfic
 * bindings.
 *
 * Note: This file does not include device nodes for all the controllers in
 * S5PV210 SoC. As device tree coverage for S5PV210 increases, additional
 * nodes can be added to this file.
 */

#include "s5pv210-pinctrl.h"

#define PIN_SLP(_pin, _mode, _pull)					\
	_pin {								\
		samsung,pins = #_pin;					\
		samsung,pin-con-pdn = <S5PV210_PIN_PDN_ ##_mode>;	\
		samsung,pin-pud-pdn = <S5PV210_PIN_PULL_ ##_pull>;	\
	}

&pinctrl0 {
	gpa0: gpa0-gpio-bank {
		gpio-controller;
		#gpio-cells = <2>;

		interrupt-controller;
		#interrupt-cells = <2>;
	};

	gpa1: gpa1-gpio-bank {
		gpio-controller;
		#gpio-cells = <2>;

		interrupt-controller;
		#interrupt-cells = <2>;
	};

	gpb: gpb-gpio-bank {
		gpio-controller;
		#gpio-cells = <2>;

		interrupt-controller;
		#interrupt-cells = <2>;
	};

	gpc0: gpc0-gpio-bank {
		gpio-controller;
		#gpio-cells = <2>;

		interrupt-controller;
		#interrupt-cells = <2>;
	};

	gpc1: gpc1-gpio-bank {
		gpio-controller;
		#gpio-cells = <2>;

		interrupt-controller;
		#interrupt-cells = <2>;
	};

	gpd0: gpd0-gpio-bank {
		gpio-controller;
		#gpio-cells = <2>;

		interrupt-controller;
		#interrupt-cells = <2>;
	};

	gpd1: gpd1-gpio-bank {
		gpio-controller;
		#gpio-cells = <2>;

		interrupt-controller;
		#interrupt-cells = <2>;
	};

	gpe0: gpe0-gpio-bank {
		gpio-controller;
		#gpio-cells = <2>;

		interrupt-controller;
		#interrupt-cells = <2>;
	};

	gpe1: gpe1-gpio-bank {
		gpio-controller;
		#gpio-cells = <2>;

		interrupt-controller;
		#interrupt-cells = <2>;
	};

	gpf0: gpf0-gpio-bank {
		gpio-controller;
		#gpio-cells = <2>;

		interrupt-controller;
		#interrupt-cells = <2>;
	};

	gpf1: gpf1-gpio-bank {
		gpio-controller;
		#gpio-cells = <2>;

		interrupt-controller;
		#interrupt-cells = <2>;
	};

	gpf2: gpf2-gpio-bank {
		gpio-controller;
		#gpio-cells = <2>;

		interrupt-controller;
		#interrupt-cells = <2>;
	};

	gpf3: gpf3-gpio-bank {
		gpio-controller;
		#gpio-cells = <2>;

		interrupt-controller;
		#interrupt-cells = <2>;
	};

	gpg0: gpg0-gpio-bank {
		gpio-controller;
		#gpio-cells = <2>;

		interrupt-controller;
		#interrupt-cells = <2>;
	};

	gpg1: gpg1-gpio-bank {
		gpio-controller;
		#gpio-cells = <2>;

		interrupt-controller;
		#interrupt-cells = <2>;
	};

	gpg2: gpg2-gpio-bank {
		gpio-controller;
		#gpio-cells = <2>;

		interrupt-controller;
		#interrupt-cells = <2>;
	};

	gpg3: gpg3-gpio-bank {
		gpio-controller;
		#gpio-cells = <2>;

		interrupt-controller;
		#interrupt-cells = <2>;
	};

	gpj0: gpj0-gpio-bank {
		gpio-controller;
		#gpio-cells = <2>;

		interrupt-controller;
		#interrupt-cells = <2>;
	};

	gpj1: gpj1-gpio-bank {
		gpio-controller;
		#gpio-cells = <2>;

		interrupt-controller;
		#interrupt-cells = <2>;
	};

	gpj2: gpj2-gpio-bank {
		gpio-controller;
		#gpio-cells = <2>;

		interrupt-controller;
		#interrupt-cells = <2>;
	};

	gpj3: gpj3-gpio-bank {
		gpio-controller;
		#gpio-cells = <2>;

		interrupt-controller;
		#interrupt-cells = <2>;
	};

	gpj4: gpj4-gpio-bank {
		gpio-controller;
		#gpio-cells = <2>;

		interrupt-controller;
		#interrupt-cells = <2>;
	};

	gpi: gpi-gpio-bank {
		gpio-controller;
		#gpio-cells = <2>;
	};

	mp01: mp01-gpio-bank {
		gpio-controller;
		#gpio-cells = <2>;
	};

	mp02: mp02-gpio-bank {
		gpio-controller;
		#gpio-cells = <2>;
	};

	mp03: mp03-gpio-bank {
		gpio-controller;
		#gpio-cells = <2>;
	};

	mp04: mp04-gpio-bank {
		gpio-controller;
		#gpio-cells = <2>;
	};

	mp05: mp05-gpio-bank {
		gpio-controller;
		#gpio-cells = <2>;
	};

	mp06: mp06-gpio-bank {
		gpio-controller;
		#gpio-cells = <2>;
	};

	mp07: mp07-gpio-bank {
		gpio-controller;
		#gpio-cells = <2>;
	};

	gph0: gph0-gpio-bank {
		gpio-controller;
		interrupt-controller;
		interrupt-parent = <&vic0>;
		interrupts = <0>, <1>, <2>, <3>,
				<4>, <5>, <6>, <7>;
		#gpio-cells = <2>;
		#interrupt-cells = <2>;
	};

	gph1: gph1-gpio-bank {
		gpio-controller;
		interrupt-controller;
		interrupt-parent = <&vic0>;
		interrupts = <8>, <9>, <10>, <11>,
				<12>, <13>, <14>, <15>;
		#gpio-cells = <2>;
		#interrupt-cells = <2>;
	};

	gph2: gph2-gpio-bank {
		gpio-controller;
		#gpio-cells = <2>;

		interrupt-controller;
		#interrupt-cells = <2>;
	};

	gph3: gph3-gpio-bank {
		gpio-controller;
		#gpio-cells = <2>;

		interrupt-controller;
		#interrupt-cells = <2>;
	};

	uart0_data: uart0-data-pins {
		samsung,pins = "gpa0-0", "gpa0-1";
		samsung,pin-function = <S5PV210_PIN_FUNC_2>;
		samsung,pin-pud = <S5PV210_PIN_PULL_NONE>;
		samsung,pin-drv = <S5PV210_PIN_DRV_LV1>;
	};

	uart0_fctl: uart0-fctl-pins {
		samsung,pins = "gpa0-2", "gpa0-3";
		samsung,pin-function = <S5PV210_PIN_FUNC_2>;
		samsung,pin-pud = <S5PV210_PIN_PULL_NONE>;
		samsung,pin-drv = <S5PV210_PIN_DRV_LV1>;
	};

	uart1_data: uart1-data-pins {
		samsung,pins = "gpa0-4", "gpa0-5";
		samsung,pin-function = <S5PV210_PIN_FUNC_2>;
		samsung,pin-pud = <S5PV210_PIN_PULL_NONE>;
		samsung,pin-drv = <S5PV210_PIN_DRV_LV1>;
	};

	uart1_fctl: uart1-fctl-pins {
		samsung,pins = "gpa0-6", "gpa0-7";
		samsung,pin-function = <S5PV210_PIN_FUNC_2>;
		samsung,pin-pud = <S5PV210_PIN_PULL_NONE>;
		samsung,pin-drv = <S5PV210_PIN_DRV_LV1>;
	};

	uart2_data: uart2-data-pins {
		samsung,pins = "gpa1-0", "gpa1-1";
		samsung,pin-function = <S5PV210_PIN_FUNC_2>;
		samsung,pin-pud = <S5PV210_PIN_PULL_NONE>;
		samsung,pin-drv = <S5PV210_PIN_DRV_LV1>;
	};

	uart2_fctl: uart2-fctl-pins {
		samsung,pins = "gpa1-2", "gpa1-3";
		samsung,pin-function = <S5PV210_PIN_FUNC_3>;
		samsung,pin-pud = <S5PV210_PIN_PULL_NONE>;
		samsung,pin-drv = <S5PV210_PIN_DRV_LV1>;
	};

	uart3_data: uart3-data-pins {
		samsung,pins = "gpa1-2", "gpa1-3";
		samsung,pin-function = <S5PV210_PIN_FUNC_2>;
		samsung,pin-pud = <S5PV210_PIN_PULL_NONE>;
		samsung,pin-drv = <S5PV210_PIN_DRV_LV1>;
	};

	uart_audio: uart-audio-pins {
		samsung,pins = "gpa1-2", "gpa1-3";
		samsung,pin-function = <S5PV210_PIN_FUNC_4>;
		samsung,pin-pud = <S5PV210_PIN_PULL_NONE>;
		samsung,pin-drv = <S5PV210_PIN_DRV_LV1>;
	};

	spi0_bus: spi0-bus-pins {
		samsung,pins = "gpb-0", "gpb-2", "gpb-3";
		samsung,pin-function = <S5PV210_PIN_FUNC_2>;
		samsung,pin-pud = <S5PV210_PIN_PULL_UP>;
		samsung,pin-drv = <S5PV210_PIN_DRV_LV1>;
	};

	spi1_bus: spi1-bus-pins {
		samsung,pins = "gpb-4", "gpb-6", "gpb-7";
		samsung,pin-function = <S5PV210_PIN_FUNC_2>;
		samsung,pin-pud = <S5PV210_PIN_PULL_UP>;
		samsung,pin-drv = <S5PV210_PIN_DRV_LV1>;
	};

	i2s0_bus: i2s0-bus-pins {
		samsung,pins = "gpi-0", "gpi-1", "gpi-2", "gpi-3",
				"gpi-4", "gpi-5", "gpi-6";
		samsung,pin-function = <S5PV210_PIN_FUNC_2>;
		samsung,pin-pud = <S5PV210_PIN_PULL_NONE>;
		samsung,pin-drv = <S5PV210_PIN_DRV_LV1>;
	};

	i2s1_bus: i2s1-bus-pins {
		samsung,pins = "gpc0-0", "gpc0-1", "gpc0-2", "gpc0-3",
				"gpc0-4";
		samsung,pin-function = <S5PV210_PIN_FUNC_2>;
		samsung,pin-pud = <S5PV210_PIN_PULL_NONE>;
		samsung,pin-drv = <S5PV210_PIN_DRV_LV1>;
	};

	i2s2_bus: i2s2-bus-pins {
		samsung,pins = "gpc1-0", "gpc1-1", "gpc1-2", "gpc1-3",
				"gpc1-4";
		samsung,pin-function = <S5PV210_PIN_FUNC_4>;
		samsung,pin-pud = <S5PV210_PIN_PULL_NONE>;
		samsung,pin-drv = <S5PV210_PIN_DRV_LV1>;
	};

	pcm1_bus: pcm1-bus-pins {
		samsung,pins = "gpc0-0", "gpc0-1", "gpc0-2", "gpc0-3",
				"gpc0-4";
		samsung,pin-function = <S5PV210_PIN_FUNC_3>;
		samsung,pin-pud = <S5PV210_PIN_PULL_NONE>;
		samsung,pin-drv = <S5PV210_PIN_DRV_LV1>;
	};

	ac97_bus: ac97-bus-pins {
		samsung,pins = "gpc0-0", "gpc0-1", "gpc0-2", "gpc0-3",
				"gpc0-4";
		samsung,pin-function = <S5PV210_PIN_FUNC_4>;
		samsung,pin-pud = <S5PV210_PIN_PULL_NONE>;
		samsung,pin-drv = <S5PV210_PIN_DRV_LV1>;
	};

	i2s2_bus: i2s2-bus-pins {
		samsung,pins = "gpc1-0", "gpc1-1", "gpc1-2", "gpc1-3",
				"gpc1-4";
		samsung,pin-function = <S5PV210_PIN_FUNC_2>;
		samsung,pin-pud = <S5PV210_PIN_PULL_NONE>;
		samsung,pin-drv = <S5PV210_PIN_DRV_LV1>;
	};

	pcm2_bus: pcm2-bus-pins {
		samsung,pins = "gpc1-0", "gpc1-1", "gpc1-2", "gpc1-3",
				"gpc1-4";
		samsung,pin-function = <S5PV210_PIN_FUNC_3>;
		samsung,pin-pud = <S5PV210_PIN_PULL_NONE>;
		samsung,pin-drv = <S5PV210_PIN_DRV_LV1>;
	};

	spdif_bus: spdif-bus-pins {
		samsung,pins = "gpc1-0", "gpc1-1";
		samsung,pin-function = <S5PV210_PIN_FUNC_4>;
		samsung,pin-pud = <S5PV210_PIN_PULL_NONE>;
		samsung,pin-drv = <S5PV210_PIN_DRV_LV1>;
	};

	spi2_bus: spi2-bus-pins {
		samsung,pins = "gpc1-1", "gpc1-2", "gpc1-3", "gpc1-4";
		samsung,pin-function = <S5PV210_PIN_FUNC_5>;
		samsung,pin-pud = <S5PV210_PIN_PULL_UP>;
		samsung,pin-drv = <S5PV210_PIN_DRV_LV1>;
	};

	i2c0_bus: i2c0-bus-pins {
		samsung,pins = "gpd1-0", "gpd1-1";
		samsung,pin-function = <S5PV210_PIN_FUNC_2>;
		samsung,pin-pud = <S5PV210_PIN_PULL_UP>;
		samsung,pin-drv = <S5PV210_PIN_DRV_LV1>;
	};

	i2c1_bus: i2c1-bus-pins {
		samsung,pins = "gpd1-2", "gpd1-3";
		samsung,pin-function = <S5PV210_PIN_FUNC_2>;
		samsung,pin-pud = <S5PV210_PIN_PULL_UP>;
		samsung,pin-drv = <S5PV210_PIN_DRV_LV1>;
	};

	i2c2_bus: i2c2-bus-pins {
		samsung,pins = "gpd1-4", "gpd1-5";
		samsung,pin-function = <S5PV210_PIN_FUNC_2>;
		samsung,pin-pud = <S5PV210_PIN_PULL_UP>;
		samsung,pin-drv = <S5PV210_PIN_DRV_LV1>;
	};

	pwm0_out: pwm0-out-pins {
		samsung,pins = "gpd0-0";
		samsung,pin-function = <S5PV210_PIN_FUNC_2>;
		samsung,pin-pud = <S5PV210_PIN_PULL_NONE>;
		samsung,pin-drv = <S5PV210_PIN_DRV_LV1>;
	};

	pwm1_out: pwm1-out-pins {
		samsung,pins = "gpd0-1";
		samsung,pin-function = <S5PV210_PIN_FUNC_2>;
		samsung,pin-pud = <S5PV210_PIN_PULL_NONE>;
		samsung,pin-drv = <S5PV210_PIN_DRV_LV1>;
	};

	pwm2_out: pwm2-out-pins {
		samsung,pins = "gpd0-2";
		samsung,pin-function = <S5PV210_PIN_FUNC_2>;
		samsung,pin-pud = <S5PV210_PIN_PULL_NONE>;
		samsung,pin-drv = <S5PV210_PIN_DRV_LV1>;
	};

	pwm3_out: pwm3-out-pins {
		samsung,pins = "gpd0-3";
		samsung,pin-function = <S5PV210_PIN_FUNC_2>;
		samsung,pin-pud = <S5PV210_PIN_PULL_NONE>;
		samsung,pin-drv = <S5PV210_PIN_DRV_LV1>;
	};

	keypad_row0: keypad-row-0-pins {
		samsung,pins = "gph3-0";
		samsung,pin-function = <S5PV210_PIN_FUNC_3>;
		samsung,pin-pud = <S5PV210_PIN_PULL_NONE>;
		samsung,pin-drv = <S5PV210_PIN_DRV_LV1>;
	};

	keypad_row1: keypad-row-1-pins {
		samsung,pins = "gph3-1";
		samsung,pin-function = <S5PV210_PIN_FUNC_3>;
		samsung,pin-pud = <S5PV210_PIN_PULL_NONE>;
		samsung,pin-drv = <S5PV210_PIN_DRV_LV1>;
	};

	keypad_row2: keypad-row-2-pins {
		samsung,pins = "gph3-2";
		samsung,pin-function = <S5PV210_PIN_FUNC_3>;
		samsung,pin-pud = <S5PV210_PIN_PULL_NONE>;
		samsung,pin-drv = <S5PV210_PIN_DRV_LV1>;
	};

	keypad_row3: keypad-row-3-pins {
		samsung,pins = "gph3-3";
		samsung,pin-function = <S5PV210_PIN_FUNC_3>;
		samsung,pin-pud = <S5PV210_PIN_PULL_NONE>;
		samsung,pin-drv = <S5PV210_PIN_DRV_LV1>;
	};

	keypad_row4: keypad-row-4-pins {
		samsung,pins = "gph3-4";
		samsung,pin-function = <S5PV210_PIN_FUNC_3>;
		samsung,pin-pud = <S5PV210_PIN_PULL_NONE>;
		samsung,pin-drv = <S5PV210_PIN_DRV_LV1>;
	};

	keypad_row5: keypad-row-5-pins {
		samsung,pins = "gph3-5";
		samsung,pin-function = <S5PV210_PIN_FUNC_3>;
		samsung,pin-pud = <S5PV210_PIN_PULL_NONE>;
		samsung,pin-drv = <S5PV210_PIN_DRV_LV1>;
	};

	keypad_row6: keypad-row-6-pins {
		samsung,pins = "gph3-6";
		samsung,pin-function = <S5PV210_PIN_FUNC_3>;
		samsung,pin-pud = <S5PV210_PIN_PULL_NONE>;
		samsung,pin-drv = <S5PV210_PIN_DRV_LV1>;
	};

	keypad_row7: keypad-row-7-pins {
		samsung,pins = "gph3-7";
		samsung,pin-function = <S5PV210_PIN_FUNC_3>;
		samsung,pin-pud = <S5PV210_PIN_PULL_NONE>;
		samsung,pin-drv = <S5PV210_PIN_DRV_LV1>;
	};

	keypad_col0: keypad-col-0-pins {
		samsung,pins = "gph2-0";
		samsung,pin-function = <S5PV210_PIN_FUNC_3>;
		samsung,pin-pud = <S5PV210_PIN_PULL_NONE>;
		samsung,pin-drv = <S5PV210_PIN_DRV_LV1>;
	};

	keypad_col1: keypad-col-1-pins {
		samsung,pins = "gph2-1";
		samsung,pin-function = <S5PV210_PIN_FUNC_3>;
		samsung,pin-pud = <S5PV210_PIN_PULL_NONE>;
		samsung,pin-drv = <S5PV210_PIN_DRV_LV1>;
	};

	keypad_col2: keypad-col-2-pins {
		samsung,pins = "gph2-2";
		samsung,pin-function = <S5PV210_PIN_FUNC_3>;
		samsung,pin-pud = <S5PV210_PIN_PULL_NONE>;
		samsung,pin-drv = <S5PV210_PIN_DRV_LV1>;
	};

	keypad_col3: keypad-col-3-pins {
		samsung,pins = "gph2-3";
		samsung,pin-function = <S5PV210_PIN_FUNC_3>;
		samsung,pin-pud = <S5PV210_PIN_PULL_NONE>;
		samsung,pin-drv = <S5PV210_PIN_DRV_LV1>;
	};

	keypad_col4: keypad-col-4-pins {
		samsung,pins = "gph2-4";
		samsung,pin-function = <S5PV210_PIN_FUNC_3>;
		samsung,pin-pud = <S5PV210_PIN_PULL_NONE>;
		samsung,pin-drv = <S5PV210_PIN_DRV_LV1>;
	};

	keypad_col5: keypad-col-5-pins {
		samsung,pins = "gph2-5";
		samsung,pin-function = <S5PV210_PIN_FUNC_3>;
		samsung,pin-pud = <S5PV210_PIN_PULL_NONE>;
		samsung,pin-drv = <S5PV210_PIN_DRV_LV1>;
	};

	keypad_col6: keypad-col-6-pins {
		samsung,pins = "gph2-6";
		samsung,pin-function = <S5PV210_PIN_FUNC_3>;
		samsung,pin-pud = <S5PV210_PIN_PULL_NONE>;
		samsung,pin-drv = <S5PV210_PIN_DRV_LV1>;
	};

	keypad_col7: keypad-col-7-pins {
		samsung,pins = "gph2-7";
		samsung,pin-function = <S5PV210_PIN_FUNC_3>;
		samsung,pin-pud = <S5PV210_PIN_PULL_NONE>;
		samsung,pin-drv = <S5PV210_PIN_DRV_LV1>;
	};

	sd0_clk: sd0-clk-pins {
		samsung,pins = "gpg0-0";
		samsung,pin-function = <S5PV210_PIN_FUNC_2>;
		samsung,pin-pud = <S5PV210_PIN_PULL_NONE>;
		samsung,pin-drv = <S5PV210_PIN_DRV_LV4>;
	};

	sd0_cmd: sd0-cmd-pins {
		samsung,pins = "gpg0-1";
		samsung,pin-function = <S5PV210_PIN_FUNC_2>;
		samsung,pin-pud = <S5PV210_PIN_PULL_NONE>;
		samsung,pin-drv = <S5PV210_PIN_DRV_LV4>;
	};

	sd0_cd: sd0-cd-pins {
		samsung,pins = "gpg0-2";
		samsung,pin-function = <S5PV210_PIN_FUNC_2>;
		samsung,pin-pud = <S5PV210_PIN_PULL_UP>;
		samsung,pin-drv = <S5PV210_PIN_DRV_LV4>;
	};

	sd0_bus1: sd0-bus-width1-pins {
		samsung,pins = "gpg0-3";
		samsung,pin-function = <S5PV210_PIN_FUNC_2>;
		samsung,pin-pud = <S5PV210_PIN_PULL_UP>;
		samsung,pin-drv = <S5PV210_PIN_DRV_LV4>;
	};

	sd0_bus4: sd0-bus-width4-pins {
		samsung,pins = "gpg0-3", "gpg0-4", "gpg0-5", "gpg0-6";
		samsung,pin-function = <S5PV210_PIN_FUNC_2>;
		samsung,pin-pud = <S5PV210_PIN_PULL_UP>;
		samsung,pin-drv = <S5PV210_PIN_DRV_LV4>;
	};

	sd0_bus8: sd0-bus-width8-pins {
		samsung,pins = "gpg1-3", "gpg1-4", "gpg1-5", "gpg1-6";
		samsung,pin-function = <S5PV210_PIN_FUNC_3>;
		samsung,pin-pud = <S5PV210_PIN_PULL_UP>;
		samsung,pin-drv = <S5PV210_PIN_DRV_LV4>;
	};

	sd1_clk: sd1-clk-pins {
		samsung,pins = "gpg1-0";
		samsung,pin-function = <S5PV210_PIN_FUNC_2>;
		samsung,pin-pud = <S5PV210_PIN_PULL_NONE>;
		samsung,pin-drv = <S5PV210_PIN_DRV_LV4>;
	};

	sd1_cmd: sd1-cmd-pins {
		samsung,pins = "gpg1-1";
		samsung,pin-function = <S5PV210_PIN_FUNC_2>;
		samsung,pin-pud = <S5PV210_PIN_PULL_NONE>;
		samsung,pin-drv = <S5PV210_PIN_DRV_LV4>;
	};

	sd1_cd: sd1-cd-pins {
		samsung,pins = "gpg1-2";
		samsung,pin-function = <S5PV210_PIN_FUNC_2>;
		samsung,pin-pud = <S5PV210_PIN_PULL_UP>;
		samsung,pin-drv = <S5PV210_PIN_DRV_LV4>;
	};

	sd1_bus1: sd1-bus-width1-pins {
		samsung,pins = "gpg1-3";
		samsung,pin-function = <S5PV210_PIN_FUNC_2>;
		samsung,pin-pud = <S5PV210_PIN_PULL_UP>;
		samsung,pin-drv = <S5PV210_PIN_DRV_LV4>;
	};

	sd1_bus4: sd1-bus-width4-pins {
		samsung,pins = "gpg1-3", "gpg1-4", "gpg1-5", "gpg1-6";
		samsung,pin-function = <S5PV210_PIN_FUNC_2>;
		samsung,pin-pud = <S5PV210_PIN_PULL_UP>;
		samsung,pin-drv = <S5PV210_PIN_DRV_LV4>;
	};

	sd2_clk: sd2-clk-pins {
		samsung,pins = "gpg2-0";
		samsung,pin-function = <S5PV210_PIN_FUNC_2>;
		samsung,pin-pud = <S5PV210_PIN_PULL_NONE>;
		samsung,pin-drv = <S5PV210_PIN_DRV_LV4>;
	};

	sd2_cmd: sd2-cmd-pins {
		samsung,pins = "gpg2-1";
		samsung,pin-function = <S5PV210_PIN_FUNC_2>;
		samsung,pin-pud = <S5PV210_PIN_PULL_NONE>;
		samsung,pin-drv = <S5PV210_PIN_DRV_LV4>;
	};

	sd2_cd: sd2-cd-pins {
		samsung,pins = "gpg2-2";
		samsung,pin-function = <S5PV210_PIN_FUNC_2>;
		samsung,pin-pud = <S5PV210_PIN_PULL_UP>;
		samsung,pin-drv = <S5PV210_PIN_DRV_LV4>;
	};

	sd2_bus1: sd2-bus-width1-pins {
		samsung,pins = "gpg2-3";
		samsung,pin-function = <S5PV210_PIN_FUNC_2>;
		samsung,pin-pud = <S5PV210_PIN_PULL_UP>;
		samsung,pin-drv = <S5PV210_PIN_DRV_LV4>;
	};

	sd2_bus4: sd2-bus-width4-pins {
		samsung,pins = "gpg2-3", "gpg2-4", "gpg2-5", "gpg2-6";
		samsung,pin-function = <S5PV210_PIN_FUNC_2>;
		samsung,pin-pud = <S5PV210_PIN_PULL_UP>;
		samsung,pin-drv = <S5PV210_PIN_DRV_LV4>;
	};

	sd2_bus8: sd2-bus-width8-pins {
		samsung,pins = "gpg3-3", "gpg3-4", "gpg3-5", "gpg3-6";
		samsung,pin-function = <S5PV210_PIN_FUNC_3>;
		samsung,pin-pud = <S5PV210_PIN_PULL_UP>;
		samsung,pin-drv = <S5PV210_PIN_DRV_LV4>;
	};

	sd3_clk: sd3-clk-pins {
		samsung,pins = "gpg3-0";
		samsung,pin-function = <S5PV210_PIN_FUNC_2>;
		samsung,pin-pud = <S5PV210_PIN_PULL_NONE>;
		samsung,pin-drv = <S5PV210_PIN_DRV_LV4>;
	};

	sd3_cmd: sd3-cmd-pins {
		samsung,pins = "gpg3-1";
		samsung,pin-function = <S5PV210_PIN_FUNC_2>;
		samsung,pin-pud = <S5PV210_PIN_PULL_NONE>;
		samsung,pin-drv = <S5PV210_PIN_DRV_LV4>;
	};

	sd3_cd: sd3-cd-pins {
		samsung,pins = "gpg3-2";
		samsung,pin-function = <S5PV210_PIN_FUNC_2>;
		samsung,pin-pud = <S5PV210_PIN_PULL_UP>;
		samsung,pin-drv = <S5PV210_PIN_DRV_LV4>;
	};

	sd3_bus1: sd3-bus-width1-pins {
		samsung,pins = "gpg3-3";
		samsung,pin-function = <S5PV210_PIN_FUNC_2>;
		samsung,pin-pud = <S5PV210_PIN_PULL_UP>;
		samsung,pin-drv = <S5PV210_PIN_DRV_LV4>;
	};

	sd3_bus4: sd3-bus-width4-pins {
		samsung,pins = "gpg3-3", "gpg3-4", "gpg3-5", "gpg3-6";
		samsung,pin-function = <S5PV210_PIN_FUNC_2>;
		samsung,pin-pud = <S5PV210_PIN_PULL_UP>;
		samsung,pin-drv = <S5PV210_PIN_DRV_LV4>;
	};

	eint0: ext-int0-pins {
		samsung,pins = "gph0-0";
		samsung,pin-function = <S5PV210_PIN_FUNC_F>;
		samsung,pin-pud = <S5PV210_PIN_PULL_NONE>;
		samsung,pin-drv = <S5PV210_PIN_DRV_LV1>;
	};

	eint8: ext-int8-pins {
		samsung,pins = "gph1-0";
		samsung,pin-function = <S5PV210_PIN_FUNC_F>;
		samsung,pin-pud = <S5PV210_PIN_PULL_NONE>;
		samsung,pin-drv = <S5PV210_PIN_DRV_LV1>;
	};

	eint15: ext-int15-pins {
		samsung,pins = "gph1-7";
		samsung,pin-function = <S5PV210_PIN_FUNC_F>;
		samsung,pin-pud = <S5PV210_PIN_PULL_NONE>;
		samsung,pin-drv = <S5PV210_PIN_DRV_LV1>;
	};

	eint16: ext-int16-pins {
		samsung,pins = "gph2-0";
		samsung,pin-function = <S5PV210_PIN_FUNC_F>;
		samsung,pin-pud = <S5PV210_PIN_PULL_NONE>;
		samsung,pin-drv = <S5PV210_PIN_DRV_LV1>;
	};

	eint31: ext-int31-pins {
		samsung,pins = "gph3-7";
		samsung,pin-function = <S5PV210_PIN_FUNC_F>;
		samsung,pin-pud = <S5PV210_PIN_PULL_NONE>;
		samsung,pin-drv = <S5PV210_PIN_DRV_LV1>;
	};

	cam_port_a_io: cam-port-a-io-pins {
		samsung,pins = "gpe0-0", "gpe0-1", "gpe0-2", "gpe0-3",
				"gpe0-4", "gpe0-5", "gpe0-6", "gpe0-7",
				"gpe1-0", "gpe1-1", "gpe1-2", "gpe1-4";
		samsung,pin-function = <S5PV210_PIN_FUNC_2>;
		samsung,pin-pud = <S5PV210_PIN_PULL_NONE>;
		samsung,pin-drv = <S5PV210_PIN_DRV_LV1>;
	};

	cam_port_a_clk_active: cam-port-a-clk-active-pins {
		samsung,pins = "gpe1-3";
		samsung,pin-function = <S5PV210_PIN_FUNC_2>;
		samsung,pin-pud = <S5PV210_PIN_PULL_NONE>;
		samsung,pin-drv = <S5PV210_PIN_DRV_LV4>;
	};

	cam_port_a_clk_idle: cam-port-a-clk-idle-pins {
		samsung,pins = "gpe1-3";
		samsung,pin-function = <S5PV210_PIN_FUNC_INPUT>;
		samsung,pin-pud = <S5PV210_PIN_PULL_DOWN>;
		samsung,pin-drv = <S5PV210_PIN_DRV_LV1>;
	};

	cam_port_b_io: cam-port-b-io-pins {
		samsung,pins = "gpj0-0", "gpj0-1", "gpj0-2", "gpj0-3",
				"gpj0-4", "gpj0-5", "gpj0-6", "gpj0-7",
				"gpj1-0", "gpj1-1", "gpj1-2", "gpj1-4";
		samsung,pin-function = <S5PV210_PIN_FUNC_3>;
		samsung,pin-pud = <S5PV210_PIN_PULL_NONE>;
		samsung,pin-drv = <S5PV210_PIN_DRV_LV1>;
	};

	cam_port_b_clk_active: cam-port-b-clk-active-pins {
		samsung,pins = "gpj1-3";
		samsung,pin-function = <S5PV210_PIN_FUNC_3>;
		samsung,pin-pud = <S5PV210_PIN_PULL_NONE>;
		samsung,pin-drv = <S5PV210_PIN_DRV_LV4>;
	};

	cam_port_b_clk_idle: cam-port-b-clk-idle-pins {
		samsung,pins = "gpj1-3";
		samsung,pin-function = <S5PV210_PIN_FUNC_INPUT>;
		samsung,pin-pud = <S5PV210_PIN_PULL_DOWN>;
		samsung,pin-drv = <S5PV210_PIN_DRV_LV1>;
	};

	lcd_ctrl: lcd-ctrl-pins {
		samsung,pins = "gpd0-0", "gpd0-1";
		samsung,pin-function = <S5PV210_PIN_FUNC_3>;
		samsung,pin-pud = <S5PV210_PIN_PULL_NONE>;
		samsung,pin-drv = <S5PV210_PIN_DRV_LV1>;
	};

	lcd_sync: lcd-sync-pins {
		samsung,pins = "gpf0-0", "gpf0-1";
		samsung,pin-function = <S5PV210_PIN_FUNC_2>;
		samsung,pin-pud = <S5PV210_PIN_PULL_NONE>;
		samsung,pin-drv = <S5PV210_PIN_DRV_LV1>;
	};

	lcd_clk: lcd-clk-pins {
		samsung,pins = "gpf0-0", "gpf0-1", "gpf0-2", "gpf0-3";
		samsung,pin-function = <S5PV210_PIN_FUNC_2>;
		samsung,pin-pud = <S5PV210_PIN_PULL_NONE>;
		samsung,pin-drv = <S5PV210_PIN_DRV_LV1>;
	};

	lcd_data24: lcd-data-width24-pins {
		samsung,pins =  "gpf0-4", "gpf0-5", "gpf0-6", "gpf0-7",
				"gpf1-0", "gpf1-1", "gpf1-2", "gpf1-3",
				"gpf1-4", "gpf1-5", "gpf1-6", "gpf1-7",
				"gpf2-0", "gpf2-1", "gpf2-2", "gpf2-3",
				"gpf2-4", "gpf2-5", "gpf2-6", "gpf2-7",
				"gpf3-0", "gpf3-1", "gpf3-2", "gpf3-3";
		samsung,pin-function = <S5PV210_PIN_FUNC_2>;
		samsung,pin-pud = <S5PV210_PIN_PULL_NONE>;
		samsung,pin-drv = <S5PV210_PIN_DRV_LV1>;
	};
};


code:
/* SPDX-License-Identifier: GPL-2.0 */
/*
 * Samsung S5PV210 DTS pinctrl constants
 *
 * Copyright (c) 2016 Samsung Electronics Co., Ltd.
 *		http://www.samsung.com
 * Copyright (c) 2022 Linaro Ltd
 * Author: Krzysztof Kozlowski <krzk@kernel.org>
 */

#ifndef __DTS_ARM_SAMSUNG_S5PV210_PINCTRL_H__
#define __DTS_ARM_SAMSUNG_S5PV210_PINCTRL_H__

#define S5PV210_PIN_PULL_NONE		0
#define S5PV210_PIN_PULL_DOWN		1
#define S5PV210_PIN_PULL_UP		2

/* Pin function in power down mode */
#define S5PV210_PIN_PDN_OUT0		0
#define S5PV210_PIN_PDN_OUT1		1
#define S5PV210_PIN_PDN_INPUT		2
#define S5PV210_PIN_PDN_PREV		3

#define S5PV210_PIN_DRV_LV1		0
#define S5PV210_PIN_DRV_LV2		2
#define S5PV210_PIN_DRV_LV3		1
#define S5PV210_PIN_DRV_LV4		3

#define S5PV210_PIN_FUNC_INPUT		0
#define S5PV210_PIN_FUNC_OUTPUT		1
#define S5PV210_PIN_FUNC_2		2
#define S5PV210_PIN_FUNC_3		3
#define S5PV210_PIN_FUNC_4		4
#define S5PV210_PIN_FUNC_5		5
#define S5PV210_PIN_FUNC_6		6
#define S5PV210_PIN_FUNC_EINT		0xf
#define S5PV210_PIN_FUNC_F		S5PV210_PIN_FUNC_EINT

#endif /* __DTS_ARM_SAMSUNG_S5PV210_PINCTRL_H__ */


code:
// SPDX-License-Identifier: GPL-2.0
/*
 * Samsung's S5PV210 SoC device tree source
 *
 * Copyright (c) 2013-2014 Samsung Electronics, Co. Ltd.
 *
 * Mateusz Krawczuk <m.krawczuk@partner.samsung.com>
 * Tomasz Figa <t.figa@samsung.com>
 *
 * Board device tree source for YIC System SMDC110 board.
 *
 * NOTE: This file is completely based on original board file for mach-smdkc110
 * available in Linux 3.15 and intends to provide equivalent level of hardware
 * support. Due to lack of hardware, _no_ testing has been performed.
 */

/dts-v1/;
#include <dt-bindings/input/input.h>
#include "s5pv210.dtsi"

/ {
	model = "YIC System SMDKC110 based on S5PC110";
	compatible = "yic,smdkc110", "samsung,s5pv210";

	chosen {
		bootargs = "console=ttySAC0,115200n8 root=/dev/mmcblk0p1 rw rootwait ignore_loglevel earlyprintk";
	};

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

	pmic_ap_clk: clock-0 {
		/* Workaround for missing PMIC and its clock */
		compatible = "fixed-clock";
		#clock-cells = <0>;
		clock-frequency = <32768>;
	};
};

&xusbxti {
	clock-frequency = <24000000>;
};

&uart0 {
	status = "okay";
};

&uart1 {
	status = "okay";
};

&uart2 {
	status = "okay";
};

&uart3 {
	status = "okay";
};

&rtc {
	status = "okay";
	clocks = <&clocks CLK_RTC>, <&pmic_ap_clk>;
	clock-names = "rtc", "rtc_src";
};

&i2c0 {
	status = "okay";

	audio-codec@1b {
		compatible = "wlf,wm8580";
		reg = <0x1b>;
	};

	eeprom@50 {
		compatible = "atmel,24c08";
		reg = <0x50>;
	};
};

&i2s0 {
	status = "okay";
};


code:
// SPDX-License-Identifier: GPL-2.0
/*
 * Samsung's S5PV210 SoC device tree source
 *
 * Copyright (c) 2013-2014 Samsung Electronics, Co. Ltd.
 *
 * Mateusz Krawczuk <m.krawczuk@partner.samsung.com>
 * Tomasz Figa <t.figa@samsung.com>
 *
 * Board device tree source for YIC System SMDV210 board.
 *
 * NOTE: This file is completely based on original board file for mach-smdkv210
 * available in Linux 3.15 and intends to provide equivalent level of hardware
 * support. Due to lack of hardware, _no_ testing has been performed.
 */

/dts-v1/;
#include <dt-bindings/interrupt-controller/irq.h>
#include <dt-bindings/input/input.h>
#include "s5pv210.dtsi"

/ {
	model = "YIC System SMDKV210 based on S5PV210";
	compatible = "yic,smdkv210", "samsung,s5pv210";

	chosen {
		bootargs = "console=ttySAC0,115200n8 root=/dev/mmcblk0p1 rw rootwait ignore_loglevel earlyprintk";
	};

	memory@20000000 {
		device_type = "memory";
		reg = <0x20000000 0x40000000>;
	};

	pmic_ap_clk: clock-0 {
		/* Workaround for missing PMIC and its clock */
		compatible = "fixed-clock";
		#clock-cells = <0>;
		clock-frequency = <32768>;
	};

	ethernet@a8000000 {
		compatible = "davicom,dm9000";
		reg = <0xA8000000 0x2 0xA8000002 0x2>;
		interrupt-parent = <&gph1>;
		interrupts = <1 IRQ_TYPE_LEVEL_HIGH>;
		local-mac-address = [00 00 de ad be ef];
		davicom,no-eeprom;
	};

	backlight {
		compatible = "pwm-backlight";
		pwms = <&pwm 3 5000000 0>;
		brightness-levels = <0 4 8 16 32 64 128 255>;
		default-brightness-level = <6>;
		pinctrl-names = "default";
		pinctrl-0 = <&pwm3_out>;
	};
};

&xusbxti {
	clock-frequency = <24000000>;
};

&keypad {
	linux,input-no-autorepeat;
	wakeup-source;
	samsung,keypad-num-rows = <8>;
	samsung,keypad-num-columns = <8>;
	pinctrl-names = "default";
	pinctrl-0 = <&keypad_row0>, <&keypad_row1>, <&keypad_row2>,
			<&keypad_row3>, <&keypad_row4>, <&keypad_row5>,
			<&keypad_row6>, <&keypad_row7>,
			<&keypad_col0>, <&keypad_col1>, <&keypad_col2>,
			<&keypad_col3>, <&keypad_col4>, <&keypad_col5>,
			<&keypad_col6>, <&keypad_col7>;
	status = "okay";

	key-1 {
		keypad,row = <0>;
		keypad,column = <3>;
		linux,code = <KEY_1>;
	};

	key-2 {
		keypad,row = <0>;
		keypad,column = <4>;
		linux,code = <KEY_2>;
	};

	key-3 {
		keypad,row = <0>;
		keypad,column = <5>;
		linux,code = <KEY_3>;
	};

	key-4 {
		keypad,row = <0>;
		keypad,column = <6>;
		linux,code = <KEY_4>;
	};

	key-5 {
		keypad,row = <0
		>;
		keypad,column = <7>;
		linux,code = <KEY_5>;
	};

	key-6 {
		keypad,row = <1>;
		keypad,column = <3>;
		linux,code = <KEY_A>;
	};
	key-7 {
		keypad,row = <1>;
		keypad,column = <4>;
		linux,code = <KEY_B>;
	};

	key-8 {
		keypad,row = <1>;
		keypad,column = <5>;
		linux,code = <KEY_C>;
	};

	key-9 {
		keypad,row = <1>;
		keypad,column = <6>;
		linux,code = <KEY_D>;
	};

	key-10 {
		keypad,row = <1>;
		keypad,column = <7>;
		linux,code = <KEY_E>;
	};
};

&uart0 {
	status = "okay";
};

&uart1 {
	status = "okay";
};

&uart2 {
	status = "okay";
};

&uart3 {
	status = "okay";
};

&rtc {
	status = "okay";
	clocks = <&clocks CLK_RTC>, <&pmic_ap_clk>;
	clock-names = "rtc", "rtc_src";
};

&sdhci0 {
	bus-width = <4>;
	pinctrl-0 = <&sd0_clk &sd0_cmd &sd0_cd &sd0_bus1 &sd0_bus4>;
	pinctrl-names = "default";
	status = "okay";
};

&sdhci1 {
	bus-width = <4>;
	pinctrl-0 = <&sd1_clk &sd1_cmd &sd1_cd &sd1_bus1 &sd1_bus4>;
	pinctrl-names = "default";
	status = "okay";
};

&sdhci2 {
	bus-width = <4>;
	pinctrl-0 = <&sd2_clk &sd2_cmd &sd2_cd &sd2_bus1 &sd2_bus4>;
	pinctrl-names = "default";
	status = "okay";
};

&sdhci3 {
	bus-width = <4>;
	pinctrl-0 = <&sd3_clk &sd3_cmd &sd3_cd &sd3_bus1 &sd3_bus4>;
	pinctrl-names = "default";
	status = "okay";
};

&hsotg {
	dr_mode = "peripheral";
	status = "okay";
};

&usbphy {
	status = "okay";
};

&fimd {
	pinctrl-0 = <&lcd_clk &lcd_data24>;
	pinctrl-names = "default";
	status = "okay";

	display-timings {
		native-mode = <&timing0>;

		timing0: timing {
			/* 800x480@60Hz */
			clock-frequency = <24373920>;
			hactive = <800>;
			vactive = <480>;
			hfront-porch = <8>;
			hback-porch = <13>;
			hsync-len = <3>;
			vback-porch = <7>;
			vfront-porch = <5>;
			vsync-len = <1>;
			hsync-active = <0>;
			vsync-active = <0>;
			de-active = <1>;
			pixelclk-active = <1>;
		};
	};
};

&pwm {
	samsung,pwm-outputs = <3>;
};

&i2c0 {
	status = "okay";

	audio-codec@1b {
		compatible = "wlf,wm8580";
		reg = <0x1b>;
	};

	eeprom@50 {
		compatible = "atmel,24c08";
		reg = <0x50>;
	};
};

&i2s0 {
	status = "okay";
};


code:
// SPDX-License-Identifier: GPL-2.0
/*
 * Samsung's S5PV210 SoC device tree source
 *
 * Copyright (c) 2013-2014 Samsung Electronics, Co. Ltd.
 *
 * Mateusz Krawczuk <m.krawczuk@partner.samsung.com>
 * Tomasz Figa <t.figa@samsung.com>
 *
 * Board device tree source for Torbreck board.
 *
 * NOTE: This file is completely based on original board file for mach-torbreck
 * available in Linux 3.15 and intends to provide equivalent level of hardware
 * support. Due to lack of hardware, _no_ testing has been performed.
 */

/dts-v1/;
#include <dt-bindings/input/input.h>
#include "s5pv210.dtsi"

/ {
	model = "aESOP Torbreck based on S5PV210";
	compatible = "aesop,torbreck", "samsung,s5pv210";

	chosen {
		bootargs = "console=ttySAC0,115200n8 root=/dev/mmcblk0p1 rw rootwait ignore_loglevel earlyprintk";
	};

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

	pmic_ap_clk: clock-0 {
		/* Workaround for missing PMIC and its clock */
		compatible = "fixed-clock";
		#clock-cells = <0>;
		clock-frequency = <32768>;
	};
};

&xusbxti {
	clock-frequency = <24000000>;
};

&uart0 {
	status = "okay";
};

&uart1 {
	status = "okay";
};

&uart2 {
	status = "okay";
};

&uart3 {
	status = "okay";
};

&rtc {
	status = "okay";
	clocks = <&clocks CLK_RTC>, <&pmic_ap_clk>;
	clock-names = "rtc", "rtc_src";
};

&sdhci0 {
	bus-width = <4>;
	pinctrl-0 = <&sd0_clk &sd0_cmd &sd0_cd &sd0_bus1 &sd0_bus4>;
	pinctrl-names = "default";
	status = "okay";
};

&sdhci1 {
	bus-width = <4>;
	pinctrl-0 = <&sd1_clk &sd1_cmd &sd1_cd &sd1_bus1 &sd1_bus4>;
	pinctrl-names = "default";
	status = "okay";
};

&sdhci2 {
	bus-width = <4>;
	pinctrl-0 = <&sd2_clk &sd2_cmd &sd2_bus1 &sd2_bus4>;
	pinctrl-names = "default";
	status = "okay";
};

&sdhci3 {
	bus-width = <4>;
	pinctrl-0 = <&sd3_clk &sd3_cmd &sd3_cd &sd3_bus1 &sd3_bus4>;
	pinctrl-names = "default";
	status = "okay";
};

&i2s0 {
	status = "okay";
};


code:
// SPDX-License-Identifier: GPL-2.0
/*
 * Samsung's S5PV210 SoC device tree source
 *
 * Copyright (c) 2013-2014 Samsung Electronics, Co. Ltd.
 *
 * Mateusz Krawczuk <m.krawczuk@partner.samsung.com>
 * Tomasz Figa <t.figa@samsung.com>
 *
 * Samsung's S5PV210 SoC device nodes are listed in this file. S5PV210
 * based board files can include this file and provide values for board specfic
 * bindings.
 *
 * Note: This file does not include device nodes for all the controllers in
 * S5PV210 SoC. As device tree coverage for S5PV210 increases, additional
 * nodes can be added to this file.
 */

#include <dt-bindings/clock/s5pv210.h>
#include <dt-bindings/clock/s5pv210-audss.h>

/ {
	#address-cells = <1>;
	#size-cells = <1>;

	aliases {
		csis0 = &csis0;
		dmc0 = &dmc0;
		dmc1 = &dmc1;
		fimc0 = &fimc0;
		fimc1 = &fimc1;
		fimc2 = &fimc2;
		i2c0 = &i2c0;
		i2c1 = &i2c1;
		i2c2 = &i2c2;
		i2s0 = &i2s0;
		i2s1 = &i2s1;
		i2s2 = &i2s2;
		pinctrl0 = &pinctrl0;
		spi0 = &spi0;
		spi1 = &spi1;
	};

	cpus {
		#address-cells = <1>;
		#size-cells = <0>;

		cpu@0 {
			device_type = "cpu";
			compatible = "arm,cortex-a8";
			reg = <0>;
		};
	};

	xxti: oscillator-0 {
		compatible = "fixed-clock";
		clock-frequency = <0>;
		clock-output-names = "xxti";
		#clock-cells = <0>;
	};

	xusbxti: oscillator-1 {
		compatible = "fixed-clock";
		clock-frequency = <0>;
		clock-output-names = "xusbxti";
		#clock-cells = <0>;
	};

	soc {
		compatible = "simple-bus";
		#address-cells = <1>;
		#size-cells = <1>;
		ranges;

		onenand: onenand@b0600000 {
			compatible = "samsung,s5pv210-onenand";
			reg = <0xb0600000 0x2000>,
				<0xb0000000 0x20000>,
				<0xb0040000 0x20000>;
			interrupt-parent = <&vic1>;
			interrupts = <31>;
			clocks = <&clocks CLK_NANDXL>, <&clocks DOUT_FLASH>;
			clock-names = "bus", "onenand";
			#address-cells = <1>;
			#size-cells = <1>;
			status = "disabled";
		};

		chipid@e0000000 {
			compatible = "samsung,s5pv210-chipid";
			reg = <0xe0000000 0x1000>;
		};

		clocks: clock-controller@e0100000 {
			compatible = "samsung,s5pv210-clock";
			reg = <0xe0100000 0x10000>;
			clock-names = "xxti", "xusbxti";
			clocks = <&xxti>, <&xusbxti>;
			#clock-cells = <1>;
		};

		pmu_syscon: syscon@e0108000 {
			compatible = "samsung-s5pv210-pmu", "syscon";
			reg = <0xe0108000 0x8000>;
		};

		pinctrl0: pinctrl@e0200000 {
			compatible = "samsung,s5pv210-pinctrl";
			reg = <0xe0200000 0x1000>;
			interrupt-parent = <&vic0>;
			interrupts = <30>;

			wakeup-interrupt-controller {
				compatible = "samsung,s5pv210-wakeup-eint";
				interrupts = <16>;
				interrupt-parent = <&vic0>;
			};
		};

		pdma0: dma-controller@e0900000 {
			compatible = "arm,pl330", "arm,primecell";
			reg = <0xe0900000 0x1000>;
			interrupt-parent = <&vic0>;
			interrupts = <19>;
			clocks = <&clocks CLK_PDMA0>;
			clock-names = "apb_pclk";
			#dma-cells = <1>;
		};

		pdma1: dma-controller@e0a00000 {
			compatible = "arm,pl330", "arm,primecell";
			reg = <0xe0a00000 0x1000>;
			interrupt-parent = <&vic0>;
			interrupts = <20>;
			clocks = <&clocks CLK_PDMA1>;
			clock-names = "apb_pclk";
			#dma-cells = <1>;
		};

		adc: adc@e1700000 {
			compatible = "samsung,s5pv210-adc";
			reg = <0xe1700000 0x1000>;
			interrupt-parent = <&vic2>;
			interrupts = <23>, <24>;
			clocks = <&clocks CLK_TSADC>;
			clock-names = "adc";
			#io-channel-cells = <1>;
			status = "disabled";
		};

		spi0: spi@e1300000 {
			compatible = "samsung,s5pv210-spi";
			reg = <0xe1300000 0x1000>;
			interrupt-parent = <&vic1>;
			interrupts = <15>;
			dmas = <&pdma0 7>, <&pdma0 6>;
			dma-names = "tx", "rx";
			clocks = <&clocks SCLK_SPI0>, <&clocks CLK_SPI0>;
			clock-names = "spi", "spi_busclk0";
			pinctrl-names = "default";
			pinctrl-0 = <&spi0_bus>;
			#address-cells = <1>;
			#size-cells = <0>;
			status = "disabled";
		};

		spi1: spi@e1400000 {
			compatible = "samsung,s5pv210-spi";
			reg = <0xe1400000 0x1000>;
			interrupt-parent = <&vic1>;
			interrupts = <16>;
			dmas = <&pdma1 7>, <&pdma1 6>;
			dma-names = "tx", "rx";
			clocks = <&clocks SCLK_SPI1>, <&clocks CLK_SPI1>;
			clock-names = "spi", "spi_busclk0";
			pinctrl-names = "default";
			pinctrl-0 = <&spi1_bus>;
			#address-cells = <1>;
			#size-cells = <0>;
			status = "disabled";
		};

		keypad: keypad@e1600000 {
			compatible = "samsung,s5pv210-keypad";
			reg = <0xe1600000 0x1000>;
			interrupt-parent = <&vic2>;
			interrupts = <25>;
			clocks = <&clocks CLK_KEYIF>;
			clock-names = "keypad";
			status = "disabled";
		};

		i2c0: i2c@e1800000 {
			compatible = "samsung,s3c2440-i2c";
			reg = <0xe1800000 0x1000>;
			interrupt-parent = <&vic1>;
			interrupts = <14>;
			clocks = <&clocks CLK_I2C0>;
			clock-names = "i2c";
			pinctrl-names = "default";
			pinctrl-0 = <&i2c0_bus>;
			#address-cells = <1>;
			#size-cells = <0>;
			status = "disabled";
		};

		i2c2: i2c@e1a00000 {
			compatible = "samsung,s3c2440-i2c";
			reg = <0xe1a00000 0x1000>;
			interrupt-parent = <&vic1>;
			interrupts = <19>;
			clocks = <&clocks CLK_I2C2>;
			clock-names = "i2c";
			pinctrl-0 = <&i2c2_bus>;
			pinctrl-names = "default";
			#address-cells = <1>;
			#size-cells = <0>;
			status = "disabled";
		};

		clk_audss: clock-controller@eee10000 {
			compatible = "samsung,s5pv210-audss-clock";
			reg = <0xeee10000 0x1000>;
			clock-names = "hclk", "xxti",
				      "fout_epll",
				      "sclk_audio0";
			clocks = <&clocks DOUT_HCLKP>, <&xxti>,
				 <&clocks FOUT_EPLL>,
				 <&clocks SCLK_AUDIO0>;
			#clock-cells = <1>;
		};

		i2s0: i2s@eee30000 {
			compatible = "samsung,s5pv210-i2s";
			reg = <0xeee30000 0x1000>;
			interrupt-parent = <&vic2>;
			interrupts = <16>;
			dma-names = "tx", "rx", "tx-sec";
			dmas = <&pdma1 10>, <&pdma1 9>, <&pdma1 11>;
			clock-names = "iis",
				      "i2s_opclk0",
				      "i2s_opclk1";
			clocks = <&clk_audss CLK_I2S>,
				 <&clk_audss CLK_I2S>,
				 <&clk_audss CLK_DOUT_AUD_BUS>;
			samsung,idma-addr = <0xc0010000>;
			pinctrl-names = "default";
			pinctrl-0 = <&i2s0_bus>;
			#sound-dai-cells = <0>;
			status = "disabled";
		};

		i2s1: i2s@e2100000 {
			compatible = "samsung,s3c6410-i2s";
			reg = <0xe2100000 0x1000>;
			interrupt-parent = <&vic2>;
			interrupts = <17>;
			dma-names = "tx", "rx";
			dmas = <&pdma1 13>, <&pdma1 12>;
			clock-names = "iis", "i2s_opclk0";
			clocks = <&clocks CLK_I2S1>, <&clocks SCLK_AUDIO1>;
			pinctrl-names = "default";
			pinctrl-0 = <&i2s1_bus>;
			#sound-dai-cells = <0>;
			status = "disabled";
		};

		i2s2: i2s@e2a00000 {
			compatible = "samsung,s3c6410-i2s";
			reg = <0xe2a00000 0x1000>;
			interrupt-parent = <&vic2>;
			interrupts = <18>;
			dma-names = "tx", "rx";
			dmas = <&pdma1 15>, <&pdma1 14>;
			clock-names = "iis", "i2s_opclk0";
			clocks = <&clocks CLK_I2S2>, <&clocks SCLK_AUDIO2>;
			pinctrl-names = "default";
			pinctrl-0 = <&i2s2_bus>;
			#sound-dai-cells = <0>;
			status = "disabled";
		};

		pwm: pwm@e2500000 {
			compatible = "samsung,s5pc100-pwm";
			reg = <0xe2500000 0x1000>;
			interrupt-parent = <&vic0>;
			interrupts = <21>, <22>, <23>, <24>, <25>;
			clock-names = "timers";
			clocks = <&clocks CLK_PWM>;
			#pwm-cells = <3>;
		};

		watchdog: watchdog@e2700000 {
			compatible = "samsung,s3c6410-wdt";
			reg = <0xe2700000 0x1000>;
			interrupt-parent = <&vic0>;
			interrupts = <26>;
			clock-names = "watchdog";
			clocks = <&clocks CLK_WDT>;
		};

		rtc: rtc@e2800000 {
			compatible = "samsung,s3c6410-rtc";
			reg = <0xe2800000 0x100>;
			interrupt-parent = <&vic0>;
			interrupts = <28>, <29>;
			clocks = <&clocks CLK_RTC>;
			clock-names = "rtc";
			status = "disabled";
		};

		uart0: serial@e2900000 {
			compatible = "samsung,s5pv210-uart";
			reg = <0xe2900000 0x400>;
			interrupt-parent = <&vic1>;
			interrupts = <10>;
			clock-names = "uart", "clk_uart_baud0",
					"clk_uart_baud1";
			clocks = <&clocks CLK_UART0>, <&clocks CLK_UART0>,
					<&clocks SCLK_UART0>;
			status = "disabled";
		};

		uart1: serial@e2900400 {
			compatible = "samsung,s5pv210-uart";
			reg = <0xe2900400 0x400>;
			interrupt-parent = <&vic1>;
			interrupts = <11>;
			clock-names = "uart", "clk_uart_baud0",
					"clk_uart_baud1";
			clocks = <&clocks CLK_UART1>, <&clocks CLK_UART1>,
					<&clocks SCLK_UART1>;
			status = "disabled";
		};

		uart2: serial@e2900800 {
			compatible = "samsung,s5pv210-uart";
			reg = <0xe2900800 0x400>;
			interrupt-parent = <&vic1>;
			interrupts = <12>;
			clock-names = "uart", "clk_uart_baud0",
					"clk_uart_baud1";
			clocks = <&clocks CLK_UART2>, <&clocks CLK_UART2>,
					<&clocks SCLK_UART2>;
			status = "disabled";
		};

		uart3: serial@e2900c00 {
			compatible = "samsung,s5pv210-uart";
			reg = <0xe2900c00 0x400>;
			interrupt-parent = <&vic1>;
			interrupts = <13>;
			clock-names = "uart", "clk_uart_baud0",
					"clk_uart_baud1";
			clocks = <&clocks CLK_UART3>, <&clocks CLK_UART3>,
					<&clocks SCLK_UART3>;
			status = "disabled";
		};

		sdhci0: mmc@eb000000 {
			compatible = "samsung,s3c6410-sdhci";
			reg = <0xeb000000 0x100000>;
			interrupt-parent = <&vic1>;
			interrupts = <26>;
			clock-names = "hsmmc", "mmc_busclk.0", "mmc_busclk.2";
			clocks = <&clocks CLK_HSMMC0>, <&clocks CLK_HSMMC0>,
					<&clocks SCLK_MMC0>;
			status = "disabled";
		};

		sdhci1: mmc@eb100000 {
			compatible = "samsung,s3c6410-sdhci";
			reg = <0xeb100000 0x100000>;
			interrupt-parent = <&vic1>;
			interrupts = <27>;
			clock-names = "hsmmc", "mmc_busclk.0", "mmc_busclk.2";
			clocks = <&clocks CLK_HSMMC1>, <&clocks CLK_HSMMC1>,
					<&clocks SCLK_MMC1>;
			status = "disabled";
		};

		sdhci2: mmc@eb200000 {
			compatible = "samsung,s3c6410-sdhci";
			reg = <0xeb200000 0x100000>;
			interrupt-parent = <&vic1>;
			interrupts = <28>;
			clock-names = "hsmmc", "mmc_busclk.0", "mmc_busclk.2";
			clocks = <&clocks CLK_HSMMC2>, <&clocks CLK_HSMMC2>,
					<&clocks SCLK_MMC2>;
			status = "disabled";
		};

		sdhci3: mmc@eb300000 {
			compatible = "samsung,s3c6410-sdhci";
			reg = <0xeb300000 0x100000>;
			interrupt-parent = <&vic3>;
			interrupts = <2>;
			clock-names = "hsmmc", "mmc_busclk.0", "mmc_busclk.3";
			clocks = <&clocks CLK_HSMMC3>, <&clocks CLK_HSMMC3>,
					<&clocks SCLK_MMC3>;
			status = "disabled";
		};

		hsotg: hsotg@ec000000 {
			compatible = "samsung,s3c6400-hsotg";
			reg = <0xec000000 0x20000>;
			interrupt-parent = <&vic1>;
			interrupts = <24>;
			clocks = <&clocks CLK_USB_OTG>;
			clock-names = "otg";
			phy-names = "usb2-phy";
			phys = <&usbphy 0>;
			status = "disabled";
		};

		usbphy: usbphy@ec100000 {
			compatible = "samsung,s5pv210-usb2-phy";
			reg = <0xec100000 0x100>;
			samsung,pmureg-phandle = <&pmu_syscon>;
			clocks = <&clocks CLK_USB_OTG>, <&xusbxti>;
			clock-names = "phy", "ref";
			#phy-cells = <1>;
			status = "disabled";
		};

		ehci: usb@ec200000 {
			compatible = "samsung,exynos4210-ehci";
			reg = <0xec200000 0x100>;
			interrupts = <23>;
			interrupt-parent = <&vic1>;
			clocks = <&clocks CLK_USB_HOST>;
			clock-names = "usbhost";
			phys = <&usbphy 1>;
			phy-names = "host";
			status = "disabled";
		};

		ohci: usb@ec300000 {
			compatible = "samsung,exynos4210-ohci";
			reg = <0xec300000 0x100>;
			interrupts = <23>;
			interrupt-parent = <&vic1>;
			clocks = <&clocks CLK_USB_HOST>;
			clock-names = "usbhost";
			phys = <&usbphy 1>;
			phy-names = "host";
			status = "disabled";
		};

		mfc: codec@f1700000 {
			compatible = "samsung,mfc-v5";
			reg = <0xf1700000 0x10000>;
			interrupt-parent = <&vic2>;
			interrupts = <14>;
			clocks = <&clocks DOUT_MFC>, <&clocks CLK_MFC>;
			clock-names = "sclk_mfc", "mfc";
		};

		vic0: interrupt-controller@f2000000 {
			compatible = "arm,pl192-vic";
			interrupt-controller;
			reg = <0xf2000000 0x1000>;
			#interrupt-cells = <1>;
		};

		vic1: interrupt-controller@f2100000 {
			compatible = "arm,pl192-vic";
			interrupt-controller;
			reg = <0xf2100000 0x1000>;
			#interrupt-cells = <1>;
		};

		vic2: interrupt-controller@f2200000 {
			compatible = "arm,pl192-vic";
			interrupt-controller;
			reg = <0xf2200000 0x1000>;
			#interrupt-cells = <1>;
		};

		vic3: interrupt-controller@f2300000 {
			compatible = "arm,pl192-vic";
			interrupt-controller;
			reg = <0xf2300000 0x1000>;
			#interrupt-cells = <1>;
		};

		fimd: fimd@f8000000 {
			compatible = "samsung,s5pv210-fimd";
			interrupt-parent = <&vic2>;
			reg = <0xf8000000 0x20000>;
			interrupt-names = "fifo", "vsync", "lcd_sys";
			interrupts = <0>, <1>, <2>;
			clocks = <&clocks SCLK_FIMD>, <&clocks CLK_FIMD>;
			clock-names = "sclk_fimd", "fimd";
			status = "disabled";
		};

		dmc0: dmc@f0000000 {
			compatible = "samsung,s5pv210-dmc";
			reg = <0xf0000000 0x1000>;
		};

		dmc1: dmc@f1400000 {
			compatible = "samsung,s5pv210-dmc";
			reg = <0xf1400000 0x1000>;
		};

		g2d: g2d@fa000000 {
			compatible = "samsung,s5pv210-g2d";
			reg = <0xfa000000 0x1000>;
			interrupt-parent = <&vic2>;
			interrupts = <9>;
			clocks = <&clocks DOUT_G2D>, <&clocks CLK_G2D>;
			clock-names = "sclk_fimg2d", "fimg2d";
		};

		mdma1: dma-controller@fa200000 {
			compatible = "arm,pl330", "arm,primecell";
			reg = <0xfa200000 0x1000>;
			interrupt-parent = <&vic0>;
			interrupts = <18>;
			clocks = <&clocks CLK_MDMA>;
			clock-names = "apb_pclk";
			#dma-cells = <1>;
		};

		rotator: rotator@fa300000 {
			compatible = "samsung,s5pv210-rotator";
			reg = <0xfa300000 0x1000>;
			interrupt-parent = <&vic2>;
			interrupts = <4>;
			clocks = <&clocks CLK_ROTATOR>;
			clock-names = "rotator";
		};

		i2c1: i2c@fab00000 {
			compatible = "samsung,s3c2440-i2c";
			reg = <0xfab00000 0x1000>;
			interrupt-parent = <&vic2>;
			interrupts = <13>;
			clocks = <&clocks CLK_I2C1>;
			clock-names = "i2c";
			pinctrl-names = "default";
			pinctrl-0 = <&i2c1_bus>;
			#address-cells = <1>;
			#size-cells = <0>;
			status = "disabled";
		};

		camera: camera {
			compatible = "samsung,fimc", "simple-bus";
			pinctrl-names = "default";
			pinctrl-0 = <>;
			clocks = <&clocks SCLK_CAM0>, <&clocks SCLK_CAM1>;
			clock-names = "sclk_cam0", "sclk_cam1";
			#address-cells = <1>;
			#size-cells = <1>;
			#clock-cells = <1>;
			clock-output-names = "cam_a_clkout", "cam_b_clkout";
			ranges;

			csis0: csis@fa600000 {
				compatible = "samsung,s5pv210-csis";
				reg = <0xfa600000 0x4000>;
				interrupt-parent = <&vic2>;
				interrupts = <29>;
				clocks = <&clocks CLK_CSIS>,
						<&clocks SCLK_CSIS>;
				clock-names = "clk_csis",
						"sclk_csis";
				bus-width = <4>;
				status = "disabled";
				#address-cells = <1>;
				#size-cells = <0>;
			};

			fimc0: fimc@fb200000 {
				compatible = "samsung,s5pv210-fimc";
				reg = <0xfb200000 0x1000>;
				interrupts = <5>;
				interrupt-parent = <&vic2>;
				clocks = <&clocks CLK_FIMC0>,
						<&clocks SCLK_FIMC0>;
				clock-names = "fimc",
						"sclk_fimc";
				samsung,pix-limits = <4224 8192 1920 4224>;
				samsung,min-pix-alignment = <16 8>;
				samsung,cam-if;
			};

			fimc1: fimc@fb300000 {
				compatible = "samsung,s5pv210-fimc";
				reg = <0xfb300000 0x1000>;
				interrupt-parent = <&vic2>;
				interrupts = <6>;
				clocks = <&clocks CLK_FIMC1>,
						<&clocks SCLK_FIMC1>;
				clock-names = "fimc",
						"sclk_fimc";
				samsung,pix-limits = <4224 8192 1920 4224>;
				samsung,min-pix-alignment = <1 1>;
				samsung,mainscaler-ext;
				samsung,cam-if;
				samsung,lcd-wb;
			};

			fimc2: fimc@fb400000 {
				compatible = "samsung,s5pv210-fimc";
				reg = <0xfb400000 0x1000>;
				interrupt-parent = <&vic2>;
				interrupts = <7>;
				clocks = <&clocks CLK_FIMC2>,
						<&clocks SCLK_FIMC2>;
				clock-names = "fimc",
						"sclk_fimc";
				samsung,pix-limits = <1920 8192 1280 1920>;
				samsung,min-pix-alignment = <16 8>;
				samsung,rotators = <0>;
				samsung,cam-if;
			};
		};

		jpeg_codec: jpeg-codec@fb600000 {
			compatible = "samsung,s5pv210-jpeg";
			reg = <0xfb600000 0x1000>;
			interrupt-parent = <&vic2>;
			interrupts = <8>;
			clocks = <&clocks CLK_JPEG>;
			clock-names = "jpeg";
		};
	};
};

#include "s5pv210-pinctrl.dtsi"