1c66ec88fSEmmanuel VadotRT5640/RT5639 audio CODEC 2c66ec88fSEmmanuel Vadot 3c66ec88fSEmmanuel VadotThis device supports I2C only. 4c66ec88fSEmmanuel Vadot 5c66ec88fSEmmanuel VadotRequired properties: 6c66ec88fSEmmanuel Vadot 7c66ec88fSEmmanuel Vadot- compatible : One of "realtek,rt5640" or "realtek,rt5639". 8c66ec88fSEmmanuel Vadot 9c66ec88fSEmmanuel Vadot- reg : The I2C address of the device. 10c66ec88fSEmmanuel Vadot 11c66ec88fSEmmanuel Vadot- interrupts : The CODEC's interrupt output. 12c66ec88fSEmmanuel Vadot 13c66ec88fSEmmanuel VadotOptional properties: 14c66ec88fSEmmanuel Vadot 15c66ec88fSEmmanuel Vadot- clocks: The phandle of the master clock to the CODEC 16c66ec88fSEmmanuel Vadot- clock-names: Should be "mclk" 17c66ec88fSEmmanuel Vadot 18c66ec88fSEmmanuel Vadot- realtek,in1-differential 19c66ec88fSEmmanuel Vadot- realtek,in2-differential 20c66ec88fSEmmanuel Vadot- realtek,in3-differential 21c66ec88fSEmmanuel Vadot Boolean. Indicate MIC1/2/3 input are differential, rather than single-ended. 22c66ec88fSEmmanuel Vadot 23*cb7aa33aSEmmanuel Vadot- realtek,lout-differential 24*cb7aa33aSEmmanuel Vadot Boolean. Indicate LOUT output is differential, rather than stereo. 25*cb7aa33aSEmmanuel Vadot 26c66ec88fSEmmanuel Vadot- realtek,ldo1-en-gpios : The GPIO that controls the CODEC's LDO1_EN pin. 27c66ec88fSEmmanuel Vadot 28c66ec88fSEmmanuel Vadot- realtek,dmic1-data-pin 29c66ec88fSEmmanuel Vadot 0: dmic1 is not used 30c66ec88fSEmmanuel Vadot 1: using IN1P pin as dmic1 data pin 31c66ec88fSEmmanuel Vadot 2: using GPIO3 pin as dmic1 data pin 32c66ec88fSEmmanuel Vadot 33c66ec88fSEmmanuel Vadot- realtek,dmic2-data-pin 34c66ec88fSEmmanuel Vadot 0: dmic2 is not used 35c66ec88fSEmmanuel Vadot 1: using IN1N pin as dmic2 data pin 36c66ec88fSEmmanuel Vadot 2: using GPIO4 pin as dmic2 data pin 37c66ec88fSEmmanuel Vadot 38c66ec88fSEmmanuel Vadot- realtek,jack-detect-source 39c66ec88fSEmmanuel Vadot u32. Valid values: 40c66ec88fSEmmanuel Vadot 0: jack-detect is not used 41c66ec88fSEmmanuel Vadot 1: Use GPIO1 for jack-detect 42c66ec88fSEmmanuel Vadot 2: Use JD1_IN4P for jack-detect 43c66ec88fSEmmanuel Vadot 3: Use JD2_IN4N for jack-detect 44c66ec88fSEmmanuel Vadot 4: Use GPIO2 for jack-detect 45c66ec88fSEmmanuel Vadot 5: Use GPIO3 for jack-detect 46c66ec88fSEmmanuel Vadot 6: Use GPIO4 for jack-detect 47c66ec88fSEmmanuel Vadot 48c66ec88fSEmmanuel Vadot- realtek,jack-detect-not-inverted 49c66ec88fSEmmanuel Vadot bool. Normal jack-detect switches give an inverted signal, set this bool 50c66ec88fSEmmanuel Vadot in the rare case you've a jack-detect switch which is not inverted. 51c66ec88fSEmmanuel Vadot 52c66ec88fSEmmanuel Vadot- realtek,over-current-threshold-microamp 53c66ec88fSEmmanuel Vadot u32, micbias over-current detection threshold in µA, valid values are 54c66ec88fSEmmanuel Vadot 600, 1500 and 2000µA. 55c66ec88fSEmmanuel Vadot 56c66ec88fSEmmanuel Vadot- realtek,over-current-scale-factor 57c66ec88fSEmmanuel Vadot u32, micbias over-current detection scale-factor, valid values are: 58c66ec88fSEmmanuel Vadot 0: Scale current by 0.5 59c66ec88fSEmmanuel Vadot 1: Scale current by 0.75 60c66ec88fSEmmanuel Vadot 2: Scale current by 1.0 61c66ec88fSEmmanuel Vadot 3: Scale current by 1.5 62c66ec88fSEmmanuel Vadot 63c66ec88fSEmmanuel VadotPins on the device (for linking into audio routes) for RT5639/RT5640: 64c66ec88fSEmmanuel Vadot 65c66ec88fSEmmanuel Vadot * DMIC1 66c66ec88fSEmmanuel Vadot * DMIC2 67c66ec88fSEmmanuel Vadot * MICBIAS1 68c66ec88fSEmmanuel Vadot * IN1P 69c66ec88fSEmmanuel Vadot * IN1N 70c66ec88fSEmmanuel Vadot * IN2P 71c66ec88fSEmmanuel Vadot * IN2N 72c66ec88fSEmmanuel Vadot * IN3P 73c66ec88fSEmmanuel Vadot * IN3N 74c66ec88fSEmmanuel Vadot * HPOL 75c66ec88fSEmmanuel Vadot * HPOR 76c66ec88fSEmmanuel Vadot * LOUTL 77c66ec88fSEmmanuel Vadot * LOUTR 78c66ec88fSEmmanuel Vadot * SPOLP 79c66ec88fSEmmanuel Vadot * SPOLN 80c66ec88fSEmmanuel Vadot * SPORP 81c66ec88fSEmmanuel Vadot * SPORN 82c66ec88fSEmmanuel Vadot 83c66ec88fSEmmanuel VadotAdditional pins on the device for RT5640: 84c66ec88fSEmmanuel Vadot 85c66ec88fSEmmanuel Vadot * MONOP 86c66ec88fSEmmanuel Vadot * MONON 87c66ec88fSEmmanuel Vadot 88c66ec88fSEmmanuel VadotExample: 89c66ec88fSEmmanuel Vadot 90c66ec88fSEmmanuel Vadotrt5640 { 91c66ec88fSEmmanuel Vadot compatible = "realtek,rt5640"; 92c66ec88fSEmmanuel Vadot reg = <0x1c>; 93c66ec88fSEmmanuel Vadot interrupt-parent = <&gpio>; 946be33864SEmmanuel Vadot interrupts = <TEGRA_GPIO(W, 3) IRQ_TYPE_LEVEL_HIGH>; 95c66ec88fSEmmanuel Vadot realtek,ldo1-en-gpios = 96c66ec88fSEmmanuel Vadot <&gpio TEGRA_GPIO(V, 3) GPIO_ACTIVE_HIGH>; 97c66ec88fSEmmanuel Vadot}; 98