Fix sound on headset jack for ALC255 and ALC256 codec.

PR:		219350 [1], [2]
Submitted by:	Masachika ISHIZUKA (ish_at_amail.plala.or.jp) [1]
		Neel Chauhan (neel_at_neelc.org) [2]
		uri Momotyuk (yurkis_at_gmail.com) [3]
Reported by:	miwi
Reviewed by:	mav
Obtained from:	https://github.com/trueos/trueos/pull/279 [3]
MFC after:	2 weeks
Differential Revision:	https://reviews.freebsd.org/D19017
This commit is contained in:
Marcelo Araujo 2019-07-30 02:01:49 +00:00
parent 36d7818975
commit 145b1792a2
Notes: svn2git 2020-12-20 02:59:44 +00:00
svn path=/head/; revision=350433
2 changed files with 16 additions and 2 deletions

View File

@ -425,10 +425,19 @@ hdac_pin_patch(struct hdaa_widget *w)
} else if (id == HDA_CODEC_ALC298 && subid == DELL_XPS9560_SUBVENDOR) {
switch (nid) {
case 24:
config = 0x01a1913c;
config = 0x01a1913c;
break;
case 26:
config = 0x01a1913d;
config = 0x01a1913d;
break;
}
} else if (id == HDA_CODEC_ALC256 && subid == DELL_I7577_SUBVENDOR ) {
switch (nid) {
case 20:
patch = "as=1 seq=0";
break;
case 33:
patch = "as=1 seq=15";
break;
}
}
@ -769,6 +778,10 @@ hdaa_patch_direct(struct hdaa_devinfo *devinfo)
}
break;
}
if (id == HDA_CODEC_ALC255 || id == HDA_CODEC_ALC256) {
val = hdaa_read_coef(dev, 0x20, 0x46);
hdaa_write_coef(dev, 0x20, 0x46, val|0x3000);
}
if (subid == APPLE_INTEL_MAC)
hda_command(dev, HDA_CMD_12BIT(0, devinfo->nid,
0x7e7, 0));

View File

@ -203,6 +203,7 @@
#define DELL_XPSM1210_SUBVENDOR HDA_MODEL_CONSTRUCT(DELL, 0x01d7)
#define DELL_OPLX745_SUBVENDOR HDA_MODEL_CONSTRUCT(DELL, 0x01da)
#define DELL_XPS9560_SUBVENDOR HDA_MODEL_CONSTRUCT(DELL, 0x07be)
#define DELL_I7577_SUBVENDOR HDA_MODEL_CONSTRUCT(DELL, 0x0802)
#define DELL_ALL_SUBVENDOR HDA_MODEL_CONSTRUCT(DELL, 0xffff)
/* Clevo */