x86/oprofile: Fix bogus GCC-8 warning in nmi_setup()
[cris-mirror.git] / arch / arm / boot / dts / r8a7791-koelsch.dts
bloba50924d12b6f37d5a97476776a18f11fad2a1869
1 /*
2  * Device Tree Source for the Koelsch board
3  *
4  * Copyright (C) 2013 Renesas Electronics Corporation
5  * Copyright (C) 2013-2014 Renesas Solutions Corp.
6  * Copyright (C) 2014 Cogent Embedded, Inc.
7  *
8  * This file is licensed under the terms of the GNU General Public License
9  * version 2.  This program is licensed "as is" without any warranty of any
10  * kind, whether express or implied.
11  */
14  * SSI-AK4643
15  *
16  * SW1: 1: AK4643
17  *      2: CN22
18  *      3: ADV7511
19  *
20  * This command is required when Playback/Capture
21  *
22  *      amixer set "LINEOUT Mixer DACL" on
23  *      amixer set "DVC Out" 100%
24  *      amixer set "DVC In" 100%
25  *
26  * You can use Mute
27  *
28  *      amixer set "DVC Out Mute" on
29  *      amixer set "DVC In Mute" on
30  *
31  * You can use Volume Ramp
32  *
33  *      amixer set "DVC Out Ramp Up Rate"   "0.125 dB/64 steps"
34  *      amixer set "DVC Out Ramp Down Rate" "0.125 dB/512 steps"
35  *      amixer set "DVC Out Ramp" on
36  *      aplay xxx.wav &
37  *      amixer set "DVC Out"  80%  // Volume Down
38  *      amixer set "DVC Out" 100%  // Volume Up
39  */
41 /dts-v1/;
42 #include "r8a7791.dtsi"
43 #include <dt-bindings/gpio/gpio.h>
44 #include <dt-bindings/input/input.h>
46 / {
47         model = "Koelsch";
48         compatible = "renesas,koelsch", "renesas,r8a7791";
50         aliases {
51                 serial0 = &scif0;
52                 serial1 = &scif1;
53                 i2c9 = &gpioi2c1;
54                 i2c12 = &i2cexio1;
55         };
57         chosen {
58                 bootargs = "ignore_loglevel rw root=/dev/nfs ip=dhcp";
59                 stdout-path = "serial0:115200n8";
60         };
62         memory@40000000 {
63                 device_type = "memory";
64                 reg = <0 0x40000000 0 0x40000000>;
65         };
67         memory@200000000 {
68                 device_type = "memory";
69                 reg = <2 0x00000000 0 0x40000000>;
70         };
72         lbsc {
73                 #address-cells = <1>;
74                 #size-cells = <1>;
75         };
77         keyboard {
78                 compatible = "gpio-keys";
80                 key-1 {
81                         gpios = <&gpio5 0 GPIO_ACTIVE_LOW>;
82                         linux,code = <KEY_1>;
83                         label = "SW2-1";
84                         wakeup-source;
85                         debounce-interval = <20>;
86                 };
87                 key-2 {
88                         gpios = <&gpio5 1 GPIO_ACTIVE_LOW>;
89                         linux,code = <KEY_2>;
90                         label = "SW2-2";
91                         wakeup-source;
92                         debounce-interval = <20>;
93                 };
94                 key-3 {
95                         gpios = <&gpio5 2 GPIO_ACTIVE_LOW>;
96                         linux,code = <KEY_3>;
97                         label = "SW2-3";
98                         wakeup-source;
99                         debounce-interval = <20>;
100                 };
101                 key-4 {
102                         gpios = <&gpio5 3 GPIO_ACTIVE_LOW>;
103                         linux,code = <KEY_4>;
104                         label = "SW2-4";
105                         wakeup-source;
106                         debounce-interval = <20>;
107                 };
108                 key-a {
109                         gpios = <&gpio7 0 GPIO_ACTIVE_LOW>;
110                         linux,code = <KEY_A>;
111                         label = "SW30";
112                         wakeup-source;
113                         debounce-interval = <20>;
114                 };
115                 key-b {
116                         gpios = <&gpio7 1 GPIO_ACTIVE_LOW>;
117                         linux,code = <KEY_B>;
118                         label = "SW31";
119                         wakeup-source;
120                         debounce-interval = <20>;
121                 };
122                 key-c {
123                         gpios = <&gpio7 2 GPIO_ACTIVE_LOW>;
124                         linux,code = <KEY_C>;
125                         label = "SW32";
126                         wakeup-source;
127                         debounce-interval = <20>;
128                 };
129                 key-d {
130                         gpios = <&gpio7 3 GPIO_ACTIVE_LOW>;
131                         linux,code = <KEY_D>;
132                         label = "SW33";
133                         wakeup-source;
134                         debounce-interval = <20>;
135                 };
136                 key-e {
137                         gpios = <&gpio7 4 GPIO_ACTIVE_LOW>;
138                         linux,code = <KEY_E>;
139                         label = "SW34";
140                         wakeup-source;
141                         debounce-interval = <20>;
142                 };
143                 key-f {
144                         gpios = <&gpio7 5 GPIO_ACTIVE_LOW>;
145                         linux,code = <KEY_F>;
146                         label = "SW35";
147                         wakeup-source;
148                         debounce-interval = <20>;
149                 };
150                 key-g {
151                         gpios = <&gpio7 6 GPIO_ACTIVE_LOW>;
152                         linux,code = <KEY_G>;
153                         label = "SW36";
154                         wakeup-source;
155                         debounce-interval = <20>;
156                 };
157         };
159         leds {
160                 compatible = "gpio-leds";
161                 led6 {
162                         gpios = <&gpio2 19 GPIO_ACTIVE_HIGH>;
163                         label = "LED6";
164                 };
165                 led7 {
166                         gpios = <&gpio2 20 GPIO_ACTIVE_HIGH>;
167                         label = "LED7";
168                 };
169                 led8 {
170                         gpios = <&gpio2 21 GPIO_ACTIVE_HIGH>;
171                         label = "LED8";
172                 };
173         };
175         vcc_sdhi0: regulator-vcc-sdhi0 {
176                 compatible = "regulator-fixed";
178                 regulator-name = "SDHI0 Vcc";
179                 regulator-min-microvolt = <3300000>;
180                 regulator-max-microvolt = <3300000>;
182                 gpio = <&gpio7 17 GPIO_ACTIVE_HIGH>;
183                 enable-active-high;
184         };
186         vccq_sdhi0: regulator-vccq-sdhi0 {
187                 compatible = "regulator-gpio";
189                 regulator-name = "SDHI0 VccQ";
190                 regulator-min-microvolt = <1800000>;
191                 regulator-max-microvolt = <3300000>;
193                 gpios = <&gpio2 12 GPIO_ACTIVE_HIGH>;
194                 gpios-states = <1>;
195                 states = <3300000 1
196                           1800000 0>;
197         };
199         vcc_sdhi1: regulator-vcc-sdhi1 {
200                 compatible = "regulator-fixed";
202                 regulator-name = "SDHI1 Vcc";
203                 regulator-min-microvolt = <3300000>;
204                 regulator-max-microvolt = <3300000>;
206                 gpio = <&gpio7 18 GPIO_ACTIVE_HIGH>;
207                 enable-active-high;
208         };
210         vccq_sdhi1: regulator-vccq-sdhi1 {
211                 compatible = "regulator-gpio";
213                 regulator-name = "SDHI1 VccQ";
214                 regulator-min-microvolt = <1800000>;
215                 regulator-max-microvolt = <3300000>;
217                 gpios = <&gpio2 13 GPIO_ACTIVE_HIGH>;
218                 gpios-states = <1>;
219                 states = <3300000 1
220                           1800000 0>;
221         };
223         vcc_sdhi2: regulator-vcc-sdhi2 {
224                 compatible = "regulator-fixed";
226                 regulator-name = "SDHI2 Vcc";
227                 regulator-min-microvolt = <3300000>;
228                 regulator-max-microvolt = <3300000>;
230                 gpio = <&gpio7 19 GPIO_ACTIVE_HIGH>;
231                 enable-active-high;
232         };
234         vccq_sdhi2: regulator-vccq-sdhi2 {
235                 compatible = "regulator-gpio";
237                 regulator-name = "SDHI2 VccQ";
238                 regulator-min-microvolt = <1800000>;
239                 regulator-max-microvolt = <3300000>;
241                 gpios = <&gpio2 26 GPIO_ACTIVE_HIGH>;
242                 gpios-states = <1>;
243                 states = <3300000 1
244                           1800000 0>;
245         };
247         audio_clock: audio_clock {
248                 compatible = "fixed-clock";
249                 #clock-cells = <0>;
250                 clock-frequency = <11289600>;
251         };
253         rsnd_ak4643: sound {
254                 compatible = "simple-audio-card";
256                 simple-audio-card,format = "left_j";
257                 simple-audio-card,bitclock-master = <&sndcodec>;
258                 simple-audio-card,frame-master = <&sndcodec>;
260                 sndcpu: simple-audio-card,cpu {
261                         sound-dai = <&rcar_sound>;
262                 };
264                 sndcodec: simple-audio-card,codec {
265                         sound-dai = <&ak4643>;
266                         clocks = <&audio_clock>;
267                 };
268         };
270         hdmi-in {
271                 compatible = "hdmi-connector";
272                 type = "a";
274                 port {
275                         hdmi_con_in: endpoint {
276                                 remote-endpoint = <&adv7612_in>;
277                         };
278                 };
279         };
281         cec_clock: cec-clock {
282                 compatible = "fixed-clock";
283                 #clock-cells = <0>;
284                 clock-frequency = <12000000>;
285         };
287         hdmi-out {
288                 compatible = "hdmi-connector";
289                 type = "a";
291                 port {
292                         hdmi_con_out: endpoint {
293                                 remote-endpoint = <&adv7511_out>;
294                         };
295                 };
296         };
298         x2_clk: x2-clock {
299                 compatible = "fixed-clock";
300                 #clock-cells = <0>;
301                 clock-frequency = <74250000>;
302         };
304         x13_clk: x13-clock {
305                 compatible = "fixed-clock";
306                 #clock-cells = <0>;
307                 clock-frequency = <148500000>;
308         };
310         gpioi2c1: i2c-9 {
311                 #address-cells = <1>;
312                 #size-cells = <0>;
313                 compatible = "i2c-gpio";
314                 status = "disabled";
315                 sda-gpios = <&gpio7 16 (GPIO_ACTIVE_HIGH | GPIO_OPEN_DRAIN)>;
316                 scl-gpios = <&gpio7 15 (GPIO_ACTIVE_HIGH | GPIO_OPEN_DRAIN)>;
317                 i2c-gpio,delay-us = <5>;
318         };
320         /*
321          * I2C1 is routed to EXIO connector B, pins 64 (SCL) + 66 (SDA).
322          * A fallback to GPIO is provided.
323          */
324         i2cexio1: i2c-12 {
325                 compatible = "i2c-demux-pinctrl";
326                 i2c-parent = <&i2c1>, <&gpioi2c1>;
327                 i2c-bus-name = "i2c-exio1";
328                 #address-cells = <1>;
329                 #size-cells = <0>;
330         };
333 &du {
334         pinctrl-0 = <&du_pins>;
335         pinctrl-names = "default";
336         status = "okay";
338         clocks = <&cpg CPG_MOD 724>, <&cpg CPG_MOD 723>, <&cpg CPG_MOD 726>,
339                  <&x13_clk>, <&x2_clk>;
340         clock-names = "du.0", "du.1", "lvds.0",
341                       "dclkin.0", "dclkin.1";
343         ports {
344                 port@0 {
345                         endpoint {
346                                 remote-endpoint = <&adv7511_in>;
347                         };
348                 };
349                 port@1 {
350                         lvds_connector: endpoint {
351                         };
352                 };
353         };
356 &extal_clk {
357         clock-frequency = <20000000>;
360 &pfc {
361         pinctrl-0 = <&scif_clk_pins>;
362         pinctrl-names = "default";
364         i2c1_pins: i2c1 {
365                 groups = "i2c1";
366                 function = "i2c1";
367         };
369         i2c2_pins: i2c2 {
370                 groups = "i2c2";
371                 function = "i2c2";
372         };
374         du_pins: du {
375                 groups = "du_rgb888", "du_sync", "du_disp", "du_clk_out_0";
376                 function = "du";
377         };
379         scif0_pins: scif0 {
380                 groups = "scif0_data_d";
381                 function = "scif0";
382         };
384         scif1_pins: scif1 {
385                 groups = "scif1_data_d";
386                 function = "scif1";
387         };
389         scif_clk_pins: scif_clk {
390                 groups = "scif_clk";
391                 function = "scif_clk";
392         };
394         ether_pins: ether {
395                 groups = "eth_link", "eth_mdio", "eth_rmii";
396                 function = "eth";
397         };
399         phy1_pins: phy1 {
400                 groups = "intc_irq0";
401                 function = "intc";
402         };
404         sdhi0_pins: sd0 {
405                 groups = "sdhi0_data4", "sdhi0_ctrl";
406                 function = "sdhi0";
407                 power-source = <3300>;
408         };
410         sdhi0_pins_uhs: sd0_uhs {
411                 groups = "sdhi0_data4", "sdhi0_ctrl";
412                 function = "sdhi0";
413                 power-source = <1800>;
414         };
416         sdhi1_pins: sd1 {
417                 groups = "sdhi1_data4", "sdhi1_ctrl";
418                 function = "sdhi1";
419                 power-source = <3300>;
420         };
422         sdhi1_pins_uhs: sd1_uhs {
423                 groups = "sdhi1_data4", "sdhi1_ctrl";
424                 function = "sdhi1";
425                 power-source = <1800>;
426         };
428         sdhi2_pins: sd2 {
429                 groups = "sdhi2_data4", "sdhi2_ctrl";
430                 function = "sdhi2";
431                 power-source = <3300>;
432         };
434         sdhi2_pins_uhs: sd2_uhs {
435                 groups = "sdhi2_data4", "sdhi2_ctrl";
436                 function = "sdhi2";
437                 power-source = <1800>;
438         };
440         qspi_pins: qspi {
441                 groups = "qspi_ctrl", "qspi_data4";
442                 function = "qspi";
443         };
445         msiof0_pins: msiof0 {
446                 groups = "msiof0_clk", "msiof0_sync", "msiof0_rx",
447                                  "msiof0_tx";
448                 function = "msiof0";
449         };
451         usb0_pins: usb0 {
452                 groups = "usb0";
453                 function = "usb0";
454         };
456         usb1_pins: usb1 {
457                 groups = "usb1";
458                 function = "usb1";
459         };
461         vin0_pins: vin0 {
462                 groups = "vin0_data24", "vin0_sync", "vin0_clkenb", "vin0_clk";
463                 function = "vin0";
464         };
466         vin1_pins: vin1 {
467                 groups = "vin1_data8", "vin1_clk";
468                 function = "vin1";
469         };
471         sound_pins: sound {
472                 groups = "ssi0129_ctrl", "ssi0_data", "ssi1_data";
473                 function = "ssi";
474         };
476         sound_clk_pins: sound_clk {
477                 groups = "audio_clk_a";
478                 function = "audio_clk";
479         };
482 &ether {
483         pinctrl-0 = <&ether_pins &phy1_pins>;
484         pinctrl-names = "default";
486         phy-handle = <&phy1>;
487         renesas,ether-link-active-low;
488         status = "okay";
490         phy1: ethernet-phy@1 {
491                 reg = <1>;
492                 interrupt-parent = <&irqc0>;
493                 interrupts = <0 IRQ_TYPE_LEVEL_LOW>;
494                 micrel,led-mode = <1>;
495         };
498 &cmt0 {
499         status = "okay";
502 &sata0 {
503         status = "okay";
506 &scif0 {
507         pinctrl-0 = <&scif0_pins>;
508         pinctrl-names = "default";
510         status = "okay";
513 &scif1 {
514         pinctrl-0 = <&scif1_pins>;
515         pinctrl-names = "default";
517         status = "okay";
520 &scif_clk {
521         clock-frequency = <14745600>;
524 &sdhi0 {
525         pinctrl-0 = <&sdhi0_pins>;
526         pinctrl-1 = <&sdhi0_pins_uhs>;
527         pinctrl-names = "default", "state_uhs";
529         vmmc-supply = <&vcc_sdhi0>;
530         vqmmc-supply = <&vccq_sdhi0>;
531         cd-gpios = <&gpio6 6 GPIO_ACTIVE_LOW>;
532         wp-gpios = <&gpio6 7 GPIO_ACTIVE_HIGH>;
533         sd-uhs-sdr50;
534         sd-uhs-sdr104;
535         status = "okay";
538 &sdhi1 {
539         pinctrl-0 = <&sdhi1_pins>;
540         pinctrl-1 = <&sdhi1_pins_uhs>;
541         pinctrl-names = "default", "state_uhs";
543         vmmc-supply = <&vcc_sdhi1>;
544         vqmmc-supply = <&vccq_sdhi1>;
545         cd-gpios = <&gpio6 14 GPIO_ACTIVE_LOW>;
546         wp-gpios = <&gpio6 15 GPIO_ACTIVE_HIGH>;
547         sd-uhs-sdr50;
548         status = "okay";
551 &sdhi2 {
552         pinctrl-0 = <&sdhi2_pins>;
553         pinctrl-1 = <&sdhi2_pins_uhs>;
554         pinctrl-names = "default", "state_uhs";
556         vmmc-supply = <&vcc_sdhi2>;
557         vqmmc-supply = <&vccq_sdhi2>;
558         cd-gpios = <&gpio6 22 GPIO_ACTIVE_LOW>;
559         sd-uhs-sdr50;
560         status = "okay";
563 &qspi {
564         pinctrl-0 = <&qspi_pins>;
565         pinctrl-names = "default";
567         status = "okay";
569         flash: flash@0 {
570                 compatible = "spansion,s25fl512s", "jedec,spi-nor";
571                 reg = <0>;
572                 spi-max-frequency = <30000000>;
573                 spi-tx-bus-width = <4>;
574                 spi-rx-bus-width = <4>;
575                 spi-cpha;
576                 spi-cpol;
577                 m25p,fast-read;
579                 partitions {
580                         compatible = "fixed-partitions";
581                         #address-cells = <1>;
582                         #size-cells = <1>;
584                         partition@0 {
585                                 label = "loader";
586                                 reg = <0x00000000 0x00080000>;
587                                 read-only;
588                         };
589                         partition@80000 {
590                                 label = "user";
591                                 reg = <0x00080000 0x00580000>;
592                                 read-only;
593                         };
594                         partition@600000 {
595                                 label = "flash";
596                                 reg = <0x00600000 0x03a00000>;
597                         };
598                 };
599         };
602 &msiof0 {
603         pinctrl-0 = <&msiof0_pins>;
604         pinctrl-names = "default";
606         status = "okay";
608         pmic: pmic@0 {
609                 compatible = "renesas,r2a11302ft";
610                 reg = <0>;
611                 spi-max-frequency = <6000000>;
612                 spi-cpol;
613                 spi-cpha;
614         };
617 &i2c1 {
618         pinctrl-0 = <&i2c1_pins>;
619         pinctrl-names = "i2c-exio1";
622 &i2c2 {
623         pinctrl-0 = <&i2c2_pins>;
624         pinctrl-names = "default";
626         status = "okay";
627         clock-frequency = <100000>;
629         ak4643: codec@12 {
630                 compatible = "asahi-kasei,ak4643";
631                 #sound-dai-cells = <0>;
632                 reg = <0x12>;
633         };
635         composite-in@20 {
636                 compatible = "adi,adv7180";
637                 reg = <0x20>;
638                 remote = <&vin1>;
640                 port {
641                         adv7180: endpoint {
642                                 bus-width = <8>;
643                                 remote-endpoint = <&vin1ep>;
644                         };
645                 };
646         };
648         hdmi@39 {
649                 compatible = "adi,adv7511w";
650                 reg = <0x39>;
651                 interrupt-parent = <&gpio3>;
652                 interrupts = <29 IRQ_TYPE_LEVEL_LOW>;
653                 clocks = <&cec_clock>;
654                 clock-names = "cec";
656                 adi,input-depth = <8>;
657                 adi,input-colorspace = "rgb";
658                 adi,input-clock = "1x";
659                 adi,input-style = <1>;
660                 adi,input-justification = "evenly";
662                 ports {
663                         #address-cells = <1>;
664                         #size-cells = <0>;
666                         port@0 {
667                                 reg = <0>;
668                                 adv7511_in: endpoint {
669                                         remote-endpoint = <&du_out_rgb>;
670                                 };
671                         };
673                         port@1 {
674                                 reg = <1>;
675                                 adv7511_out: endpoint {
676                                         remote-endpoint = <&hdmi_con_out>;
677                                 };
678                         };
679                 };
680         };
682         hdmi-in@4c {
683                 compatible = "adi,adv7612";
684                 reg = <0x4c>;
685                 interrupt-parent = <&gpio4>;
686                 interrupts = <2 IRQ_TYPE_LEVEL_LOW>;
687                 default-input = <0>;
689                 ports {
690                         #address-cells = <1>;
691                         #size-cells = <0>;
693                         port@0 {
694                                 reg = <0>;
695                                 adv7612_in: endpoint {
696                                         remote-endpoint = <&hdmi_con_in>;
697                                 };
698                         };
700                         port@2 {
701                                 reg = <2>;
702                                 adv7612_out: endpoint {
703                                         remote-endpoint = <&vin0ep2>;
704                                 };
705                         };
706                 };
707         };
709         eeprom@50 {
710                 compatible = "renesas,r1ex24002", "atmel,24c02";
711                 reg = <0x50>;
712                 pagesize = <16>;
713         };
716 &i2c6 {
717         status = "okay";
718         clock-frequency = <100000>;
720         pmic@58 {
721                 compatible = "dlg,da9063";
722                 reg = <0x58>;
723                 interrupt-parent = <&irqc0>;
724                 interrupts = <2 IRQ_TYPE_LEVEL_LOW>;
725                 interrupt-controller;
727                 rtc {
728                         compatible = "dlg,da9063-rtc";
729                 };
731                 wdt {
732                         compatible = "dlg,da9063-watchdog";
733                 };
734         };
736         vdd_dvfs: regulator@68 {
737                 compatible = "dlg,da9210";
738                 reg = <0x68>;
739                 interrupt-parent = <&irqc0>;
740                 interrupts = <2 IRQ_TYPE_LEVEL_LOW>;
742                 regulator-min-microvolt = <1000000>;
743                 regulator-max-microvolt = <1000000>;
744                 regulator-boot-on;
745                 regulator-always-on;
746         };
749 &pci0 {
750         status = "okay";
751         pinctrl-0 = <&usb0_pins>;
752         pinctrl-names = "default";
755 &pci1 {
756         status = "okay";
757         pinctrl-0 = <&usb1_pins>;
758         pinctrl-names = "default";
761 &hsusb {
762         status = "okay";
763         pinctrl-0 = <&usb0_pins>;
764         pinctrl-names = "default";
765         renesas,enable-gpio = <&gpio5 31 GPIO_ACTIVE_HIGH>;
768 &usbphy {
769         status = "okay";
772 &pcie_bus_clk {
773         clock-frequency = <100000000>;
776 &pciec {
777         status = "okay";
780 &cpu0 {
781         cpu0-supply = <&vdd_dvfs>;
784 /* HDMI video input */
785 &vin0 {
786         status = "okay";
787         pinctrl-0 = <&vin0_pins>;
788         pinctrl-names = "default";
790         port {
791                 #address-cells = <1>;
792                 #size-cells = <0>;
794                 vin0ep2: endpoint {
795                         remote-endpoint = <&adv7612_out>;
796                         bus-width = <24>;
797                         hsync-active = <0>;
798                         vsync-active = <0>;
799                         pclk-sample = <1>;
800                         data-active = <1>;
801                 };
802         };
805 /* composite video input */
806 &vin1 {
807         status = "okay";
808         pinctrl-0 = <&vin1_pins>;
809         pinctrl-names = "default";
811         port {
812                 #address-cells = <1>;
813                 #size-cells = <0>;
815                 vin1ep: endpoint {
816                         remote-endpoint = <&adv7180>;
817                         bus-width = <8>;
818                 };
819         };
822 &rcar_sound {
823         pinctrl-0 = <&sound_pins &sound_clk_pins>;
824         pinctrl-names = "default";
826         /* Single DAI */
827         #sound-dai-cells = <0>;
829         status = "okay";
831         rcar_sound,dai {
832                 dai0 {
833                         playback = <&ssi0 &src2 &dvc0>;
834                         capture  = <&ssi1 &src3 &dvc1>;
835                 };
836         };
839 &ssi1 {
840         shared-pin;