1CS42L42 audio CODEC 2 3Required properties: 4 5 - compatible : "cirrus,cs42l42" 6 7 - reg : the I2C address of the device for I2C. 8 9 - VP-supply, VCP-supply, VD_FILT-supply, VL-supply, VA-supply : 10 power supplies for the device, as covered in 11 Documentation/devicetree/bindings/regulator/regulator.txt. 12 13Optional properties: 14 15 - reset-gpios : a GPIO spec for the reset pin. If specified, it will be 16 deasserted before communication to the codec starts. 17 18 - interrupts : IRQ line info CS42L42. 19 (See Documentation/devicetree/bindings/interrupt-controller/interrupts.txt 20 for further information relating to interrupt properties) 21 22 - cirrus,ts-inv : Boolean property. For jacks that invert the tip sense 23 polarity. Normal jacks will short tip sense pin to HS1 when headphones are 24 plugged in and leave tip sense floating when not plugged in. Inverting jacks 25 short tip sense when unplugged and float when plugged in. 26 27 0 = (Default) Non-inverted 28 1 = Inverted 29 30 - cirrus,ts-dbnc-rise : Debounce the rising edge of TIP_SENSE_PLUG. With no 31 debounce, the tip sense pin might be noisy on a plug event. 32 33 0 - 0ms, 34 1 - 125ms, 35 2 - 250ms, 36 3 - 500ms, 37 4 - 750ms, 38 5 - (Default) 1s, 39 6 - 1.25s, 40 7 - 1.5s, 41 42 - cirrus,ts-dbnc-fall : Debounce the falling edge of TIP_SENSE_UNPLUG. 43 With no debounce, the tip sense pin might be noisy on an unplug event. 44 45 0 - 0ms, 46 1 - 125ms, 47 2 - 250ms, 48 3 - 500ms, 49 4 - 750ms, 50 5 - (Default) 1s, 51 6 - 1.25s, 52 7 - 1.5s, 53 54 - cirrus,btn-det-init-dbnce : This sets how long the driver sleeps after 55 enabling button detection interrupts. After auto-detection and before 56 servicing button interrupts, the HS bias needs time to settle. If you 57 don't wait, there is possibility for erroneous button interrupt. 58 59 0ms - 200ms, 60 Default = 100ms 61 62 - cirrus,btn-det-event-dbnce : This sets how long the driver delays after 63 receiving a button press interrupt. With level detect interrupts, you want 64 to wait a small amount of time to make sure the button press is making a 65 clean connection with the bias resistors. 66 67 0ms - 20ms, 68 Default = 10ms 69 70 - cirrus,bias-lvls : For a level-detect headset button scheme, each button 71 will bias the mic pin to a certain voltage. To determine which button was 72 pressed, the driver will compare this biased voltage to sequential, 73 decreasing voltages and will stop when a comparator is tripped, 74 indicating a comparator voltage < bias voltage. This value represents a 75 percentage of the internally generated HS bias voltage. For different 76 hardware setups, a designer might want to tweak this. This is an array of 77 descending values for the comparator voltage. 78 79 Array of 4 values 80 Each 0-63 81 < x1 x2 x3 x4 > 82 Default = < 15 8 4 1> 83 84 - cirrus,hs-bias-sense-disable: This is boolean property. If present the 85 HSBIAS sense is disabled. Configures HSBIAS output current sense through 86 the external 2.21-k resistor. HSBIAS_SENSE is hardware feature to reduce 87 the potential pop noise during the headset plug out slowly. But on some 88 platforms ESD voltage will affect it causing test to fail, especially 89 with CTIA headset type. For different hardware setups, a designer might 90 want to tweak default behavior. 91 92Example: 93 94cs42l42: cs42l42@48 { 95 compatible = "cirrus,cs42l42"; 96 reg = <0x48>; 97 VA-supply = <&dummy_vreg>; 98 VP-supply = <&dummy_vreg>; 99 VCP-supply = <&dummy_vreg>; 100 VD_FILT-supply = <&dummy_vreg>; 101 VL-supply = <&dummy_vreg>; 102 103 reset-gpios = <&axi_gpio_0 1 0>; 104 interrupt-parent = <&gpio0>; 105 interrupts = <55 8> 106 107 cirrus,ts-inv = <0x00>; 108 cirrus,ts-dbnc-rise = <0x05>; 109 cirrus,ts-dbnc-fall = <0x00>; 110 cirrus,btn-det-init-dbnce = <100>; 111 cirrus,btn-det-event-dbnce = <10>; 112 cirrus,bias-lvls = <0x0F 0x08 0x04 0x01>; 113 cirrus,hs-bias-ramp-rate = <0x02>; 114}; 115