// SPDX-License-Identifier: GPL-2.0-or-later OR MIT
/*
 * Copyright 2018-2022 Toradex
 */

/dts-v1/;

#include "imx6ull-colibri-nonwifi.dtsi"
#include "imx6ull-colibri-iris-v2.dtsi"

/ {
	model = "Toradex Colibri iMX6ULL 256M/512B on Colibri Iris V2";
	compatible = "toradex,colibri-imx6ull-iris-v2",
		     "toradex,colibri-imx6ull",
		     "fsl,imx6ull";
};

&ad7879_ts {
	status = "okay";
};

&atmel_mxt_ts {
	status = "okay";
};

&backlight {
	status = "okay";
};

&gpio1 {
	/* This turns the LVDS transceiver on */
	lvds-power-on-hog {
		gpio-hog;
		gpios = <14 GPIO_ACTIVE_HIGH>; /* SODIMM 99 */
		line-name = "LVDS_POWER_ON";
		output-high;
	};
};

&gpio2 {
	/*
	 * This switches the LVDS transceiver to the single-channel
	 * output mode.
	 */
	lvds-ch-mode-hog {
		gpio-hog;
		gpios = <0 GPIO_ACTIVE_HIGH>; /* SODIMM 55 */
		line-name = "LVDS_CH_MODE";
		output-high;
	};

	/*
	 * This switches the LVDS transceiver to the 24-bit RGB mode.
	 */
	lvds-rgb-mode-hog {
		gpio-hog;
		gpios = <1 GPIO_ACTIVE_HIGH>; /* SODIMM 63 */
		line-name = "LVDS_RGB_MODE";
		output-low;
	};
};

&gpio5 {
	/*
	 * This switches the LVDS transceiver to VESA color mapping mode.
	 */
	lvds-color-map-hog {
		gpio-hog;
		gpios = <3 GPIO_ACTIVE_HIGH>; /* SODIMM 95 */
		line-name = "LVDS_COLOR_MAP";
		output-low;
	};
};

&i2c1 {
	status = "okay";
};

&i2c2 {
	status = "okay";
};

&lcdif {
	status = "okay";
};

&panel_dpi {
	status = "okay";
};

&pwm4 {
	status = "okay";
};

/* PWM <B> */
&pwm5 {
	/* Pin already used by atmel_mxt_ts touchscreen */
	status = "disabled";
};

/* PWM <C> */
&pwm6 {
	/* Pin already used by atmel_mxt_ts touchscreen */
	status = "disabled";
};