// SPDX-License-Identifier: GPL-2.0-or-later
/*
 * (C) Copyright 2024 - Analog Devices, Inc.
 */

/dts-v1/;

#include "sc594-som.dtsi"

/ {
	model = "ADI SC594-SOM-EZLITE";
	compatible = "adi,sc594-som-ezlite", "adi,sc59x";
};

&i2c2 {
	crr_gpio_expander: adp5588@30 {
		compatible = "adi,adp5588";
		reg = <0x30>;
		gpio-controller;
		#gpio-cells = <2>;
		bootph-pre-ram;

		usb-spi0 {
			gpio-hog;
			gpios = <8 GPIO_ACTIVE_LOW>;
			output-low;
			line-name = "usb_spi0_en";
			bootph-pre-ram;
		};

		usb-spi1 {
			gpio-hog;
			gpios = <9 GPIO_ACTIVE_LOW>;
			output-low;
			line-name = "usb_spi1_en";
			bootph-pre-ram;
		};

		usb-qspi-en {
			gpio-hog;
			gpios = <10 GPIO_ACTIVE_LOW>;
			output-low;
			line-name = "usb_qspi_en";
			bootph-pre-ram;
		};

		usb-qspi-reset {
			gpio-hog;
			gpios = <11 GPIO_ACTIVE_LOW>;
			output-high;
			line-name = "usb_qspi_reset";
			bootph-pre-ram;
		};

		eth0-reset {
			gpio-hog;
			gpios = <12 GPIO_ACTIVE_LOW>;
			output-high;
			line-name = "eth0-reset";
			bootph-pre-ram;
		};

		adau1372-pwrdwn {
			gpio-hog;
			gpios = <13 GPIO_ACTIVE_LOW>;
			output-high;
			line-name = "adau1372_pwrdwn";
			bootph-pre-ram;
		};

		led1 {
			gpio-hog;
			gpios = <15 GPIO_ACTIVE_LOW>;
			output-high;
			line-name = "led1-en";
			bootph-pre-ram;
		};

		led2 {
			gpio-hog;
			gpios = <16 GPIO_ACTIVE_LOW>;
			output-high;
			line-name = "led2-en";
			bootph-pre-ram;
		};

		led3 {
			gpio-hog;
			gpios = <17 GPIO_ACTIVE_LOW>;
			output-high;
			line-name = "led3-en";
			bootph-pre-ram;
		};

	};
};
