Back to home page

OSCL-LXR

 
 

    


0001 // SPDX-License-Identifier: GPL-2.0 or MIT
0002 //
0003 // Device Tree Source for General Electric B1x5Pv2
0004 // patient monitor series
0005 //
0006 // Copyright 2018-2021 General Electric Company
0007 // Copyright 2018-2021 Collabora
0008 
0009 #include <dt-bindings/input/input.h>
0010 #include "imx6dl-qmx6.dtsi"
0011 
0012 / {
0013         chosen {
0014                 stdout-path = &uart3;
0015         };
0016 
0017         /* Do not allow frequencies above 800MHz */
0018         cpus {
0019                 cpu@0 {
0020                         operating-points = <
0021                                 /* kHz    uV */
0022                                 792000  1175000
0023                                 396000  1150000
0024                         >;
0025                         fsl,soc-operating-points = <
0026                                 /* ARM kHz      SOC-PU uV */
0027                                 792000  1175000
0028                                 396000  1175000
0029                         >;
0030                 };
0031 
0032                 cpu@1 {
0033                         operating-points = <
0034                                 /* kHz    uV */
0035                                 792000  1175000
0036                                 396000  1150000
0037                         >;
0038                         fsl,soc-operating-points = <
0039                                 /* ARM kHz      SOC-PU uV */
0040                                 792000  1175000
0041                                 396000  1175000
0042                         >;
0043                 };
0044         };
0045 
0046         reg_syspwr: regulator-12v {
0047                 compatible = "regulator-fixed";
0048                 regulator-name = "SYS_PWR";
0049                 regulator-min-microvolt = <12000000>;
0050                 regulator-max-microvolt = <12000000>;
0051         };
0052 
0053         reg_5v_pmc: regulator-5v-pmc {
0054                 compatible = "regulator-fixed";
0055                 regulator-name = "5V PMC";
0056                 regulator-min-microvolt = <5000000>;
0057                 regulator-max-microvolt = <5000000>;
0058                 vin-supply = <&reg_syspwr>;
0059         };
0060 
0061         reg_5v: regulator-5v {
0062                 compatible = "regulator-fixed";
0063                 regulator-name = "5V";
0064                 regulator-min-microvolt = <5000000>;
0065                 regulator-max-microvolt = <5000000>;
0066                 vin-supply = <&reg_syspwr>;
0067         };
0068 
0069         reg_3v3: regulator-3v3 {
0070                 compatible = "regulator-fixed";
0071                 regulator-name = "3V3";
0072                 regulator-min-microvolt = <3300000>;
0073                 regulator-max-microvolt = <3300000>;
0074                 vin-supply = <&reg_syspwr>;
0075         };
0076 
0077         reg_5v0_audio: regulator-5v0-audio {
0078                 compatible = "regulator-fixed";
0079                 regulator-name = "5V0_AUDIO";
0080                 regulator-min-microvolt = <5000000>;
0081                 regulator-max-microvolt = <5000000>;
0082                 vin-supply = <&reg_5v>;
0083                 gpio = <&tca6424a 16 GPIO_ACTIVE_HIGH>;
0084                 enable-active-high;
0085                 /*
0086                  * This must be always-on for da7212, which has some not
0087                  * properly documented dependencies for it's speaker supply
0088                  * pin. The issue manifests as speaker volume being very low.
0089                  */
0090                 regulator-always-on;
0091         };
0092 
0093 
0094         reg_3v3_audio: regulator-3v3-audio {
0095                 compatible = "regulator-fixed";
0096                 regulator-name = "3V3_AUDIO";
0097                 regulator-min-microvolt = <3300000>;
0098                 regulator-max-microvolt = <3300000>;
0099                 vin-supply = <&reg_3v3>;
0100                 pinctrl-0 = <&pinctrl_q7_hda_reset>;
0101                 pinctrl-names = "default";
0102                 gpio = <&gpio6 8 GPIO_ACTIVE_HIGH>;
0103                 enable-active-high;
0104         };
0105 
0106         reg_2v5_audio: regulator-2v5-audio {
0107                 compatible = "regulator-fixed";
0108                 regulator-name = "2V5_AUDIO";
0109                 regulator-min-microvolt = <2500000>;
0110                 regulator-max-microvolt = <2500000>;
0111                 regulator-always-on;
0112                 vin-supply = <&reg_3v3_audio>;
0113 
0114         };
0115 
0116         reg_wlan: regulator-wlan {
0117                 compatible = "regulator-fixed";
0118                 regulator-name = "WLAN";
0119                 regulator-min-microvolt = <3300000>;
0120                 regulator-max-microvolt = <3300000>;
0121                 vin-supply = <&reg_3v3>;
0122                 pinctrl-names = "default";
0123                 pinctrl-0 = <&pinctrl_q7_sdio_power>;
0124                 gpio = <&gpio4 30 GPIO_ACTIVE_HIGH>;
0125                 enable-active-high;
0126                 startup-delay-us = <70000>;
0127         };
0128 
0129         reg_bl: regulator-backlight {
0130                 compatible = "regulator-fixed";
0131                 regulator-name = "LED_VCC";
0132                 regulator-min-microvolt = <12000000>;
0133                 regulator-max-microvolt = <12000000>;
0134                 vin-supply = <&reg_syspwr>;
0135                 pinctrl-0 = <&pinctrl_q7_lcd_power>;
0136                 pinctrl-names = "default";
0137                 gpio = <&gpio1 7 GPIO_ACTIVE_HIGH>;
0138                 enable-active-high;
0139         };
0140 
0141         reg_lcd: regulator-lcd {
0142                 compatible = "regulator-fixed";
0143                 regulator-name = "LCD_5V";
0144                 regulator-min-microvolt = <5000000>;
0145                 regulator-max-microvolt = <5000000>;
0146                 vin-supply = <&reg_5v>;
0147         };
0148 
0149         usb_power: regulator-usb-power {
0150                 compatible = "regulator-fixed";
0151                 regulator-name = "USB POWER";
0152                 regulator-min-microvolt = <5000000>;
0153                 regulator-max-microvolt = <5000000>;
0154                 vin-supply = <&reg_5v>;
0155         };
0156 
0157         charger: battery-charger {
0158                 compatible = "gpio-charger"; /* ti,bq24172 */
0159                 charger-type = "mains";
0160                 gpios = <&tca6424a 3 GPIO_ACTIVE_LOW>;
0161                 charge-current-limit-gpios = <&tca6424a 11 GPIO_ACTIVE_HIGH>,
0162                                              <&tca6424a 12 GPIO_ACTIVE_HIGH>;
0163                 charge-current-limit-mapping = <1300000 0x0>,
0164                                                <700000 0x1>,
0165                                                <0 0x2>;
0166                 charge-status-gpios = <&tca6424a 6 GPIO_ACTIVE_HIGH>;
0167         };
0168 
0169         poweroff {
0170                 compatible = "gpio-poweroff";
0171                 pinctrl-names = "default";
0172                 pinctrl-0 = <&pinctrl_q7_spi_cs1>;
0173                 gpios = <&gpio4 25 GPIO_ACTIVE_LOW>;
0174         };
0175 
0176         power-button-key {
0177                 compatible = "gpio-keys";
0178                 pinctrl-names = "default";
0179                 pinctrl-0 = <&pinctrl_q7_sleep_button>;
0180 
0181                 power-button {
0182                         label = "power button";
0183                         gpios = <&gpio4 7 GPIO_ACTIVE_LOW>;
0184                         linux,code = <KEY_POWER>;
0185                 };
0186         };
0187 
0188         rotary-encoder-key {
0189                 compatible = "gpio-keys";
0190 
0191                 rotary-encoder-press {
0192                         label = "rotary-encoder press";
0193                         gpios = <&tca6424a 0 GPIO_ACTIVE_HIGH>;
0194                         linux,code = <KEY_ENTER>;
0195                         linux,can-disable;
0196                 };
0197         };
0198 
0199         rotary-encoder {
0200                 compatible = "rotary-encoder";
0201                 pinctrl-names = "default";
0202                 pinctrl-0 = <&pinctrl_q7_gpio2 &pinctrl_q7_gpio4>;
0203                 gpios = <&gpio4 26 GPIO_ACTIVE_LOW>, <&gpio1 0 GPIO_ACTIVE_LOW>;
0204                 rotary-encoder,relative-axis;
0205                 rotary-encoder,steps-per-period = <2>;
0206                 wakeup-source;
0207         };
0208 
0209         leds {
0210                 compatible = "gpio-leds";
0211                 pinctrl-names = "default";
0212                 pinctrl-0 = <&pinctrl_q7_gpio1 &pinctrl_q7_gpio3 &pinctrl_q7_gpio5>;
0213 
0214                 alarm1 {
0215                         label = "alarm:red";
0216                         gpios = <&gpio1 8 GPIO_ACTIVE_HIGH>;
0217                 };
0218 
0219                 alarm2 {
0220                         label = "alarm:yellow";
0221                         gpios = <&gpio4 27 GPIO_ACTIVE_HIGH>;
0222                 };
0223 
0224                 alarm3 {
0225                         label = "alarm:blue";
0226                         gpios = <&gpio4 15 GPIO_ACTIVE_HIGH>;
0227                 };
0228         };
0229 
0230         backlight: backlight {
0231                 compatible = "pwm-backlight";
0232                 pinctrl-names = "default";
0233                 pinctrl-0 = <&pinctrl_q7_backlight_enable>;
0234                 power-supply = <&reg_bl>;
0235                 pwms = <&pwm4 0 5000000 0>;
0236                 brightness-levels = <0 255>;
0237                 num-interpolated-steps = <255>;
0238                 default-brightness-level = <179>;
0239                 enable-gpios = <&gpio1 9 GPIO_ACTIVE_HIGH>;
0240         };
0241 
0242         panel {
0243                 backlight = <&backlight>;
0244                 power-supply = <&reg_lcd>;
0245 
0246                 port {
0247                         panel_in: endpoint {
0248                                 remote-endpoint = <&lvds0_out>;
0249                         };
0250                 };
0251         };
0252 
0253         sound {
0254                 compatible = "simple-audio-card";
0255                 simple-audio-card,name = "audio-card";
0256                 simple-audio-card,format = "i2s";
0257                 simple-audio-card,bitclock-master = <&dailink_master>;
0258                 simple-audio-card,frame-master = <&dailink_master>;
0259                 simple-audio-card,widgets = "Speaker", "Ext Spk";
0260                 simple-audio-card,audio-routing = "Ext Spk", "LINE";
0261 
0262                 simple-audio-card,cpu {
0263                         sound-dai = <&ssi1>;
0264                 };
0265 
0266                 dailink_master: simple-audio-card,codec {
0267                         sound-dai = <&codec>;
0268                 };
0269         };
0270 
0271         clk_ext_audio_codec: clock-codec {
0272                 compatible = "fixed-clock";
0273                 #clock-cells = <0>;
0274                 clock-frequency = <12288000>;
0275         };
0276 };
0277 
0278 &audmux {
0279         status = "okay";
0280 };
0281 
0282 &fec {
0283         status = "okay";
0284 };
0285 
0286 &hdmi {
0287         status = "okay";
0288 };
0289 
0290 &i2c1 {
0291         battery: battery@b {
0292                 compatible = "ti,bq20z65", "sbs,sbs-battery";
0293                 reg = <0x0b>;
0294                 sbs,battery-detect-gpios = <&tca6424a 5 GPIO_ACTIVE_LOW>;
0295                 sbs,i2c-retry-count = <5>;
0296                 power-supplies = <&charger>;
0297         };
0298 
0299         codec: audio-codec@1a {
0300                 compatible = "dlg,da7212";
0301                 reg = <0x1a>;
0302                 #sound-dai-cells = <0>;
0303                 VDDA-supply = <&reg_2v5_audio>;
0304                 VDDSP-supply = <&reg_5v0_audio>;
0305                 VDDMIC-supply = <&reg_3v3_audio>;
0306                 VDDIO-supply = <&reg_3v3_audio>;
0307                 clocks = <&clk_ext_audio_codec>;
0308                 clock-names = "mclk";
0309         };
0310 };
0311 
0312 &i2c5 {
0313         tca6424a: gpio-controller@22 {
0314                 compatible = "ti,tca6424";
0315                 reg = <0x22>;
0316                 gpio-controller;
0317                 #gpio-cells = <2>;
0318                 vcc-supply = <&reg_3v3>;
0319                 interrupt-parent = <&gpio7>;
0320                 interrupts = <11 IRQ_TYPE_LEVEL_LOW>;
0321                 pinctrl-names = "default";
0322                 pinctrl-0 = <&pinctrl_q7_gpio6>;
0323                 interrupt-controller;
0324                 #interrupt-cells = <2>;
0325                 gpio-line-names = "GPIO_ROTOR#", "ACM_IO_INT", "TMP_SENSOR_IRQ", "AC_IN",
0326                                   "TF_S", "BATT_T", "LED_INC_CHAR", "ACM1_OCF",
0327                                   "ACM2_OCF", "ACM_IO_RST", "USB1_POWER_EN", "EGPIO_CC_CTL0",
0328                                   "EGPIO_CC_CTL1", "12V_OEMNBP_EN", "CP2105_RST", "",
0329                                   "SPEAKER_PA_EN", "ARM7_UPI_RESET", "ARM7_PWR_RST", "NURSE_CALL",
0330                                   "MARKER_EN", "EGPIO_TOUCH_RST", "PRESSURE_INT1", "PRESSURE_INT2";
0331 
0332         };
0333 
0334         tmp75: temperature-sensor@48 {
0335                 compatible = "ti,tmp75";
0336                 reg = <0x48>;
0337                 vs-supply = <&reg_3v3>;
0338                 interrupt-parent = <&tca6424a>;
0339                 interrupts = <2 IRQ_TYPE_EDGE_FALLING>;
0340         };
0341 };
0342 
0343 &ldb {
0344         status = "okay";
0345 
0346         lvds0: lvds-channel@0 {
0347                 status = "okay";
0348                 fsl,data-mapping = "spwg";
0349                 fsl,data-width = <24>;
0350 
0351                 port@4 {
0352                         reg = <4>;
0353 
0354                         lvds0_out: endpoint {
0355                                 remote-endpoint = <&panel_in>;
0356                         };
0357                 };
0358         };
0359 };
0360 
0361 &pwm4 {
0362         status = "okay";
0363 };
0364 
0365 &ssi1 {
0366         fsl,mode = "i2s-slave";
0367         status = "okay";
0368 };
0369 
0370 &usbotg {
0371         vbus-supply = <&usb_power>;
0372         disable-over-current;
0373         dr_mode = "host";
0374         status = "okay";
0375 
0376         /*
0377          * TPS2051BDGN fault-gpio is connected to Q7[86] USB_0_1_OC_N.
0378          * On QMX6 this is not connceted to the i.MX6, but to the USB Hub
0379          * from &usbh1. This means, that we cannot easily detect and handle
0380          * over-current events. Fortunately the regulator limits the current
0381          * automatically, so the hardware is still protected.
0382          */
0383 };
0384 
0385 &usdhc4 {
0386         /* WiFi module */
0387         pinctrl-names = "default";
0388         pinctrl-0 = <&pinctrl_usdhc4>;
0389         bus-width = <4>;
0390         no-1-8-v;
0391         non-removable;
0392         wakeup-source;
0393         keep-power-in-suspend;
0394         cap-power-off-card;
0395         max-frequency = <25000000>;
0396         vmmc-supply = <&reg_wlan>;
0397         #address-cells = <1>;
0398         #size-cells = <0>;
0399         status = "okay";
0400 
0401         wlcore: wlcore@2 {
0402                 compatible = "ti,wl1837";
0403                 reg = <2>;
0404 
0405                 pinctrl-names = "default";
0406                 pinctrl-0 = <&pinctrl_q7_gpio7>;
0407 
0408                 interrupt-parent = <&gpio4>;
0409                 interrupts = <14 IRQ_TYPE_LEVEL_HIGH>;
0410 
0411                 tcxo-clock-frequency = <26000000>;
0412         };
0413 };