Back to home page

OSCL-LXR

 
 

    


0001 /*
0002  * Copyright 2013 Maxime Ripard
0003  *
0004  * Maxime Ripard <maxime.ripard@free-electrons.com>
0005  *
0006  * This file is dual-licensed: you can use it either under the terms
0007  * of the GPL or the X11 license, at your option. Note that this dual
0008  * licensing only applies to this file, and not this project as a
0009  * whole.
0010  *
0011  *  a) This library is free software; you can redistribute it and/or
0012  *     modify it under the terms of the GNU General Public License as
0013  *     published by the Free Software Foundation; either version 2 of the
0014  *     License, or (at your option) any later version.
0015  *
0016  *     This library is distributed in the hope that it will be useful,
0017  *     but WITHOUT ANY WARRANTY; without even the implied warranty of
0018  *     MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
0019  *     GNU General Public License for more details.
0020  *
0021  * Or, alternatively,
0022  *
0023  *  b) Permission is hereby granted, free of charge, to any person
0024  *     obtaining a copy of this software and associated documentation
0025  *     files (the "Software"), to deal in the Software without
0026  *     restriction, including without limitation the rights to use,
0027  *     copy, modify, merge, publish, distribute, sublicense, and/or
0028  *     sell copies of the Software, and to permit persons to whom the
0029  *     Software is furnished to do so, subject to the following
0030  *     conditions:
0031  *
0032  *     The above copyright notice and this permission notice shall be
0033  *     included in all copies or substantial portions of the Software.
0034  *
0035  *     THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
0036  *     EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES
0037  *     OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
0038  *     NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
0039  *     HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY,
0040  *     WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
0041  *     FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR
0042  *     OTHER DEALINGS IN THE SOFTWARE.
0043  */
0044 
0045 #include "sun5i.dtsi"
0046 
0047 #include <dt-bindings/dma/sun4i-a10.h>
0048 
0049 / {
0050         aliases {
0051                 ethernet0 = &emac;
0052         };
0053 
0054         chosen {
0055                 #address-cells = <1>;
0056                 #size-cells = <1>;
0057                 ranges;
0058 
0059                 framebuffer-lcd0-hdmi {
0060                         compatible = "allwinner,simple-framebuffer",
0061                                      "simple-framebuffer";
0062                         allwinner,pipeline = "de_be0-lcd0-hdmi";
0063                         clocks = <&ccu CLK_AHB_LCD>, <&ccu CLK_AHB_HDMI>,
0064                                  <&ccu CLK_AHB_DE_BE>, <&ccu CLK_DRAM_DE_BE>,
0065                                  <&ccu CLK_DE_BE>, <&ccu CLK_HDMI>;
0066                         status = "disabled";
0067                 };
0068         };
0069 
0070         display-engine {
0071                 compatible = "allwinner,sun5i-a10s-display-engine";
0072                 allwinner,pipelines = <&fe0>;
0073         };
0074 
0075         soc {
0076                 hdmi: hdmi@1c16000 {
0077                         compatible = "allwinner,sun5i-a10s-hdmi";
0078                         reg = <0x01c16000 0x1000>;
0079                         interrupts = <58>;
0080                         clocks = <&ccu CLK_AHB_HDMI>, <&ccu CLK_HDMI>,
0081                                  <&ccu CLK_PLL_VIDEO0_2X>,
0082                                  <&ccu CLK_PLL_VIDEO1_2X>;
0083                         clock-names = "ahb", "mod", "pll-0", "pll-1";
0084                         dmas = <&dma SUN4I_DMA_NORMAL 16>,
0085                                <&dma SUN4I_DMA_NORMAL 16>,
0086                                <&dma SUN4I_DMA_DEDICATED 24>;
0087                         dma-names = "ddc-tx", "ddc-rx", "audio-tx";
0088                         status = "disabled";
0089 
0090                         ports {
0091                                 #address-cells = <1>;
0092                                 #size-cells = <0>;
0093 
0094                                 hdmi_in: port@0 {
0095                                         reg = <0>;
0096 
0097                                         hdmi_in_tcon0: endpoint {
0098                                                 remote-endpoint = <&tcon0_out_hdmi>;
0099                                         };
0100                                 };
0101 
0102                                 hdmi_out: port@1 {
0103                                         reg = <1>;
0104                                 };
0105                         };
0106                 };
0107 
0108                 pwm: pwm@1c20e00 {
0109                         compatible = "allwinner,sun5i-a10s-pwm";
0110                         reg = <0x01c20e00 0xc>;
0111                         clocks = <&ccu CLK_HOSC>;
0112                         #pwm-cells = <3>;
0113                         status = "disabled";
0114                 };
0115         };
0116 };
0117 
0118 &ccu {
0119         compatible = "allwinner,sun5i-a10s-ccu";
0120 };
0121 
0122 &mmc1 {
0123         pinctrl-names = "default";
0124         pinctrl-0 = <&mmc1_pins>;
0125 };
0126 
0127 &pio {
0128         compatible = "allwinner,sun5i-a10s-pinctrl";
0129 
0130         uart0_pb_pins: uart0-pb-pins {
0131                 pins = "PB19", "PB20";
0132                 function = "uart0";
0133         };
0134 
0135         uart2_pc_pins: uart2-pc-pins {
0136                 pins = "PC18", "PC19";
0137                 function = "uart2";
0138         };
0139 
0140         emac_pa_pins: emac-pa-pins {
0141                 pins = "PA0", "PA1", "PA2",
0142                                 "PA3", "PA4", "PA5", "PA6",
0143                                 "PA7", "PA8", "PA9", "PA10",
0144                                 "PA11", "PA12", "PA13", "PA14",
0145                                 "PA15", "PA16";
0146                 function = "emac";
0147         };
0148 
0149         mmc1_pins: mmc1-pins {
0150                 pins = "PG3", "PG4", "PG5",
0151                                  "PG6", "PG7", "PG8";
0152                 function = "mmc1";
0153                 drive-strength = <30>;
0154         };
0155 
0156         spi2_pb_pins: spi2-pb-pins {
0157                 pins = "PB12", "PB13", "PB14";
0158                 function = "spi2";
0159         };
0160 
0161         spi2_cs0_pb_pin: spi2-cs0-pb-pin {
0162                 pins = "PB11";
0163                 function = "spi2";
0164         };
0165 };
0166 
0167 &tcon0_out {
0168         tcon0_out_hdmi: endpoint@2 {
0169                 reg = <2>;
0170                 remote-endpoint = <&hdmi_in_tcon0>;
0171                 allwinner,tcon-channel = <1>;
0172         };
0173 };