Anatol Pomozov | f9f6a59 | 2014-09-17 13:14:20 -0700 | [diff] [blame] | 1 | RT5677 audio CODEC |
| 2 | |
| 3 | This device supports I2C only. |
| 4 | |
| 5 | Required properties: |
| 6 | |
| 7 | - compatible : "realtek,rt5677". |
| 8 | |
| 9 | - reg : The I2C address of the device. |
| 10 | |
| 11 | - interrupts : The CODEC's interrupt output. |
| 12 | |
Anatol Pomozov | 0e612ff | 2014-09-24 11:31:58 -0700 | [diff] [blame] | 13 | - gpio-controller : Indicates this device is a GPIO controller. |
| 14 | |
| 15 | - #gpio-cells : Should be two. The first cell is the pin number and the |
| 16 | second cell is used to specify optional parameters (currently unused). |
| 17 | |
Anatol Pomozov | f9f6a59 | 2014-09-17 13:14:20 -0700 | [diff] [blame] | 18 | Optional properties: |
| 19 | |
| 20 | - realtek,pow-ldo2-gpio : The GPIO that controls the CODEC's POW_LDO2 pin. |
Anatol Pomozov | cdab0d4 | 2015-10-29 15:31:59 -0700 | [diff] [blame] | 21 | - realtek,reset-gpio : The GPIO that controls the CODEC's RESET pin. Active low. |
Anatol Pomozov | f9f6a59 | 2014-09-17 13:14:20 -0700 | [diff] [blame] | 22 | |
Anatol Pomozov | 6f67c38 | 2014-09-26 09:57:27 -0700 | [diff] [blame] | 23 | - realtek,in1-differential |
| 24 | - realtek,in2-differential |
| 25 | - realtek,lout1-differential |
| 26 | - realtek,lout2-differential |
| 27 | - realtek,lout3-differential |
| 28 | Boolean. Indicate MIC1/2 input and LOUT1/2/3 outputs are differential, |
| 29 | rather than single-ended. |
| 30 | |
Anatol Pomozov | 40eb90a | 2014-10-10 20:46:36 -0700 | [diff] [blame] | 31 | - realtek,gpio-config |
| 32 | Array of six 8bit elements that configures GPIO. |
| 33 | 0 - floating (reset value) |
| 34 | 1 - pull down |
| 35 | 2 - pull up |
| 36 | |
Oder Chiou | 5e3363a | 2014-10-16 11:24:26 -0700 | [diff] [blame] | 37 | - realtek,jd1-gpio |
| 38 | Configures GPIO Mic Jack detection 1. |
| 39 | Select 0 ~ 3 as OFF, GPIO1, GPIO2 and GPIO3 respectively. |
| 40 | |
| 41 | - realtek,jd2-gpio |
| 42 | - realtek,jd3-gpio |
| 43 | Configures GPIO Mic Jack detection 2 and 3. |
| 44 | Select 0 ~ 3 as OFF, GPIO4, GPIO5 and GPIO6 respectively. |
| 45 | |
Anatol Pomozov | f9f6a59 | 2014-09-17 13:14:20 -0700 | [diff] [blame] | 46 | Pins on the device (for linking into audio routes): |
| 47 | |
| 48 | * IN1P |
| 49 | * IN1N |
| 50 | * IN2P |
| 51 | * IN2N |
| 52 | * MICBIAS1 |
| 53 | * DMIC1 |
| 54 | * DMIC2 |
| 55 | * DMIC3 |
| 56 | * DMIC4 |
| 57 | * LOUT1 |
| 58 | * LOUT2 |
| 59 | * LOUT3 |
| 60 | |
| 61 | Example: |
| 62 | |
| 63 | rt5677 { |
| 64 | compatible = "realtek,rt5677"; |
| 65 | reg = <0x2c>; |
| 66 | interrupt-parent = <&gpio>; |
| 67 | interrupts = <TEGRA_GPIO(W, 3) GPIO_ACTIVE_HIGH>; |
Anatol Pomozov | 0e612ff | 2014-09-24 11:31:58 -0700 | [diff] [blame] | 68 | |
| 69 | gpio-controller; |
| 70 | #gpio-cells = <2>; |
| 71 | |
Anatol Pomozov | f9f6a59 | 2014-09-17 13:14:20 -0700 | [diff] [blame] | 72 | realtek,pow-ldo2-gpio = |
| 73 | <&gpio TEGRA_GPIO(V, 3) GPIO_ACTIVE_HIGH>; |
Anatol Pomozov | b3b10e9 | 2015-05-13 08:25:15 -0700 | [diff] [blame] | 74 | realtek,reset-gpio = <&gpio TEGRA_GPIO(BB, 3) GPIO_ACTIVE_LOW>; |
Anatol Pomozov | 6f67c38 | 2014-09-26 09:57:27 -0700 | [diff] [blame] | 75 | realtek,in1-differential = "true"; |
Anatol Pomozov | 40eb90a | 2014-10-10 20:46:36 -0700 | [diff] [blame] | 76 | realtek,gpio-config = /bits/ 8 <0 0 0 0 0 2>; /* pull up GPIO6 */ |
Oder Chiou | 5e3363a | 2014-10-16 11:24:26 -0700 | [diff] [blame] | 77 | realtek,jd2-gpio = <3>; /* Enables Jack detection for GPIO6 */ |
Anatol Pomozov | f9f6a59 | 2014-09-17 13:14:20 -0700 | [diff] [blame] | 78 | }; |