1*f126890aSEmmanuel Vadot// SPDX-License-Identifier: GPL-2.0-or-later
2*f126890aSEmmanuel Vadot
3*f126890aSEmmanuel Vadot#include "ep7211.dtsi"
4*f126890aSEmmanuel Vadot#include <dt-bindings/gpio/gpio.h>
5*f126890aSEmmanuel Vadot
6*f126890aSEmmanuel Vadot/ {
7*f126890aSEmmanuel Vadot	model = "Cirrus Logic EP7211 Development Board";
8*f126890aSEmmanuel Vadot	compatible = "cirrus,edb7211", "cirrus,ep7211", "cirrus,ep7209";
9*f126890aSEmmanuel Vadot
10*f126890aSEmmanuel Vadot	memory@c0000000 {
11*f126890aSEmmanuel Vadot		device_type = "memory";
12*f126890aSEmmanuel Vadot		reg = <0xc0000000 0x02000000>;
13*f126890aSEmmanuel Vadot	};
14*f126890aSEmmanuel Vadot
15*f126890aSEmmanuel Vadot	backlight: backlight {
16*f126890aSEmmanuel Vadot		compatible = "pwm-backlight";
17*f126890aSEmmanuel Vadot		pwms = <&pwm 0>;
18*f126890aSEmmanuel Vadot		brightness-levels = <
19*f126890aSEmmanuel Vadot			0x0 0x1 0x2 0x3 0x4 0x5 0x6 0x7
20*f126890aSEmmanuel Vadot			0x8 0x9 0xa 0xb 0xc 0xd 0xe 0xf
21*f126890aSEmmanuel Vadot		>;
22*f126890aSEmmanuel Vadot		default-brightness-level = <0x0>;
23*f126890aSEmmanuel Vadot		power-supply = <&blen>;
24*f126890aSEmmanuel Vadot	};
25*f126890aSEmmanuel Vadot
26*f126890aSEmmanuel Vadot	display: display {
27*f126890aSEmmanuel Vadot		model = "320x240x4";
28*f126890aSEmmanuel Vadot		bits-per-pixel = <4>;
29*f126890aSEmmanuel Vadot		ac-prescale = <17>;
30*f126890aSEmmanuel Vadot
31*f126890aSEmmanuel Vadot		display-timings {
32*f126890aSEmmanuel Vadot			native-mode = <&timing0>;
33*f126890aSEmmanuel Vadot			timing0: 320x240 {
34*f126890aSEmmanuel Vadot				hactive = <320>;
35*f126890aSEmmanuel Vadot				hback-porch = <0>;
36*f126890aSEmmanuel Vadot				hfront-porch = <0>;
37*f126890aSEmmanuel Vadot				hsync-len = <0>;
38*f126890aSEmmanuel Vadot				vactive = <240>;
39*f126890aSEmmanuel Vadot				vback-porch = <0>;
40*f126890aSEmmanuel Vadot				vfront-porch = <0>;
41*f126890aSEmmanuel Vadot				vsync-len = <0>;
42*f126890aSEmmanuel Vadot				clock-frequency = <6500000>;
43*f126890aSEmmanuel Vadot			};
44*f126890aSEmmanuel Vadot		};
45*f126890aSEmmanuel Vadot	};
46*f126890aSEmmanuel Vadot
47*f126890aSEmmanuel Vadot	i2c: i2c {
48*f126890aSEmmanuel Vadot		compatible = "i2c-gpio";
49*f126890aSEmmanuel Vadot		gpios = <&portd 4 GPIO_ACTIVE_HIGH>,
50*f126890aSEmmanuel Vadot			<&portd 5 GPIO_ACTIVE_HIGH>;
51*f126890aSEmmanuel Vadot		i2c-gpio,delay-us = <2>;
52*f126890aSEmmanuel Vadot		i2c-gpio,scl-output-only;
53*f126890aSEmmanuel Vadot		#address-cells = <1>;
54*f126890aSEmmanuel Vadot		#size-cells = <0>;
55*f126890aSEmmanuel Vadot	};
56*f126890aSEmmanuel Vadot
57*f126890aSEmmanuel Vadot	lcddc: lcddc {
58*f126890aSEmmanuel Vadot		compatible = "regulator-fixed";
59*f126890aSEmmanuel Vadot		regulator-name = "BACKLIGHT ENABLE";
60*f126890aSEmmanuel Vadot		regulator-min-microvolt = <3300000>;
61*f126890aSEmmanuel Vadot		regulator-max-microvolt = <3300000>;
62*f126890aSEmmanuel Vadot		gpio = <&portd 1 GPIO_ACTIVE_HIGH>;
63*f126890aSEmmanuel Vadot	};
64*f126890aSEmmanuel Vadot
65*f126890aSEmmanuel Vadot	blen: blen {
66*f126890aSEmmanuel Vadot		compatible = "regulator-fixed";
67*f126890aSEmmanuel Vadot		regulator-name = "BACKLIGHT ENABLE";
68*f126890aSEmmanuel Vadot		regulator-min-microvolt = <3300000>;
69*f126890aSEmmanuel Vadot		regulator-max-microvolt = <3300000>;
70*f126890aSEmmanuel Vadot		gpio = <&portd 3 GPIO_ACTIVE_HIGH>;
71*f126890aSEmmanuel Vadot	};
72*f126890aSEmmanuel Vadot};
73*f126890aSEmmanuel Vadot
74*f126890aSEmmanuel Vadot&bus {
75*f126890aSEmmanuel Vadot	flash: nor@0 {
76*f126890aSEmmanuel Vadot		compatible = "cfi-flash";
77*f126890aSEmmanuel Vadot		reg = <0 0x00000000 0x02000000>;
78*f126890aSEmmanuel Vadot		bank-width = <2>;
79*f126890aSEmmanuel Vadot		#address-cells = <1>;
80*f126890aSEmmanuel Vadot		#size-cells = <1>;
81*f126890aSEmmanuel Vadot	};
82*f126890aSEmmanuel Vadot};
83*f126890aSEmmanuel Vadot
84*f126890aSEmmanuel Vadot&fb {
85*f126890aSEmmanuel Vadot	display = <&display>;
86*f126890aSEmmanuel Vadot	lcd-supply = <&lcddc>;
87*f126890aSEmmanuel Vadot	status = "okay";
88*f126890aSEmmanuel Vadot};
89*f126890aSEmmanuel Vadot
90*f126890aSEmmanuel Vadot&portd {
91*f126890aSEmmanuel Vadot	lcden {
92*f126890aSEmmanuel Vadot		gpio-hog;
93*f126890aSEmmanuel Vadot		gpios = <2 GPIO_ACTIVE_HIGH>;
94*f126890aSEmmanuel Vadot		output-high;
95*f126890aSEmmanuel Vadot		line-name = "LCD ENABLE";
96*f126890aSEmmanuel Vadot	};
97*f126890aSEmmanuel Vadot};
98