Skip to contentSkip to conversation

ASoC: rt5663: Add the function of impedance sensing

PATCH Superseded Oder Chiou 2 participants 2 messages Sep 11, 2017 – Sep 13, 2017

Subsystems (4)

v1 of 3 Superseded Latest is v3 →

lore
Share & tools
lore

Oder Chiou

author maintainer
#0 lore raw

PATCH 1/1 ASoC: rt5663: Add the function of impedance sensing

Support the function of impedance sensing. It could be set the range number and the related parameters in the DTS.

---
 Documentation/devicetree/bindings/sound/rt5663.txt |   4 +
 include/sound/rt5663.h                             |   3 +
 sound/soc/codecs/rt5663.c                          | 218 ++++++++++++++++++++-
 3 files changed, 221 insertions(+), 4 deletions(-)
Documentation/devicetree/bindings/sound/rt5663.txt +4 -0
index ff38171..4dcd181 100644
@@ -19,6 +19,10 @@ Optional properties:
   Based on the different PCB layout, add the manual offset value to
   compensate the DC offset for each L and R channel, and they are different
   between headphone and headset.
+- "realtek,impedance_sensing_num"
+  The range number of impedance sensing.
+- "realtek,impedance_sensing_table"
+  The parameters table of impedance sensing.
 
 Pins on the device (for linking into audio routes) for RT5663:
 
include/sound/rt5663.h +3 -0
index 7d00e58..7b90a8f 100644
@@ -16,6 +16,9 @@ struct rt5663_platform_data {
 	unsigned int dc_offset_r_manual;
 	unsigned int dc_offset_l_manual_mic;
 	unsigned int dc_offset_r_manual_mic;
+
+	unsigned int impedance_sensing_num;
+	unsigned int *impedance_sensing_table;
 };
 
 #endif
sound/soc/codecs/rt5663.c +214 -4

284 lines not on this page · raw message

Signature · 1 line
2.7.4
maintainer
#1 lore raw

Documentation/devicetree/bindings/sound/rt5663.txt Optional properties: · line 25

Quoted 4 lines · Oder Chiou

+- "realtek,impedance_sensing_num"

Documentation/devicetree/bindings/sound/rt5663.txt +3 -0
+  The range number of impedance sensing.
+- "realtek,impedance_sensing_table"
+  The parameters table of impedance sensing.

I really can't tell what format these are supposed to be in from this documentation. If the realtek,impedance_sensing_num is some number defined in the datasheet it's OK to just reference the datasheet, for the table you probably need a bit of detail on the format of the table and it's contents.