Back to home page

OSCL-LXR

 
 

    


0001 // SPDX-License-Identifier: (GPL-2.0+ OR MIT)
0002 /*
0003  * at91-sama5d27_wlsom1.dtsi - Device Tree file for SAMA5D27 WLSOM1
0004  *
0005  * Copyright (C) 2019 Microchip Technology Inc. and its subsidiaries
0006  *
0007  * Author: Nicolas Ferre <nicolas.ferre@microcihp.com>
0008  * Author: Eugen Hristev <eugen.hristev@microcihp.com>
0009  */
0010 #include "sama5d2.dtsi"
0011 #include "sama5d2-pinfunc.h"
0012 #include <dt-bindings/gpio/gpio.h>
0013 #include <dt-bindings/mfd/atmel-flexcom.h>
0014 #include <dt-bindings/pinctrl/at91.h>
0015 
0016 / {
0017         model = "Microchip SAMA5D27 WLSOM1";
0018         compatible = "microchip,sama5d27-wlsom1", "atmel,sama5d27", "atmel,sama5d2", "atmel,sama5";
0019 
0020         aliases {
0021                 i2c0 = &i2c0;
0022         };
0023 
0024         clocks {
0025                 slow_xtal {
0026                         clock-frequency = <32768>;
0027                 };
0028 
0029                 main_xtal {
0030                         clock-frequency = <24000000>;
0031                 };
0032         };
0033 
0034         wifi_pwrseq: wifi_pwrseq {
0035                 compatible = "mmc-pwrseq-wilc1000";
0036                 reset-gpios = <&pioA PIN_PA27 GPIO_ACTIVE_HIGH>;
0037                 powerdown-gpios = <&pioA PIN_PA29 GPIO_ACTIVE_HIGH>;
0038                 pinctrl-0 = <&pinctrl_wilc_pwrseq>;
0039                 pinctrl-names = "default";
0040         };
0041 };
0042 
0043 &flx1 {
0044         atmel,flexcom-mode = <ATMEL_FLEXCOM_MODE_USART>;
0045 
0046         uart6: serial@200 {
0047                 pinctrl-0 = <&pinctrl_flx1_default>;
0048                 pinctrl-names = "default";
0049         };
0050 };
0051 
0052 &i2c0 {
0053         pinctrl-0 = <&pinctrl_i2c0_default>;
0054         pinctrl-1 = <&pinctrl_i2c0_gpio>;
0055         pinctrl-names = "default", "gpio";
0056         sda-gpios = <&pioA PIN_PD21 GPIO_ACTIVE_HIGH>;
0057         scl-gpios = <&pioA PIN_PD22 (GPIO_ACTIVE_HIGH | GPIO_OPEN_DRAIN)>;
0058         status = "okay";
0059 };
0060 
0061 &i2c1 {
0062         dmas = <0>, <0>;
0063         pinctrl-names = "default", "gpio";
0064         pinctrl-0 = <&pinctrl_i2c1_default>;
0065         pinctrl-1 = <&pinctrl_i2c1_gpio>;
0066         sda-gpios = <&pioA PIN_PD19 GPIO_ACTIVE_HIGH>;
0067         scl-gpios = <&pioA PIN_PD20 (GPIO_ACTIVE_HIGH | GPIO_OPEN_DRAIN)>;
0068         status = "okay";
0069 
0070         mcp16502@5b {
0071                 compatible = "microchip,mcp16502";
0072                 reg = <0x5b>;
0073                 status = "okay";
0074                 lpm-gpios = <&pioBU 0 GPIO_ACTIVE_LOW>;
0075 
0076                 regulators {
0077                         vdd_3v3: VDD_IO {
0078                                 regulator-name = "VDD_IO";
0079                                 regulator-min-microvolt = <3300000>;
0080                                 regulator-max-microvolt = <3300000>;
0081                                 regulator-initial-mode = <2>;
0082                                 regulator-allowed-modes = <2>, <4>;
0083                                 regulator-always-on;
0084 
0085                                 regulator-state-standby {
0086                                         regulator-on-in-suspend;
0087                                         regulator-mode = <4>;
0088                                 };
0089 
0090                                 regulator-state-mem {
0091                                         regulator-off-in-suspend;
0092                                         regulator-mode = <4>;
0093                                 };
0094                         };
0095 
0096                         vddio_ddr: VDD_DDR {
0097                                 regulator-name = "VDD_DDR";
0098                                 regulator-min-microvolt = <1200000>;
0099                                 regulator-max-microvolt = <1200000>;
0100                                 regulator-initial-mode = <2>;
0101                                 regulator-allowed-modes = <2>, <4>;
0102                                 regulator-always-on;
0103 
0104                                 regulator-state-standby {
0105                                         regulator-on-in-suspend;
0106                                         regulator-suspend-microvolt = <1200000>;
0107                                         regulator-changeable-in-suspend;
0108                                         regulator-mode = <4>;
0109                                 };
0110 
0111                                 regulator-state-mem {
0112                                         regulator-on-in-suspend;
0113                                         regulator-suspend-microvolt = <1200000>;
0114                                         regulator-changeable-in-suspend;
0115                                         regulator-mode = <4>;
0116                                 };
0117                         };
0118 
0119                         vdd_core: VDD_CORE {
0120                                 regulator-name = "VDD_CORE";
0121                                 regulator-min-microvolt = <1250000>;
0122                                 regulator-max-microvolt = <1250000>;
0123                                 regulator-initial-mode = <2>;
0124                                 regulator-allowed-modes = <2>, <4>;
0125                                 regulator-always-on;
0126 
0127                                 regulator-state-standby {
0128                                         regulator-on-in-suspend;
0129                                         regulator-mode = <4>;
0130                                 };
0131 
0132                                 regulator-state-mem {
0133                                         regulator-off-in-suspend;
0134                                         regulator-mode = <4>;
0135                                 };
0136                         };
0137 
0138                         vdd_ddr: VDD_OTHER {
0139                                 regulator-name = "VDD_OTHER";
0140                                 regulator-min-microvolt = <1800000>;
0141                                 regulator-max-microvolt = <1800000>;
0142                                 regulator-initial-mode = <2>;
0143                                 regulator-allowed-modes = <2>, <4>;
0144                                 regulator-always-on;
0145 
0146                                 regulator-state-standby {
0147                                         regulator-on-in-suspend;
0148                                         regulator-suspend-microvolt = <1800000>;
0149                                         regulator-changeable-in-suspend;
0150                                         regulator-mode = <4>;
0151                                 };
0152 
0153                                 regulator-state-mem {
0154                                         regulator-on-in-suspend;
0155                                         regulator-suspend-microvolt = <1800000>;
0156                                         regulator-changeable-in-suspend;
0157                                         regulator-mode = <4>;
0158                                 };
0159                         };
0160 
0161                         LDO1 {
0162                                 regulator-name = "LDO1";
0163                                 regulator-min-microvolt = <3300000>;
0164                                 regulator-max-microvolt = <3300000>;
0165                                 regulator-always-on;
0166 
0167                                 regulator-state-standby {
0168                                         regulator-on-in-suspend;
0169                                 };
0170 
0171                                 regulator-state-mem {
0172                                         regulator-off-in-suspend;
0173                                 };
0174                         };
0175 
0176                         LDO2 {
0177                                 regulator-name = "LDO2";
0178                                 regulator-min-microvolt = <1800000>;
0179                                 regulator-max-microvolt = <3300000>;
0180 
0181                                 regulator-state-standby {
0182                                         regulator-on-in-suspend;
0183                                 };
0184 
0185                                 regulator-state-mem {
0186                                         regulator-off-in-suspend;
0187                                 };
0188                         };
0189                 };
0190         };
0191 };
0192 
0193 &macb0 {
0194         pinctrl-names = "default";
0195         pinctrl-0 = <&pinctrl_macb0_default>;
0196         #address-cells = <1>;
0197         #size-cells = <0>;
0198         phy-mode = "rmii";
0199 
0200         ethernet-phy@0 {
0201                 reg = <0x0>;
0202                 interrupt-parent = <&pioA>;
0203                 interrupts = <PIN_PB24 IRQ_TYPE_LEVEL_LOW>;
0204                 pinctrl-names = "default";
0205                 pinctrl-0 = <&pinctrl_macb0_phy_irq>;
0206         };
0207 };
0208 
0209 &pmc {
0210         atmel,osc-bypass;
0211 };
0212 
0213 &qspi1 {
0214         pinctrl-names = "default";
0215         pinctrl-0 = <&pinctrl_qspi1_default>;
0216         status = "disabled";
0217 
0218         qspi1_flash: flash@0 {
0219                 #address-cells = <1>;
0220                 #size-cells = <1>;
0221                 compatible = "jedec,spi-nor";
0222                 reg = <0>;
0223                 spi-max-frequency = <80000000>;
0224                 spi-rx-bus-width = <4>;
0225                 spi-tx-bus-width = <4>;
0226                 m25p,fast-read;
0227                 status = "disabled";
0228 
0229                 at91bootstrap@0 {
0230                         label = "at91bootstrap";
0231                         reg = <0x0 0x40000>;
0232                 };
0233 
0234                 bootloader@40000 {
0235                         label = "bootloader";
0236                         reg = <0x40000 0xc0000>;
0237                 };
0238 
0239                 bootloaderenvred@100000 {
0240                         label = "bootloader env redundant";
0241                         reg = <0x100000 0x40000>;
0242                 };
0243 
0244                 bootloaderenv@140000 {
0245                         label = "bootloader env";
0246                         reg = <0x140000 0x40000>;
0247                 };
0248 
0249                 dtb@180000 {
0250                         label = "device tree";
0251                         reg = <0x180000 0x80000>;
0252                 };
0253 
0254                 kernel@200000 {
0255                         label = "kernel";
0256                         reg = <0x200000 0x600000>;
0257                 };
0258         };
0259 };
0260 
0261 &pioA {
0262         pinctrl_flx1_default: flx1_usart_default {
0263                 pinmux = <PIN_PA24__FLEXCOM1_IO0>,
0264                          <PIN_PA23__FLEXCOM1_IO1>,
0265                          <PIN_PA25__FLEXCOM1_IO3>,
0266                          <PIN_PA26__FLEXCOM1_IO4>;
0267                 bias-disable;
0268         };
0269 
0270         pinctrl_i2c0_default: i2c0_default {
0271                 pinmux = <PIN_PD21__TWD0>,
0272                          <PIN_PD22__TWCK0>;
0273                 bias-disable;
0274         };
0275 
0276         pinctrl_i2c0_gpio: i2c0_gpio {
0277                 pinmux = <PIN_PD21__GPIO>,
0278                          <PIN_PD22__GPIO>;
0279                 bias-disable;
0280         };
0281 
0282         pinctrl_i2c1_default: i2c1_default {
0283                 pinmux = <PIN_PD19__TWD1>,
0284                          <PIN_PD20__TWCK1>;
0285                 bias-disable;
0286         };
0287 
0288         pinctrl_i2c1_gpio: i2c1_gpio {
0289                 pinmux = <PIN_PD19__GPIO>,
0290                          <PIN_PD20__GPIO>;
0291                 bias-disable;
0292         };
0293 
0294         pinctrl_macb0_default: macb0_default {
0295                 pinmux = <PIN_PB14__GTXCK>,
0296                          <PIN_PB15__GTXEN>,
0297                          <PIN_PB16__GRXDV>,
0298                          <PIN_PB17__GRXER>,
0299                          <PIN_PB18__GRX0>,
0300                          <PIN_PB19__GRX1>,
0301                          <PIN_PB20__GTX0>,
0302                          <PIN_PB21__GTX1>,
0303                          <PIN_PB22__GMDC>,
0304                          <PIN_PB23__GMDIO>;
0305                 bias-disable;
0306         };
0307 
0308         pinctrl_macb0_phy_irq: macb0_phy_irq {
0309                 pinmux = <PIN_PB24__GPIO>;
0310                 bias-disable;
0311         };
0312 
0313         pinctrl_qspi1_default: qspi1_default {
0314                 pinmux = <PIN_PB5__QSPI1_SCK>,
0315                          <PIN_PB6__QSPI1_CS>,
0316                          <PIN_PB7__QSPI1_IO0>,
0317                          <PIN_PB8__QSPI1_IO1>,
0318                          <PIN_PB9__QSPI1_IO2>,
0319                          <PIN_PB10__QSPI1_IO3>;
0320                 bias-pull-up;
0321         };
0322 
0323         pinctrl_sdmmc1_default: sdmmc1_default {
0324                 cmd-data {
0325                         pinmux = <PIN_PA28__SDMMC1_CMD>,
0326                                  <PIN_PA18__SDMMC1_DAT0>,
0327                                  <PIN_PA19__SDMMC1_DAT1>,
0328                                  <PIN_PA20__SDMMC1_DAT2>,
0329                                  <PIN_PA21__SDMMC1_DAT3>;
0330                         bias-disable;
0331                 };
0332 
0333                 conf-ck {
0334                         pinmux = <PIN_PA22__SDMMC1_CK>;
0335                         bias-disable;
0336                 };
0337         };
0338 
0339         pinctrl_wilc_default: wilc_default {
0340                 conf-irq {
0341                         pinmux = <PIN_PB25__GPIO>;
0342                         bias-disable;
0343                 };
0344         };
0345 
0346         pinctrl_wilc_pwrseq: wilc_pwrseq {
0347                 conf-ce-nrst {
0348                         pinmux = <PIN_PA27__GPIO>,
0349                                  <PIN_PA29__GPIO>;
0350                         bias-disable;
0351                 };
0352 
0353                 conf-rtcclk {
0354                         pinmux = <PIN_PB13__PCK1>;
0355                         bias-disable;
0356                 };
0357         };
0358 };
0359 
0360 &sdmmc1 {
0361         #address-cells = <1>;
0362         #size-cells = <0>;
0363         bus-width = <4>;
0364         pinctrl-names = "default";
0365         pinctrl-0 = <&pinctrl_sdmmc1_default>;
0366         mmc-pwrseq = <&wifi_pwrseq>;
0367         no-1-8-v;
0368         non-removable;
0369         bus-width = <4>;
0370         status = "okay";
0371 
0372         wilc: wifi@0 {
0373                 reg = <0>;
0374                 compatible = "microchip,wilc1000";
0375                 pinctrl-names = "default";
0376                 pinctrl-0 = <&pinctrl_wilc_default>;
0377                 clocks = <&pmc PMC_TYPE_SYSTEM 9>;
0378                 clock-names = "rtc";
0379                 interrupts = <PIN_PB25 IRQ_TYPE_NONE>;
0380                 interrupt-parent = <&pioA>;
0381                 assigned-clocks = <&pmc PMC_TYPE_SYSTEM 9>;
0382                 assigned-clock-rates = <32768>;
0383         };
0384 };
0385