0001 // SPDX-License-Identifier: GPL-2.0-or-later
0002 /*
0003 * at91sam9n12ek.dts - Device Tree file for AT91SAM9N12-EK board
0004 *
0005 * Copyright (C) 2012 Atmel,
0006 * 2012 Hong Xu <hong.xu@atmel.com>
0007 */
0008 /dts-v1/;
0009 #include "at91sam9n12.dtsi"
0010
0011 / {
0012 model = "Atmel AT91SAM9N12-EK";
0013 compatible = "atmel,at91sam9n12ek", "atmel,at91sam9n12", "atmel,at91sam9";
0014
0015 chosen {
0016 bootargs = "root=/dev/mtdblock1 rw rootfstype=jffs2";
0017 stdout-path = "serial0:115200n8";
0018 };
0019
0020 memory@20000000 {
0021 reg = <0x20000000 0x8000000>;
0022 };
0023
0024 clocks {
0025 slow_xtal {
0026 clock-frequency = <32768>;
0027 };
0028
0029 main_xtal {
0030 clock-frequency = <16000000>;
0031 };
0032 };
0033
0034 ahb {
0035 apb {
0036 dbgu: serial@fffff200 {
0037 status = "okay";
0038 };
0039
0040 ssc0: ssc@f0010000 {
0041 status = "okay";
0042 };
0043
0044 tcb0: timer@f8008000 {
0045 timer@0 {
0046 compatible = "atmel,tcb-timer";
0047 reg = <0>;
0048 };
0049
0050 timer@1 {
0051 compatible = "atmel,tcb-timer";
0052 reg = <1>;
0053 };
0054 };
0055
0056 i2c0: i2c@f8010000 {
0057 status = "okay";
0058
0059 wm8904: codec@1a {
0060 compatible = "wlf,wm8904";
0061 reg = <0x1a>;
0062 clocks = <&pmc PMC_TYPE_SYSTEM 8>;
0063 clock-names = "mclk";
0064 };
0065
0066 qt1070: keyboard@1b {
0067 compatible = "qt1070";
0068 reg = <0x1b>;
0069 interrupt-parent = <&pioA>;
0070 interrupts = <2 IRQ_TYPE_EDGE_FALLING>;
0071 pinctrl-names = "default";
0072 pinctrl-0 = <&pinctrl_qt1070_irq>;
0073 };
0074 };
0075
0076 mmc0: mmc@f0008000 {
0077 pinctrl-0 = <
0078 &pinctrl_board_mmc0
0079 &pinctrl_mmc0_slot0_clk_cmd_dat0
0080 &pinctrl_mmc0_slot0_dat1_3>;
0081 status = "okay";
0082 slot@0 {
0083 reg = <0>;
0084 bus-width = <4>;
0085 cd-gpios = <&pioA 7 GPIO_ACTIVE_HIGH>;
0086 };
0087 };
0088
0089 pinctrl@fffff400 {
0090 mmc0 {
0091 pinctrl_board_mmc0: mmc0-board {
0092 atmel,pins =
0093 <AT91_PIOA 7 AT91_PERIPH_GPIO AT91_PINCTRL_PULL_UP_DEGLITCH>; /* PA7 gpio CD pin pull up and deglitch */
0094 };
0095 };
0096
0097 qt1070 {
0098 pinctrl_qt1070_irq: qt1070_irq {
0099 atmel,pins =
0100 <AT91_PIOA 2 AT91_PERIPH_GPIO AT91_PINCTRL_PULL_UP_DEGLITCH>;
0101 };
0102 };
0103
0104 sound {
0105 pinctrl_pck0_as_audio_mck: pck0_as_audio_mck {
0106 atmel,pins =
0107 <AT91_PIOB 10 AT91_PERIPH_B AT91_PINCTRL_NONE>;
0108 };
0109 };
0110
0111 usb1 {
0112 pinctrl_usb1_vbus_sense: usb1_vbus_sense {
0113 atmel,pins =
0114 <AT91_PIOB 16 AT91_PERIPH_GPIO AT91_PINCTRL_DEGLITCH>; /* PB16 gpio usb vbus sense, no pull up and deglitch */
0115 };
0116 };
0117 };
0118
0119 spi0: spi@f0000000 {
0120 status = "okay";
0121 cs-gpios = <&pioA 14 0>, <0>, <0>, <0>;
0122 flash@0 {
0123 compatible = "atmel,at25df321a";
0124 spi-max-frequency = <50000000>;
0125 reg = <0>;
0126 };
0127 };
0128
0129 hlcdc: hlcdc@f8038000 {
0130 status = "okay";
0131
0132 hlcdc-display-controller {
0133 pinctrl-names = "default";
0134 pinctrl-0 = <&pinctrl_lcd_base &pinctrl_lcd_rgb888>;
0135
0136 port@0 {
0137 hlcdc_panel_output: endpoint@0 {
0138 reg = <0>;
0139 remote-endpoint = <&panel_input>;
0140 };
0141 };
0142 };
0143 };
0144
0145 usb1: gadget@f803c000 {
0146 pinctrl-names = "default";
0147 pinctrl-0 = <&pinctrl_usb1_vbus_sense>;
0148 atmel,vbus-gpio = <&pioB 16 GPIO_ACTIVE_HIGH>;
0149 status = "okay";
0150 };
0151
0152 watchdog@fffffe40 {
0153 status = "okay";
0154 };
0155
0156 rtc@fffffeb0 {
0157 status = "okay";
0158 };
0159 };
0160
0161 ebi: ebi@10000000 {
0162 status = "okay";
0163
0164 nand_controller: nand-controller {
0165 status = "okay";
0166 pinctrl-0 = <&pinctrl_nand_cs &pinctrl_nand_rb>;
0167 pinctrl-names = "default";
0168
0169 nand@3 {
0170 reg = <0x3 0x0 0x800000>;
0171 rb-gpios = <&pioD 5 GPIO_ACTIVE_HIGH>;
0172 cs-gpios = <&pioD 4 GPIO_ACTIVE_HIGH>;
0173 nand-bus-width = <8>;
0174 nand-ecc-mode = "soft";
0175 nand-ecc-strength = <2>;
0176 nand-ecc-step-size = <512>;
0177 nand-on-flash-bbt;
0178 label = "atmel_nand";
0179 };
0180 };
0181 };
0182
0183 usb0: ohci@500000 {
0184 num-ports = <1>;
0185 atmel,vbus-gpio = <&pioB 7 GPIO_ACTIVE_LOW>;
0186 status = "okay";
0187 };
0188 };
0189
0190 backlight: backlight {
0191 compatible = "pwm-backlight";
0192 pwms = <&hlcdc_pwm 0 50000 0>;
0193 brightness-levels = <0 4 8 16 32 64 128 255>;
0194 default-brightness-level = <6>;
0195 power-supply = <&bl_reg>;
0196 status = "okay";
0197 };
0198
0199 bl_reg: backlight_regulator {
0200 compatible = "regulator-fixed";
0201 regulator-name = "backlight-power-supply";
0202 regulator-min-microvolt = <5000000>;
0203 regulator-max-microvolt = <5000000>;
0204 status = "okay";
0205 };
0206
0207 leds {
0208 compatible = "gpio-leds";
0209
0210 d8 {
0211 label = "d8";
0212 gpios = <&pioB 4 GPIO_ACTIVE_LOW>;
0213 linux,default-trigger = "mmc0";
0214 };
0215
0216 d9 {
0217 label = "d9";
0218 gpios = <&pioB 5 GPIO_ACTIVE_LOW>;
0219 linux,default-trigger = "nand-disk";
0220 };
0221
0222 d10 {
0223 label = "d10";
0224 gpios = <&pioB 6 GPIO_ACTIVE_HIGH>;
0225 linux,default-trigger = "heartbeat";
0226 };
0227 };
0228
0229 gpio-keys {
0230 compatible = "gpio-keys";
0231
0232 button-enter {
0233 label = "Enter";
0234 gpios = <&pioB 3 GPIO_ACTIVE_LOW>;
0235 linux,code = <28>;
0236 wakeup-source;
0237 };
0238 };
0239
0240 panel: panel {
0241 compatible = "qiaodian,qd43003c0-40";
0242 backlight = <&backlight>;
0243 power-supply = <&panel_reg>;
0244 #address-cells = <1>;
0245 #size-cells = <0>;
0246 status = "okay";
0247
0248 port@0 {
0249 reg = <0>;
0250 #address-cells = <1>;
0251 #size-cells = <0>;
0252
0253 panel_input: endpoint@0 {
0254 reg = <0>;
0255 remote-endpoint = <&hlcdc_panel_output>;
0256 };
0257 };
0258 };
0259
0260 panel_reg: panel_regulator {
0261 compatible = "regulator-fixed";
0262 regulator-name = "panel-power-supply";
0263 regulator-min-microvolt = <3300000>;
0264 regulator-max-microvolt = <3300000>;
0265 status = "okay";
0266 };
0267
0268 sound {
0269 compatible = "atmel,asoc-wm8904";
0270 pinctrl-names = "default";
0271 pinctrl-0 = <&pinctrl_pck0_as_audio_mck>;
0272
0273 atmel,model = "wm8904 @ AT91SAM9N12";
0274 atmel,audio-routing =
0275 "Headphone Jack", "HPOUTL",
0276 "Headphone Jack", "HPOUTR",
0277 "IN2L", "Line In Jack",
0278 "IN2R", "Line In Jack",
0279 "Mic", "MICBIAS",
0280 "IN1L", "Mic";
0281
0282 atmel,ssc-controller = <&ssc0>;
0283 atmel,audio-codec = <&wm8904>;
0284 };
0285 };