1*724ba675SRob Herring// SPDX-License-Identifier: GPL-2.0 2*724ba675SRob Herring/* 3*724ba675SRob Herring * Google Veyron (and derivatives) fragment for the max98090 audio 4*724ba675SRob Herring * codec and analog headphone jack. 5*724ba675SRob Herring * 6*724ba675SRob Herring * Copyright 2016 Google, Inc 7*724ba675SRob Herring */ 8*724ba675SRob Herring 9*724ba675SRob Herring/ { 10*724ba675SRob Herring sound { 11*724ba675SRob Herring compatible = "rockchip,rockchip-audio-max98090"; 12*724ba675SRob Herring pinctrl-names = "default"; 13*724ba675SRob Herring pinctrl-0 = <&mic_det>, <&hp_det>; 14*724ba675SRob Herring rockchip,model = "VEYRON-I2S"; 15*724ba675SRob Herring rockchip,i2s-controller = <&i2s>; 16*724ba675SRob Herring rockchip,audio-codec = <&max98090>; 17*724ba675SRob Herring rockchip,hp-det-gpios = <&gpio6 RK_PA5 GPIO_ACTIVE_HIGH>; 18*724ba675SRob Herring rockchip,mic-det-gpios = <&gpio6 RK_PB3 GPIO_ACTIVE_LOW>; 19*724ba675SRob Herring rockchip,headset-codec = <&headsetcodec>; 20*724ba675SRob Herring rockchip,hdmi-codec = <&hdmi>; 21*724ba675SRob Herring }; 22*724ba675SRob Herring}; 23*724ba675SRob Herring 24*724ba675SRob Herring&i2c2 { 25*724ba675SRob Herring max98090: max98090@10 { 26*724ba675SRob Herring compatible = "maxim,max98090"; 27*724ba675SRob Herring reg = <0x10>; 28*724ba675SRob Herring interrupt-parent = <&gpio6>; 29*724ba675SRob Herring interrupts = <RK_PA7 IRQ_TYPE_EDGE_FALLING>; 30*724ba675SRob Herring clock-names = "mclk"; 31*724ba675SRob Herring clocks = <&cru SCLK_I2S0_OUT>; 32*724ba675SRob Herring pinctrl-names = "default"; 33*724ba675SRob Herring pinctrl-0 = <&int_codec>; 34*724ba675SRob Herring }; 35*724ba675SRob Herring}; 36*724ba675SRob Herring 37*724ba675SRob Herring&i2c4 { 38*724ba675SRob Herring headsetcodec: ts3a227e@3b { 39*724ba675SRob Herring compatible = "ti,ts3a227e"; 40*724ba675SRob Herring reg = <0x3b>; 41*724ba675SRob Herring interrupt-parent = <&gpio0>; 42*724ba675SRob Herring interrupts = <RK_PA3 IRQ_TYPE_LEVEL_LOW>; 43*724ba675SRob Herring pinctrl-names = "default"; 44*724ba675SRob Herring pinctrl-0 = <&ts3a227e_int_l>; 45*724ba675SRob Herring ti,micbias = <7>; /* MICBIAS = 2.8V */ 46*724ba675SRob Herring }; 47*724ba675SRob Herring}; 48*724ba675SRob Herring 49*724ba675SRob Herring&i2s { 50*724ba675SRob Herring status = "okay"; 51*724ba675SRob Herring}; 52*724ba675SRob Herring 53*724ba675SRob Herring&io_domains { 54*724ba675SRob Herring audio-supply = <&vcc18_codec>; 55*724ba675SRob Herring}; 56*724ba675SRob Herring 57*724ba675SRob Herring&rk808 { 58*724ba675SRob Herring vcc10-supply = <&vcc33_sys>; 59*724ba675SRob Herring 60*724ba675SRob Herring regulators { 61*724ba675SRob Herring vcc18_codec: LDO_REG6 { 62*724ba675SRob Herring regulator-name = "vcc18_codec"; 63*724ba675SRob Herring regulator-always-on; 64*724ba675SRob Herring regulator-boot-on; 65*724ba675SRob Herring regulator-min-microvolt = <1800000>; 66*724ba675SRob Herring regulator-max-microvolt = <1800000>; 67*724ba675SRob Herring regulator-state-mem { 68*724ba675SRob Herring regulator-off-in-suspend; 69*724ba675SRob Herring }; 70*724ba675SRob Herring }; 71*724ba675SRob Herring }; 72*724ba675SRob Herring}; 73*724ba675SRob Herring 74*724ba675SRob Herring&pinctrl { 75*724ba675SRob Herring codec { 76*724ba675SRob Herring hp_det: hp-det { 77*724ba675SRob Herring rockchip,pins = <6 RK_PA5 RK_FUNC_GPIO &pcfg_pull_up>; 78*724ba675SRob Herring }; 79*724ba675SRob Herring 80*724ba675SRob Herring /* 81*724ba675SRob Herring * HACK: We're going to _pull down_ this _active low_ interrupt 82*724ba675SRob Herring * so that it never fires. We don't need this interrupt because 83*724ba675SRob Herring * we've got a ts3a227e chip but the driver requires it. 84*724ba675SRob Herring */ 85*724ba675SRob Herring int_codec: int-codec { 86*724ba675SRob Herring rockchip,pins = <6 RK_PA7 RK_FUNC_GPIO &pcfg_pull_down>; 87*724ba675SRob Herring }; 88*724ba675SRob Herring 89*724ba675SRob Herring mic_det: mic-det { 90*724ba675SRob Herring rockchip,pins = <6 RK_PB3 RK_FUNC_GPIO &pcfg_pull_up>; 91*724ba675SRob Herring }; 92*724ba675SRob Herring }; 93*724ba675SRob Herring 94*724ba675SRob Herring headset { 95*724ba675SRob Herring ts3a227e_int_l: ts3a227e-int-l { 96*724ba675SRob Herring rockchip,pins = <0 RK_PA3 RK_FUNC_GPIO &pcfg_pull_up>; 97*724ba675SRob Herring }; 98*724ba675SRob Herring }; 99*724ba675SRob Herring}; 100