xref: /freebsd/sys/contrib/device-tree/src/arm/marvell/armada-388-clearfog-base.dts (revision f126890ac5386406dadf7c4cfa9566cbb56537c5)
1*f126890aSEmmanuel Vadot// SPDX-License-Identifier: (GPL-2.0 OR MIT)
2*f126890aSEmmanuel Vadot/*
3*f126890aSEmmanuel Vadot * Device Tree file for SolidRun Clearfog Base revision A1 rev 2.0 (88F6828)
4*f126890aSEmmanuel Vadot *
5*f126890aSEmmanuel Vadot *  Copyright (C) 2015 Russell King
6*f126890aSEmmanuel Vadot */
7*f126890aSEmmanuel Vadot
8*f126890aSEmmanuel Vadot/dts-v1/;
9*f126890aSEmmanuel Vadot#include "armada-388-clearfog.dtsi"
10*f126890aSEmmanuel Vadot
11*f126890aSEmmanuel Vadot/ {
12*f126890aSEmmanuel Vadot	model = "SolidRun Clearfog Base A1";
13*f126890aSEmmanuel Vadot	compatible = "solidrun,clearfog-base-a1",
14*f126890aSEmmanuel Vadot		"solidrun,clearfog-a1", "marvell,armada388",
15*f126890aSEmmanuel Vadot		"marvell,armada385", "marvell,armada380";
16*f126890aSEmmanuel Vadot
17*f126890aSEmmanuel Vadot	gpio-keys {
18*f126890aSEmmanuel Vadot		compatible = "gpio-keys";
19*f126890aSEmmanuel Vadot		pinctrl-0 = <&rear_button_pins>;
20*f126890aSEmmanuel Vadot		pinctrl-names = "default";
21*f126890aSEmmanuel Vadot
22*f126890aSEmmanuel Vadot		button-0 {
23*f126890aSEmmanuel Vadot			/* The rear SW3 button */
24*f126890aSEmmanuel Vadot			label = "Rear Button";
25*f126890aSEmmanuel Vadot			gpios = <&gpio1 12 GPIO_ACTIVE_LOW>;
26*f126890aSEmmanuel Vadot			linux,can-disable;
27*f126890aSEmmanuel Vadot			linux,code = <BTN_0>;
28*f126890aSEmmanuel Vadot		};
29*f126890aSEmmanuel Vadot	};
30*f126890aSEmmanuel Vadot};
31*f126890aSEmmanuel Vadot
32*f126890aSEmmanuel Vadot&eth1 {
33*f126890aSEmmanuel Vadot	phy = <&phy1>;
34*f126890aSEmmanuel Vadot};
35*f126890aSEmmanuel Vadot
36*f126890aSEmmanuel Vadot&gpio0 {
37*f126890aSEmmanuel Vadot	phy1_reset {
38*f126890aSEmmanuel Vadot		gpio-hog;
39*f126890aSEmmanuel Vadot		gpios = <19 GPIO_ACTIVE_LOW>;
40*f126890aSEmmanuel Vadot		output-low;
41*f126890aSEmmanuel Vadot		line-name = "phy1-reset";
42*f126890aSEmmanuel Vadot	};
43*f126890aSEmmanuel Vadot};
44*f126890aSEmmanuel Vadot
45*f126890aSEmmanuel Vadot&mdio {
46*f126890aSEmmanuel Vadot	pinctrl-0 = <&mdio_pins &microsom_phy_clk_pins &clearfog_phy_pins>;
47*f126890aSEmmanuel Vadot	phy1: ethernet-phy@1 {
48*f126890aSEmmanuel Vadot		/*
49*f126890aSEmmanuel Vadot		 * Annoyingly, the marvell phy driver configures the LED
50*f126890aSEmmanuel Vadot		 * register, rather than preserving reset-loaded setting.
51*f126890aSEmmanuel Vadot		 * We undo that rubbish here.
52*f126890aSEmmanuel Vadot		 */
53*f126890aSEmmanuel Vadot		marvell,reg-init = <3 16 0 0x101e>;
54*f126890aSEmmanuel Vadot		reg = <1>;
55*f126890aSEmmanuel Vadot	};
56*f126890aSEmmanuel Vadot};
57*f126890aSEmmanuel Vadot
58*f126890aSEmmanuel Vadot&pinctrl {
59*f126890aSEmmanuel Vadot	/* phy1 reset */
60*f126890aSEmmanuel Vadot	clearfog_phy_pins: clearfog-phy-pins {
61*f126890aSEmmanuel Vadot		marvell,pins = "mpp19";
62*f126890aSEmmanuel Vadot		marvell,function = "gpio";
63*f126890aSEmmanuel Vadot	};
64*f126890aSEmmanuel Vadot	rear_button_pins: rear-button-pins {
65*f126890aSEmmanuel Vadot		marvell,pins = "mpp44";
66*f126890aSEmmanuel Vadot		marvell,function = "gpio";
67*f126890aSEmmanuel Vadot	};
68*f126890aSEmmanuel Vadot};
69