.. | .. |
---|
52 | 52 | |
---|
53 | 53 | /* Index (NID:20h) */ |
---|
54 | 54 | #define RT711_DAC_DC_CALI_CTL1 0x00 |
---|
| 55 | +#define RT711_JD_CTL1 0x08 |
---|
55 | 56 | #define RT711_JD_CTL2 0x09 |
---|
| 57 | +#define RT711_JD_CTL4 0x0b |
---|
56 | 58 | #define RT711_CC_DET1 0x11 |
---|
57 | 59 | #define RT711_PARA_VERB_CTL 0x1a |
---|
58 | 60 | #define RT711_COMBO_JACK_AUTO_CTL1 0x45 |
---|
.. | .. |
---|
171 | 173 | /* DAC DC offset calibration control-1 (0x00)(NID:20h) */ |
---|
172 | 174 | #define RT711_DAC_DC_CALI_TRIGGER (0x1 << 15) |
---|
173 | 175 | |
---|
| 176 | +/* jack detect control 1 (0x08)(NID:20h) */ |
---|
| 177 | +#define RT711_JD2_DIGITAL_JD_MODE_SEL (0x1 << 1) |
---|
| 178 | +#define RT711_JD2_1_JD_MODE (0x0 << 1) |
---|
| 179 | +#define RT711_JD2_2_JD_MODE (0x1 << 1) |
---|
| 180 | + |
---|
174 | 181 | /* jack detect control 2 (0x09)(NID:20h) */ |
---|
175 | 182 | #define RT711_JD2_2PORT_200K_DECODE_HP (0x1 << 13) |
---|
| 183 | +#define RT711_JD2_2PORT_100K_DECODE (0x1 << 12) |
---|
| 184 | +#define RT711_JD2_2PORT_100K_DECODE_HP (0x0 << 12) |
---|
176 | 185 | #define RT711_HP_JD_SEL_JD1 (0x0 << 1) |
---|
177 | 186 | #define RT711_HP_JD_SEL_JD2 (0x1 << 1) |
---|
| 187 | +#define RT711_JD2_1PORT_TYPE_DECODE (0x3 << 10) |
---|
| 188 | +#define RT711_JD2_1PORT_JD_LINE2 (0x0 << 10) |
---|
| 189 | +#define RT711_JD2_1PORT_JD_HP (0x1 << 10) |
---|
| 190 | +#define RT711_JD2_1PORT_JD_LINE1 (0x2 << 10) |
---|
| 191 | +#define RT711_JD1_2PORT_TYPE_100K_DECODE (0x1 << 0) |
---|
| 192 | +#define RT711_JD1_2PORT_JD_RESERVED (0x0 << 0) |
---|
| 193 | +#define RT711_JD1_2PORT_JD_LINE1 (0x1 << 0) |
---|
| 194 | + |
---|
| 195 | +/* jack detect control 4 (0x0b)(NID:20h) */ |
---|
| 196 | +#define RT711_JD2_PAD_PULL_UP_MASK (0x1 << 3) |
---|
| 197 | +#define RT711_JD2_PAD_NOT_PULL_UP (0x0 << 3) |
---|
| 198 | +#define RT711_JD2_PAD_PULL_UP (0x1 << 3) |
---|
| 199 | +#define RT711_JD2_MODE_SEL_MASK (0x3 << 0) |
---|
| 200 | +#define RT711_JD2_MODE0_2PORT (0x0 << 0) |
---|
| 201 | +#define RT711_JD2_MODE1_3P3V_1PORT (0x1 << 0) |
---|
| 202 | +#define RT711_JD2_MODE2_1P8V_1PORT (0x2 << 0) |
---|
178 | 203 | |
---|
179 | 204 | /* CC DET1 (0x11)(NID:20h) */ |
---|
180 | 205 | #define RT711_HP_JD_FINAL_RESULT_CTL_JD12 (0x1 << 10) |
---|
.. | .. |
---|
215 | 240 | enum rt711_jd_src { |
---|
216 | 241 | RT711_JD_NULL, |
---|
217 | 242 | RT711_JD1, |
---|
218 | | - RT711_JD2 |
---|
| 243 | + RT711_JD2, |
---|
| 244 | + RT711_JD2_100K, |
---|
| 245 | + RT711_JD2_1P8V_1PORT |
---|
219 | 246 | }; |
---|
220 | 247 | |
---|
221 | 248 | int rt711_io_init(struct device *dev, struct sdw_slave *slave); |
---|