alsa-devel.alsa-project.org archive mirror
 help / color / mirror / Atom feed
* Re: [PATCH 15/19] drm/i915: HSW cdclk support
       [not found]                 ` <1428586886.3155.5.camel@sorvi>
@ 2015-04-09 13:51                   ` Daniel Vetter
  2015-04-09 15:17                     ` Takashi Iwai
  0 siblings, 1 reply; 6+ messages in thread
From: Daniel Vetter @ 2015-04-09 13:51 UTC (permalink / raw)
  To: Mika Kahola; +Cc: alsa-devel, Takashi Iwai, intel-gfx

On Thu, Apr 09, 2015 at 04:41:26PM +0300, Mika Kahola wrote:
> On Thu, 2015-04-09 at 11:32 +0200, Daniel Vetter wrote:
> > On Thu, Apr 09, 2015 at 10:24:24AM +0300, Mika Kahola wrote:
> > > I did some testing on audio part with HDMI-HDMI and DP-HDMI cables
> > > connected to my Haswell box. Before applying the patch I tested as a
> > > reference with the latest -nightly (04-08-2015), 4.0-rc7. Unfortunately,
> > > I failed to get any audio over HDMI cable. For a reference I tested with
> > > the very same setup the vanillla kernel from Linus tree 4.0-rc7 and with
> > > that kernel the audio worked ok. Then I did some GIT bisecting and it
> > > turned out that the first commit that I failed to get audio working was
> > > aa2fee4286e43b4784982b17669b02cc99c1ae55.
> > 
> I rerun the bisecting and this time the result was
> 
> commit 0a599838737a2527c35e4d94f794aefe59df1781
> Merge: 2d846c7 a59d719
> Author: Takashi Iwai <tiwai@suse.de>
> Date:   Wed Apr 8 11:29:56 2015 +0200
> 
>     Merge branch 'for-linus' into for-next
>     
>     Back merge HD-audio quirks to for-next branch, so that we can apply
>     a couple of more quirks.
>     
>     Signed-off-by: Takashi Iwai <tiwai@suse.de>

Adding Takashi and intel audio folks.
-Daniel

> 
> > I don't have this sha1 anywhere. Can you please double-check?
> > 
> > Also to avoid such issues please always add at least the commit subject
> > and author, so that I can find it if it's somehow rebased.
> > -Daniel
> > 
> > > 
> > > To test this patch audio functionality I checkout the -nightly version
> > > that works for me and apply the patch and test it. I'll come back with
> > > the results later on. 
> > > 
> > > I had the module option i915.disable_power_well=0
> > > 
> > > The test routine that I used for audio testing was
> > > speaker-test -c 2 -r 48000 -f S16_LE -t pink --device=plughw:0,3
> > > 
> > > On Tue, 2015-04-07 at 15:52 +0200, Daniel Vetter wrote:
> > > > On Tue, Apr 07, 2015 at 12:29:25PM +0300, Mika Kahola wrote:
> > > > > Definitely a good idea to check the audio part as well if there is
> > > > > a doubt that by changing CD clock the audio would fail. I can check
> > > > > this and I'll get back once I have the results.
> > > > 
> > > > We force a full modeset, which should result in an interrupt on the audio
> > > > side, which should result in the audio driver re-reading the current
> > > > cdclk. If that's no the case it's buggy already.
> > > > -Daniel
> > > 
> > > -- 
> > > Mika Kahola, Intel OTC
> > > 
> > > 
> > > 
> > 
> 
> -- 
> Mika Kahola, Intel OTC
> 
> 
> 

-- 
Daniel Vetter
Software Engineer, Intel Corporation
http://blog.ffwll.ch
_______________________________________________
Intel-gfx mailing list
Intel-gfx@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/intel-gfx

^ permalink raw reply	[flat|nested] 6+ messages in thread

* Re: [PATCH 15/19] drm/i915: HSW cdclk support
  2015-04-09 13:51                   ` [PATCH 15/19] drm/i915: HSW cdclk support Daniel Vetter
@ 2015-04-09 15:17                     ` Takashi Iwai
  2015-04-10 13:27                       ` Mika Kahola
  0 siblings, 1 reply; 6+ messages in thread
From: Takashi Iwai @ 2015-04-09 15:17 UTC (permalink / raw)
  To: Daniel Vetter; +Cc: intel-gfx, alsa-devel

At Thu, 9 Apr 2015 15:51:27 +0200,
Daniel Vetter wrote:
> 
> On Thu, Apr 09, 2015 at 04:41:26PM +0300, Mika Kahola wrote:
> > On Thu, 2015-04-09 at 11:32 +0200, Daniel Vetter wrote:
> > > On Thu, Apr 09, 2015 at 10:24:24AM +0300, Mika Kahola wrote:
> > > > I did some testing on audio part with HDMI-HDMI and DP-HDMI cables
> > > > connected to my Haswell box. Before applying the patch I tested as a
> > > > reference with the latest -nightly (04-08-2015), 4.0-rc7. Unfortunately,
> > > > I failed to get any audio over HDMI cable. For a reference I tested with
> > > > the very same setup the vanillla kernel from Linus tree 4.0-rc7 and with
> > > > that kernel the audio worked ok. Then I did some GIT bisecting and it
> > > > turned out that the first commit that I failed to get audio working was
> > > > aa2fee4286e43b4784982b17669b02cc99c1ae55.
> > > 
> > I rerun the bisecting and this time the result was
> > 
> > commit 0a599838737a2527c35e4d94f794aefe59df1781
> > Merge: 2d846c7 a59d719
> > Author: Takashi Iwai <tiwai@suse.de>
> > Date:   Wed Apr 8 11:29:56 2015 +0200
> > 
> >     Merge branch 'for-linus' into for-next
> >     
> >     Back merge HD-audio quirks to for-next branch, so that we can apply
> >     a couple of more quirks.
> >     
> >     Signed-off-by: Takashi Iwai <tiwai@suse.de>
> 
> Adding Takashi and intel audio folks.

The bisecting looks odd.  The commit you pointed is a back-merge from
4.0-rc to next branch, so this merge itself shouldn't bring so many
stuff -- at least about the sound part.

The diff in sound/* is found below.  As you can see, the only change
relevant with HDMI is the chunk in sound/pci/hda/hda_intel.c for
HD-audio controller, but it's specific to Skylake, thus this must be
irrelevant with your hardware.

Please double-check.


thanks,

Takashi

===
% git diff 0a599838737a2527c35e4d94f794aefe59df1781^..0a599838737a2527c35e4d94f794aefe59df1781 sound
diff --git a/sound/pci/hda/hda_intel.c b/sound/pci/hda/hda_intel.c
index 9bcc5457a83e..e1c210515581 100644
--- a/sound/pci/hda/hda_intel.c
+++ b/sound/pci/hda/hda_intel.c
@@ -1967,7 +1967,7 @@ static const struct pci_device_id azx_ids[] = {
 	  .driver_data = AZX_DRIVER_PCH | AZX_DCAPS_INTEL_PCH },
 	/* Sunrise Point */
 	{ PCI_DEVICE(0x8086, 0xa170),
-	  .driver_data = AZX_DRIVER_PCH | AZX_DCAPS_INTEL_PCH },
+	  .driver_data = AZX_DRIVER_PCH | AZX_DCAPS_INTEL_SKYLAKE },
 	/* Sunrise Point-LP */
 	{ PCI_DEVICE(0x8086, 0x9d70),
 	  .driver_data = AZX_DRIVER_PCH | AZX_DCAPS_INTEL_SKYLAKE },
diff --git a/sound/pci/hda/patch_realtek.c b/sound/pci/hda/patch_realtek.c
index e0c06f9a0e80..7f46d063af57 100644
--- a/sound/pci/hda/patch_realtek.c
+++ b/sound/pci/hda/patch_realtek.c
@@ -396,7 +396,7 @@ static void alc_auto_setup_eapd(struct hda_codec *codec, bool on)
 {
 	/* We currently only handle front, HP */
 	static hda_nid_t pins[] = {
-		0x0f, 0x10, 0x14, 0x15, 0
+		0x0f, 0x10, 0x14, 0x15, 0x17, 0
 	};
 	hda_nid_t *p;
 	for (p = pins; *p; p++)
@@ -2870,6 +2870,8 @@ static void alc283_init(struct hda_codec *codec)
 
 	if (!hp_pin)
 		return;
+
+	msleep(30);
 	hp_pin_sense = snd_hda_jack_detect(codec, hp_pin);
 
 	/* Index 0x43 Direct Drive HP AMP LPM Control 1 */
@@ -3564,6 +3566,7 @@ static void alc_headset_mode_unplugged(struct hda_codec *codec)
 
 	switch (codec->core.vendor_id) {
 	case 0x10ec0255:
+	case 0x10ec0256:
 		alc_process_coef_fw(codec, coef0255);
 		break;
 	case 0x10ec0233:
@@ -3619,6 +3622,7 @@ static void alc_headset_mode_mic_in(struct hda_codec *codec, hda_nid_t hp_pin,
 
 	switch (codec->core.vendor_id) {
 	case 0x10ec0255:
+	case 0x10ec0256:
 		alc_write_coef_idx(codec, 0x45, 0xc489);
 		snd_hda_set_pin_ctl_cache(codec, hp_pin, 0);
 		alc_process_coef_fw(codec, coef0255);
@@ -3688,6 +3692,7 @@ static void alc_headset_mode_default(struct hda_codec *codec)
 
 	switch (codec->core.vendor_id) {
 	case 0x10ec0255:
+	case 0x10ec0256:
 		alc_process_coef_fw(codec, coef0255);
 		break;
 	case 0x10ec0233:
@@ -3742,6 +3747,7 @@ static void alc_headset_mode_ctia(struct hda_codec *codec)
 
 	switch (codec->core.vendor_id) {
 	case 0x10ec0255:
+	case 0x10ec0256:
 		alc_process_coef_fw(codec, coef0255);
 		break;
 	case 0x10ec0233:
@@ -3796,6 +3802,7 @@ static void alc_headset_mode_omtp(struct hda_codec *codec)
 
 	switch (codec->core.vendor_id) {
 	case 0x10ec0255:
+	case 0x10ec0256:
 		alc_process_coef_fw(codec, coef0255);
 		break;
 	case 0x10ec0233:
@@ -3841,6 +3848,7 @@ static void alc_determine_headset_type(struct hda_codec *codec)
 
 	switch (codec->core.vendor_id) {
 	case 0x10ec0255:
+	case 0x10ec0256:
 		alc_process_coef_fw(codec, coef0255);
 		msleep(300);
 		val = alc_read_coef_idx(codec, 0x46);
@@ -4993,6 +5001,7 @@ static const struct snd_pci_quirk alc269_fixup_tbl[] = {
 	SND_PCI_QUIRK(0x17aa, 0x501a, "Thinkpad", ALC283_FIXUP_INT_MIC),
 	SND_PCI_QUIRK(0x17aa, 0x501e, "Thinkpad L440", ALC292_FIXUP_TPT440_DOCK),
 	SND_PCI_QUIRK(0x17aa, 0x5026, "Thinkpad", ALC269_FIXUP_LIMIT_INT_MIC_BOOST),
+	SND_PCI_QUIRK(0x17aa, 0x5036, "Thinkpad T450s", ALC292_FIXUP_TPT440_DOCK),
 	SND_PCI_QUIRK(0x17aa, 0x5109, "Thinkpad", ALC269_FIXUP_LIMIT_INT_MIC_BOOST),
 	SND_PCI_QUIRK(0x17aa, 0x3bf8, "Quanta FL1", ALC269_FIXUP_PCM_44K),
 	SND_PCI_QUIRK(0x17aa, 0x9e54, "LENOVO NB", ALC269_FIXUP_LENOVO_EAPD),
@@ -5173,6 +5182,16 @@ static const struct snd_hda_pin_quirk alc269_pin_fixup_tbl[] = {
 		{0x17, 0x40000000},
 		{0x1d, 0x40700001},
 		{0x21, 0x02211050}),
+	SND_HDA_PIN_QUIRK(0x10ec0256, 0x1028, "Dell", ALC255_FIXUP_DELL1_MIC_NO_PRESENCE,
+		{0x12, 0x90a60140},
+		{0x13, 0x40000000},
+		{0x14, 0x90170110},
+		{0x19, 0x411111f0},
+		{0x1a, 0x411111f0},
+		{0x1b, 0x411111f0},
+		{0x1d, 0x40700001},
+		{0x1e, 0x411111f0},
+		{0x21, 0x02211020}),
 	SND_HDA_PIN_QUIRK(0x10ec0280, 0x103c, "HP", ALC280_FIXUP_HP_GPIO4,
 		{0x12, 0x90a60130},
 		{0x13, 0x40000000},
diff --git a/sound/usb/quirks.c b/sound/usb/quirks.c
index 353532b8aee4..8f63e8c8b46c 100644
--- a/sound/usb/quirks.c
+++ b/sound/usb/quirks.c
@@ -1113,8 +1113,13 @@ void snd_usb_set_format_quirk(struct snd_usb_substream *subs,
 
 bool snd_usb_get_sample_rate_quirk(struct snd_usb_audio *chip)
 {
-	/* MS Lifecam HD-5000 doesn't support reading the sample rate. */
-	return chip->usb_id == USB_ID(0x045E, 0x076D);
+	/* devices which do not support reading the sample rate. */
+	switch (chip->usb_id) {
+	case USB_ID(0x045E, 0x076D): /* MS Lifecam HD-5000 */
+	case USB_ID(0x04D8, 0xFEEA): /* Benchmark DAC1 Pre */
+		return true;
+	}
+	return false;
 }
 
 /* Marantz/Denon USB DACs need a vendor cmd to switch

_______________________________________________
Intel-gfx mailing list
Intel-gfx@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/intel-gfx

^ permalink raw reply related	[flat|nested] 6+ messages in thread

* Re: [PATCH 15/19] drm/i915: HSW cdclk support
  2015-04-09 15:17                     ` Takashi Iwai
@ 2015-04-10 13:27                       ` Mika Kahola
  2015-04-10 14:10                         ` Takashi Iwai
  0 siblings, 1 reply; 6+ messages in thread
From: Mika Kahola @ 2015-04-10 13:27 UTC (permalink / raw)
  To: Takashi Iwai; +Cc: intel-gfx, alsa-devel

On Thu, 2015-04-09 at 17:17 +0200, Takashi Iwai wrote:
> At Thu, 9 Apr 2015 15:51:27 +0200,
> Daniel Vetter wrote:
> > 
> > On Thu, Apr 09, 2015 at 04:41:26PM +0300, Mika Kahola wrote:
> > > On Thu, 2015-04-09 at 11:32 +0200, Daniel Vetter wrote:
> > > > On Thu, Apr 09, 2015 at 10:24:24AM +0300, Mika Kahola wrote:
> > > > > I did some testing on audio part with HDMI-HDMI and DP-HDMI cables
> > > > > connected to my Haswell box. Before applying the patch I tested as a
> > > > > reference with the latest -nightly (04-08-2015), 4.0-rc7. Unfortunately,
> > > > > I failed to get any audio over HDMI cable. For a reference I tested with
> > > > > the very same setup the vanillla kernel from Linus tree 4.0-rc7 and with
> > > > > that kernel the audio worked ok. Then I did some GIT bisecting and it
> > > > > turned out that the first commit that I failed to get audio working was
> > > > > aa2fee4286e43b4784982b17669b02cc99c1ae55.
> > > > 
> > > I rerun the bisecting and this time the result was
> > > 
> > > commit 0a599838737a2527c35e4d94f794aefe59df1781
> > > Merge: 2d846c7 a59d719
> > > Author: Takashi Iwai <tiwai@suse.de>
> > > Date:   Wed Apr 8 11:29:56 2015 +0200
> > > 
> > >     Merge branch 'for-linus' into for-next
> > >     
> > >     Back merge HD-audio quirks to for-next branch, so that we can apply
> > >     a couple of more quirks.
> > >     
> > >     Signed-off-by: Takashi Iwai <tiwai@suse.de>
> > 
> > Adding Takashi and intel audio folks.
> 
> The bisecting looks odd.  The commit you pointed is a back-merge from
> 4.0-rc to next branch, so this merge itself shouldn't bring so many
> stuff -- at least about the sound part.
> 
> The diff in sound/* is found below.  As you can see, the only change
> relevant with HDMI is the chunk in sound/pci/hda/hda_intel.c for
> HD-audio controller, but it's specific to Skylake, thus this must be
> irrelevant with your hardware.
> 
> Please double-check.

I double-checked the bisecting and I ended up with the same result. You're
right, it does seems odd why audio on my Haswell box stopped working.

Any ideas how to proceed from here?

Cheers,
Mika


> thanks,
> 
> Takashi
> 
> ===
> % git diff 0a599838737a2527c35e4d94f794aefe59df1781^..0a599838737a2527c35e4d94f794aefe59df1781 sound
> diff --git a/sound/pci/hda/hda_intel.c b/sound/pci/hda/hda_intel.c
> index 9bcc5457a83e..e1c210515581 100644
> --- a/sound/pci/hda/hda_intel.c
> +++ b/sound/pci/hda/hda_intel.c
> @@ -1967,7 +1967,7 @@ static const struct pci_device_id azx_ids[] = {
>  	  .driver_data = AZX_DRIVER_PCH | AZX_DCAPS_INTEL_PCH },
>  	/* Sunrise Point */
>  	{ PCI_DEVICE(0x8086, 0xa170),
> -	  .driver_data = AZX_DRIVER_PCH | AZX_DCAPS_INTEL_PCH },
> +	  .driver_data = AZX_DRIVER_PCH | AZX_DCAPS_INTEL_SKYLAKE },
>  	/* Sunrise Point-LP */
>  	{ PCI_DEVICE(0x8086, 0x9d70),
>  	  .driver_data = AZX_DRIVER_PCH | AZX_DCAPS_INTEL_SKYLAKE },
> diff --git a/sound/pci/hda/patch_realtek.c b/sound/pci/hda/patch_realtek.c
> index e0c06f9a0e80..7f46d063af57 100644
> --- a/sound/pci/hda/patch_realtek.c
> +++ b/sound/pci/hda/patch_realtek.c
> @@ -396,7 +396,7 @@ static void alc_auto_setup_eapd(struct hda_codec *codec, bool on)
>  {
>  	/* We currently only handle front, HP */
>  	static hda_nid_t pins[] = {
> -		0x0f, 0x10, 0x14, 0x15, 0
> +		0x0f, 0x10, 0x14, 0x15, 0x17, 0
>  	};
>  	hda_nid_t *p;
>  	for (p = pins; *p; p++)
> @@ -2870,6 +2870,8 @@ static void alc283_init(struct hda_codec *codec)
>  
>  	if (!hp_pin)
>  		return;
> +
> +	msleep(30);
>  	hp_pin_sense = snd_hda_jack_detect(codec, hp_pin);
>  
>  	/* Index 0x43 Direct Drive HP AMP LPM Control 1 */
> @@ -3564,6 +3566,7 @@ static void alc_headset_mode_unplugged(struct hda_codec *codec)
>  
>  	switch (codec->core.vendor_id) {
>  	case 0x10ec0255:
> +	case 0x10ec0256:
>  		alc_process_coef_fw(codec, coef0255);
>  		break;
>  	case 0x10ec0233:
> @@ -3619,6 +3622,7 @@ static void alc_headset_mode_mic_in(struct hda_codec *codec, hda_nid_t hp_pin,
>  
>  	switch (codec->core.vendor_id) {
>  	case 0x10ec0255:
> +	case 0x10ec0256:
>  		alc_write_coef_idx(codec, 0x45, 0xc489);
>  		snd_hda_set_pin_ctl_cache(codec, hp_pin, 0);
>  		alc_process_coef_fw(codec, coef0255);
> @@ -3688,6 +3692,7 @@ static void alc_headset_mode_default(struct hda_codec *codec)
>  
>  	switch (codec->core.vendor_id) {
>  	case 0x10ec0255:
> +	case 0x10ec0256:
>  		alc_process_coef_fw(codec, coef0255);
>  		break;
>  	case 0x10ec0233:
> @@ -3742,6 +3747,7 @@ static void alc_headset_mode_ctia(struct hda_codec *codec)
>  
>  	switch (codec->core.vendor_id) {
>  	case 0x10ec0255:
> +	case 0x10ec0256:
>  		alc_process_coef_fw(codec, coef0255);
>  		break;
>  	case 0x10ec0233:
> @@ -3796,6 +3802,7 @@ static void alc_headset_mode_omtp(struct hda_codec *codec)
>  
>  	switch (codec->core.vendor_id) {
>  	case 0x10ec0255:
> +	case 0x10ec0256:
>  		alc_process_coef_fw(codec, coef0255);
>  		break;
>  	case 0x10ec0233:
> @@ -3841,6 +3848,7 @@ static void alc_determine_headset_type(struct hda_codec *codec)
>  
>  	switch (codec->core.vendor_id) {
>  	case 0x10ec0255:
> +	case 0x10ec0256:
>  		alc_process_coef_fw(codec, coef0255);
>  		msleep(300);
>  		val = alc_read_coef_idx(codec, 0x46);
> @@ -4993,6 +5001,7 @@ static const struct snd_pci_quirk alc269_fixup_tbl[] = {
>  	SND_PCI_QUIRK(0x17aa, 0x501a, "Thinkpad", ALC283_FIXUP_INT_MIC),
>  	SND_PCI_QUIRK(0x17aa, 0x501e, "Thinkpad L440", ALC292_FIXUP_TPT440_DOCK),
>  	SND_PCI_QUIRK(0x17aa, 0x5026, "Thinkpad", ALC269_FIXUP_LIMIT_INT_MIC_BOOST),
> +	SND_PCI_QUIRK(0x17aa, 0x5036, "Thinkpad T450s", ALC292_FIXUP_TPT440_DOCK),
>  	SND_PCI_QUIRK(0x17aa, 0x5109, "Thinkpad", ALC269_FIXUP_LIMIT_INT_MIC_BOOST),
>  	SND_PCI_QUIRK(0x17aa, 0x3bf8, "Quanta FL1", ALC269_FIXUP_PCM_44K),
>  	SND_PCI_QUIRK(0x17aa, 0x9e54, "LENOVO NB", ALC269_FIXUP_LENOVO_EAPD),
> @@ -5173,6 +5182,16 @@ static const struct snd_hda_pin_quirk alc269_pin_fixup_tbl[] = {
>  		{0x17, 0x40000000},
>  		{0x1d, 0x40700001},
>  		{0x21, 0x02211050}),
> +	SND_HDA_PIN_QUIRK(0x10ec0256, 0x1028, "Dell", ALC255_FIXUP_DELL1_MIC_NO_PRESENCE,
> +		{0x12, 0x90a60140},
> +		{0x13, 0x40000000},
> +		{0x14, 0x90170110},
> +		{0x19, 0x411111f0},
> +		{0x1a, 0x411111f0},
> +		{0x1b, 0x411111f0},
> +		{0x1d, 0x40700001},
> +		{0x1e, 0x411111f0},
> +		{0x21, 0x02211020}),
>  	SND_HDA_PIN_QUIRK(0x10ec0280, 0x103c, "HP", ALC280_FIXUP_HP_GPIO4,
>  		{0x12, 0x90a60130},
>  		{0x13, 0x40000000},
> diff --git a/sound/usb/quirks.c b/sound/usb/quirks.c
> index 353532b8aee4..8f63e8c8b46c 100644
> --- a/sound/usb/quirks.c
> +++ b/sound/usb/quirks.c
> @@ -1113,8 +1113,13 @@ void snd_usb_set_format_quirk(struct snd_usb_substream *subs,
>  
>  bool snd_usb_get_sample_rate_quirk(struct snd_usb_audio *chip)
>  {
> -	/* MS Lifecam HD-5000 doesn't support reading the sample rate. */
> -	return chip->usb_id == USB_ID(0x045E, 0x076D);
> +	/* devices which do not support reading the sample rate. */
> +	switch (chip->usb_id) {
> +	case USB_ID(0x045E, 0x076D): /* MS Lifecam HD-5000 */
> +	case USB_ID(0x04D8, 0xFEEA): /* Benchmark DAC1 Pre */
> +		return true;
> +	}
> +	return false;
>  }
>  
>  /* Marantz/Denon USB DACs need a vendor cmd to switch
> 


_______________________________________________
Intel-gfx mailing list
Intel-gfx@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/intel-gfx

^ permalink raw reply	[flat|nested] 6+ messages in thread

* Re: [PATCH 15/19] drm/i915: HSW cdclk support
  2015-04-10 13:27                       ` Mika Kahola
@ 2015-04-10 14:10                         ` Takashi Iwai
  2015-04-13  9:43                           ` Mika Kahola
  0 siblings, 1 reply; 6+ messages in thread
From: Takashi Iwai @ 2015-04-10 14:10 UTC (permalink / raw)
  To: Mika Kahola; +Cc: intel-gfx, alsa-devel

At Fri, 10 Apr 2015 16:27:39 +0300,
Mika Kahola wrote:
> 
> On Thu, 2015-04-09 at 17:17 +0200, Takashi Iwai wrote:
> > At Thu, 9 Apr 2015 15:51:27 +0200,
> > Daniel Vetter wrote:
> > > 
> > > On Thu, Apr 09, 2015 at 04:41:26PM +0300, Mika Kahola wrote:
> > > > On Thu, 2015-04-09 at 11:32 +0200, Daniel Vetter wrote:
> > > > > On Thu, Apr 09, 2015 at 10:24:24AM +0300, Mika Kahola wrote:
> > > > > > I did some testing on audio part with HDMI-HDMI and DP-HDMI cables
> > > > > > connected to my Haswell box. Before applying the patch I tested as a
> > > > > > reference with the latest -nightly (04-08-2015), 4.0-rc7. Unfortunately,
> > > > > > I failed to get any audio over HDMI cable. For a reference I tested with
> > > > > > the very same setup the vanillla kernel from Linus tree 4.0-rc7 and with
> > > > > > that kernel the audio worked ok. Then I did some GIT bisecting and it
> > > > > > turned out that the first commit that I failed to get audio working was
> > > > > > aa2fee4286e43b4784982b17669b02cc99c1ae55.
> > > > > 
> > > > I rerun the bisecting and this time the result was
> > > > 
> > > > commit 0a599838737a2527c35e4d94f794aefe59df1781
> > > > Merge: 2d846c7 a59d719
> > > > Author: Takashi Iwai <tiwai@suse.de>
> > > > Date:   Wed Apr 8 11:29:56 2015 +0200
> > > > 
> > > >     Merge branch 'for-linus' into for-next
> > > >     
> > > >     Back merge HD-audio quirks to for-next branch, so that we can apply
> > > >     a couple of more quirks.
> > > >     
> > > >     Signed-off-by: Takashi Iwai <tiwai@suse.de>
> > > 
> > > Adding Takashi and intel audio folks.
> > 
> > The bisecting looks odd.  The commit you pointed is a back-merge from
> > 4.0-rc to next branch, so this merge itself shouldn't bring so many
> > stuff -- at least about the sound part.
> > 
> > The diff in sound/* is found below.  As you can see, the only change
> > relevant with HDMI is the chunk in sound/pci/hda/hda_intel.c for
> > HD-audio controller, but it's specific to Skylake, thus this must be
> > irrelevant with your hardware.
> > 
> > Please double-check.
> 
> I double-checked the bisecting and I ended up with the same result. You're
> right, it does seems odd why audio on my Haswell box stopped working.
> 
> Any ideas how to proceed from here?

Try to check whether the reverting the diff of sound/* manually fixes
the problem.  (i.e. apply diff -R for the diff I showed in the
previous mail.)

If it doesn't fix but still reverting the whole commit does fix, it
means that something else got broken by the merge.


Takashi


> 
> Cheers,
> Mika
> 
> 
> > thanks,
> > 
> > Takashi
> > 
> > ===
> > % git diff 0a599838737a2527c35e4d94f794aefe59df1781^..0a599838737a2527c35e4d94f794aefe59df1781 sound
> > diff --git a/sound/pci/hda/hda_intel.c b/sound/pci/hda/hda_intel.c
> > index 9bcc5457a83e..e1c210515581 100644
> > --- a/sound/pci/hda/hda_intel.c
> > +++ b/sound/pci/hda/hda_intel.c
> > @@ -1967,7 +1967,7 @@ static const struct pci_device_id azx_ids[] = {
> >  	  .driver_data = AZX_DRIVER_PCH | AZX_DCAPS_INTEL_PCH },
> >  	/* Sunrise Point */
> >  	{ PCI_DEVICE(0x8086, 0xa170),
> > -	  .driver_data = AZX_DRIVER_PCH | AZX_DCAPS_INTEL_PCH },
> > +	  .driver_data = AZX_DRIVER_PCH | AZX_DCAPS_INTEL_SKYLAKE },
> >  	/* Sunrise Point-LP */
> >  	{ PCI_DEVICE(0x8086, 0x9d70),
> >  	  .driver_data = AZX_DRIVER_PCH | AZX_DCAPS_INTEL_SKYLAKE },
> > diff --git a/sound/pci/hda/patch_realtek.c b/sound/pci/hda/patch_realtek.c
> > index e0c06f9a0e80..7f46d063af57 100644
> > --- a/sound/pci/hda/patch_realtek.c
> > +++ b/sound/pci/hda/patch_realtek.c
> > @@ -396,7 +396,7 @@ static void alc_auto_setup_eapd(struct hda_codec *codec, bool on)
> >  {
> >  	/* We currently only handle front, HP */
> >  	static hda_nid_t pins[] = {
> > -		0x0f, 0x10, 0x14, 0x15, 0
> > +		0x0f, 0x10, 0x14, 0x15, 0x17, 0
> >  	};
> >  	hda_nid_t *p;
> >  	for (p = pins; *p; p++)
> > @@ -2870,6 +2870,8 @@ static void alc283_init(struct hda_codec *codec)
> >  
> >  	if (!hp_pin)
> >  		return;
> > +
> > +	msleep(30);
> >  	hp_pin_sense = snd_hda_jack_detect(codec, hp_pin);
> >  
> >  	/* Index 0x43 Direct Drive HP AMP LPM Control 1 */
> > @@ -3564,6 +3566,7 @@ static void alc_headset_mode_unplugged(struct hda_codec *codec)
> >  
> >  	switch (codec->core.vendor_id) {
> >  	case 0x10ec0255:
> > +	case 0x10ec0256:
> >  		alc_process_coef_fw(codec, coef0255);
> >  		break;
> >  	case 0x10ec0233:
> > @@ -3619,6 +3622,7 @@ static void alc_headset_mode_mic_in(struct hda_codec *codec, hda_nid_t hp_pin,
> >  
> >  	switch (codec->core.vendor_id) {
> >  	case 0x10ec0255:
> > +	case 0x10ec0256:
> >  		alc_write_coef_idx(codec, 0x45, 0xc489);
> >  		snd_hda_set_pin_ctl_cache(codec, hp_pin, 0);
> >  		alc_process_coef_fw(codec, coef0255);
> > @@ -3688,6 +3692,7 @@ static void alc_headset_mode_default(struct hda_codec *codec)
> >  
> >  	switch (codec->core.vendor_id) {
> >  	case 0x10ec0255:
> > +	case 0x10ec0256:
> >  		alc_process_coef_fw(codec, coef0255);
> >  		break;
> >  	case 0x10ec0233:
> > @@ -3742,6 +3747,7 @@ static void alc_headset_mode_ctia(struct hda_codec *codec)
> >  
> >  	switch (codec->core.vendor_id) {
> >  	case 0x10ec0255:
> > +	case 0x10ec0256:
> >  		alc_process_coef_fw(codec, coef0255);
> >  		break;
> >  	case 0x10ec0233:
> > @@ -3796,6 +3802,7 @@ static void alc_headset_mode_omtp(struct hda_codec *codec)
> >  
> >  	switch (codec->core.vendor_id) {
> >  	case 0x10ec0255:
> > +	case 0x10ec0256:
> >  		alc_process_coef_fw(codec, coef0255);
> >  		break;
> >  	case 0x10ec0233:
> > @@ -3841,6 +3848,7 @@ static void alc_determine_headset_type(struct hda_codec *codec)
> >  
> >  	switch (codec->core.vendor_id) {
> >  	case 0x10ec0255:
> > +	case 0x10ec0256:
> >  		alc_process_coef_fw(codec, coef0255);
> >  		msleep(300);
> >  		val = alc_read_coef_idx(codec, 0x46);
> > @@ -4993,6 +5001,7 @@ static const struct snd_pci_quirk alc269_fixup_tbl[] = {
> >  	SND_PCI_QUIRK(0x17aa, 0x501a, "Thinkpad", ALC283_FIXUP_INT_MIC),
> >  	SND_PCI_QUIRK(0x17aa, 0x501e, "Thinkpad L440", ALC292_FIXUP_TPT440_DOCK),
> >  	SND_PCI_QUIRK(0x17aa, 0x5026, "Thinkpad", ALC269_FIXUP_LIMIT_INT_MIC_BOOST),
> > +	SND_PCI_QUIRK(0x17aa, 0x5036, "Thinkpad T450s", ALC292_FIXUP_TPT440_DOCK),
> >  	SND_PCI_QUIRK(0x17aa, 0x5109, "Thinkpad", ALC269_FIXUP_LIMIT_INT_MIC_BOOST),
> >  	SND_PCI_QUIRK(0x17aa, 0x3bf8, "Quanta FL1", ALC269_FIXUP_PCM_44K),
> >  	SND_PCI_QUIRK(0x17aa, 0x9e54, "LENOVO NB", ALC269_FIXUP_LENOVO_EAPD),
> > @@ -5173,6 +5182,16 @@ static const struct snd_hda_pin_quirk alc269_pin_fixup_tbl[] = {
> >  		{0x17, 0x40000000},
> >  		{0x1d, 0x40700001},
> >  		{0x21, 0x02211050}),
> > +	SND_HDA_PIN_QUIRK(0x10ec0256, 0x1028, "Dell", ALC255_FIXUP_DELL1_MIC_NO_PRESENCE,
> > +		{0x12, 0x90a60140},
> > +		{0x13, 0x40000000},
> > +		{0x14, 0x90170110},
> > +		{0x19, 0x411111f0},
> > +		{0x1a, 0x411111f0},
> > +		{0x1b, 0x411111f0},
> > +		{0x1d, 0x40700001},
> > +		{0x1e, 0x411111f0},
> > +		{0x21, 0x02211020}),
> >  	SND_HDA_PIN_QUIRK(0x10ec0280, 0x103c, "HP", ALC280_FIXUP_HP_GPIO4,
> >  		{0x12, 0x90a60130},
> >  		{0x13, 0x40000000},
> > diff --git a/sound/usb/quirks.c b/sound/usb/quirks.c
> > index 353532b8aee4..8f63e8c8b46c 100644
> > --- a/sound/usb/quirks.c
> > +++ b/sound/usb/quirks.c
> > @@ -1113,8 +1113,13 @@ void snd_usb_set_format_quirk(struct snd_usb_substream *subs,
> >  
> >  bool snd_usb_get_sample_rate_quirk(struct snd_usb_audio *chip)
> >  {
> > -	/* MS Lifecam HD-5000 doesn't support reading the sample rate. */
> > -	return chip->usb_id == USB_ID(0x045E, 0x076D);
> > +	/* devices which do not support reading the sample rate. */
> > +	switch (chip->usb_id) {
> > +	case USB_ID(0x045E, 0x076D): /* MS Lifecam HD-5000 */
> > +	case USB_ID(0x04D8, 0xFEEA): /* Benchmark DAC1 Pre */
> > +		return true;
> > +	}
> > +	return false;
> >  }
> >  
> >  /* Marantz/Denon USB DACs need a vendor cmd to switch
> > 
> 
> 
_______________________________________________
Intel-gfx mailing list
Intel-gfx@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/intel-gfx

^ permalink raw reply	[flat|nested] 6+ messages in thread

* Re: [PATCH 15/19] drm/i915: HSW cdclk support
  2015-04-10 14:10                         ` Takashi Iwai
@ 2015-04-13  9:43                           ` Mika Kahola
  2015-04-13 10:33                             ` Ville Syrjälä
  0 siblings, 1 reply; 6+ messages in thread
From: Mika Kahola @ 2015-04-13  9:43 UTC (permalink / raw)
  To: Takashi Iwai; +Cc: intel-gfx, alsa-devel

On Fri, 2015-04-10 at 16:10 +0200, Takashi Iwai wrote:
> At Fri, 10 Apr 2015 16:27:39 +0300,
> Mika Kahola wrote:
> > 
> > On Thu, 2015-04-09 at 17:17 +0200, Takashi Iwai wrote:
> > > At Thu, 9 Apr 2015 15:51:27 +0200,
> > > Daniel Vetter wrote:
> > > > 
> > > > On Thu, Apr 09, 2015 at 04:41:26PM +0300, Mika Kahola wrote:
> > > > > On Thu, 2015-04-09 at 11:32 +0200, Daniel Vetter wrote:
> > > > > > On Thu, Apr 09, 2015 at 10:24:24AM +0300, Mika Kahola wrote:
> > > > > > > I did some testing on audio part with HDMI-HDMI and DP-HDMI cables
> > > > > > > connected to my Haswell box. Before applying the patch I tested as a
> > > > > > > reference with the latest -nightly (04-08-2015), 4.0-rc7. Unfortunately,
> > > > > > > I failed to get any audio over HDMI cable. For a reference I tested with
> > > > > > > the very same setup the vanillla kernel from Linus tree 4.0-rc7 and with
> > > > > > > that kernel the audio worked ok. Then I did some GIT bisecting and it
> > > > > > > turned out that the first commit that I failed to get audio working was
> > > > > > > aa2fee4286e43b4784982b17669b02cc99c1ae55.
> > > > > > 
> > > > > I rerun the bisecting and this time the result was
> > > > > 
> > > > > commit 0a599838737a2527c35e4d94f794aefe59df1781
> > > > > Merge: 2d846c7 a59d719
> > > > > Author: Takashi Iwai <tiwai@suse.de>
> > > > > Date:   Wed Apr 8 11:29:56 2015 +0200
> > > > > 
> > > > >     Merge branch 'for-linus' into for-next
> > > > >     
> > > > >     Back merge HD-audio quirks to for-next branch, so that we can apply
> > > > >     a couple of more quirks.
> > > > >     
> > > > >     Signed-off-by: Takashi Iwai <tiwai@suse.de>
> > > > 
> > > > Adding Takashi and intel audio folks.
> > > 
> > > The bisecting looks odd.  The commit you pointed is a back-merge from
> > > 4.0-rc to next branch, so this merge itself shouldn't bring so many
> > > stuff -- at least about the sound part.
> > > 
> > > The diff in sound/* is found below.  As you can see, the only change
> > > relevant with HDMI is the chunk in sound/pci/hda/hda_intel.c for
> > > HD-audio controller, but it's specific to Skylake, thus this must be
> > > irrelevant with your hardware.
> > > 
> > > Please double-check.
> > 
> > I double-checked the bisecting and I ended up with the same result. You're
> > right, it does seems odd why audio on my Haswell box stopped working.
> > 
> > Any ideas how to proceed from here?
> 
> Try to check whether the reverting the diff of sound/* manually fixes
> the problem.  (i.e. apply diff -R for the diff I showed in the
> previous mail.)
> 
> If it doesn't fix but still reverting the whole commit does fix, it
> means that something else got broken by the merge.
> 
> 
> Takashi
> 

I reverted the diff but unfortunately there were no difference. 

For curiosity, I tested the audio with the latest -nightly and I got
the audio working again. I wonder what has changed but it seems that
the problem is now solved.

-Mika-

> 
> > 
> > Cheers,
> > Mika
> > 
> > 
> > > thanks,
> > > 
> > > Takashi
> > > 
> > > ===
> > > % git diff 0a599838737a2527c35e4d94f794aefe59df1781^..0a599838737a2527c35e4d94f794aefe59df1781 sound
> > > diff --git a/sound/pci/hda/hda_intel.c b/sound/pci/hda/hda_intel.c
> > > index 9bcc5457a83e..e1c210515581 100644
> > > --- a/sound/pci/hda/hda_intel.c
> > > +++ b/sound/pci/hda/hda_intel.c
> > > @@ -1967,7 +1967,7 @@ static const struct pci_device_id azx_ids[] = {
> > >  	  .driver_data = AZX_DRIVER_PCH | AZX_DCAPS_INTEL_PCH },
> > >  	/* Sunrise Point */
> > >  	{ PCI_DEVICE(0x8086, 0xa170),
> > > -	  .driver_data = AZX_DRIVER_PCH | AZX_DCAPS_INTEL_PCH },
> > > +	  .driver_data = AZX_DRIVER_PCH | AZX_DCAPS_INTEL_SKYLAKE },
> > >  	/* Sunrise Point-LP */
> > >  	{ PCI_DEVICE(0x8086, 0x9d70),
> > >  	  .driver_data = AZX_DRIVER_PCH | AZX_DCAPS_INTEL_SKYLAKE },
> > > diff --git a/sound/pci/hda/patch_realtek.c b/sound/pci/hda/patch_realtek.c
> > > index e0c06f9a0e80..7f46d063af57 100644
> > > --- a/sound/pci/hda/patch_realtek.c
> > > +++ b/sound/pci/hda/patch_realtek.c
> > > @@ -396,7 +396,7 @@ static void alc_auto_setup_eapd(struct hda_codec *codec, bool on)
> > >  {
> > >  	/* We currently only handle front, HP */
> > >  	static hda_nid_t pins[] = {
> > > -		0x0f, 0x10, 0x14, 0x15, 0
> > > +		0x0f, 0x10, 0x14, 0x15, 0x17, 0
> > >  	};
> > >  	hda_nid_t *p;
> > >  	for (p = pins; *p; p++)
> > > @@ -2870,6 +2870,8 @@ static void alc283_init(struct hda_codec *codec)
> > >  
> > >  	if (!hp_pin)
> > >  		return;
> > > +
> > > +	msleep(30);
> > >  	hp_pin_sense = snd_hda_jack_detect(codec, hp_pin);
> > >  
> > >  	/* Index 0x43 Direct Drive HP AMP LPM Control 1 */
> > > @@ -3564,6 +3566,7 @@ static void alc_headset_mode_unplugged(struct hda_codec *codec)
> > >  
> > >  	switch (codec->core.vendor_id) {
> > >  	case 0x10ec0255:
> > > +	case 0x10ec0256:
> > >  		alc_process_coef_fw(codec, coef0255);
> > >  		break;
> > >  	case 0x10ec0233:
> > > @@ -3619,6 +3622,7 @@ static void alc_headset_mode_mic_in(struct hda_codec *codec, hda_nid_t hp_pin,
> > >  
> > >  	switch (codec->core.vendor_id) {
> > >  	case 0x10ec0255:
> > > +	case 0x10ec0256:
> > >  		alc_write_coef_idx(codec, 0x45, 0xc489);
> > >  		snd_hda_set_pin_ctl_cache(codec, hp_pin, 0);
> > >  		alc_process_coef_fw(codec, coef0255);
> > > @@ -3688,6 +3692,7 @@ static void alc_headset_mode_default(struct hda_codec *codec)
> > >  
> > >  	switch (codec->core.vendor_id) {
> > >  	case 0x10ec0255:
> > > +	case 0x10ec0256:
> > >  		alc_process_coef_fw(codec, coef0255);
> > >  		break;
> > >  	case 0x10ec0233:
> > > @@ -3742,6 +3747,7 @@ static void alc_headset_mode_ctia(struct hda_codec *codec)
> > >  
> > >  	switch (codec->core.vendor_id) {
> > >  	case 0x10ec0255:
> > > +	case 0x10ec0256:
> > >  		alc_process_coef_fw(codec, coef0255);
> > >  		break;
> > >  	case 0x10ec0233:
> > > @@ -3796,6 +3802,7 @@ static void alc_headset_mode_omtp(struct hda_codec *codec)
> > >  
> > >  	switch (codec->core.vendor_id) {
> > >  	case 0x10ec0255:
> > > +	case 0x10ec0256:
> > >  		alc_process_coef_fw(codec, coef0255);
> > >  		break;
> > >  	case 0x10ec0233:
> > > @@ -3841,6 +3848,7 @@ static void alc_determine_headset_type(struct hda_codec *codec)
> > >  
> > >  	switch (codec->core.vendor_id) {
> > >  	case 0x10ec0255:
> > > +	case 0x10ec0256:
> > >  		alc_process_coef_fw(codec, coef0255);
> > >  		msleep(300);
> > >  		val = alc_read_coef_idx(codec, 0x46);
> > > @@ -4993,6 +5001,7 @@ static const struct snd_pci_quirk alc269_fixup_tbl[] = {
> > >  	SND_PCI_QUIRK(0x17aa, 0x501a, "Thinkpad", ALC283_FIXUP_INT_MIC),
> > >  	SND_PCI_QUIRK(0x17aa, 0x501e, "Thinkpad L440", ALC292_FIXUP_TPT440_DOCK),
> > >  	SND_PCI_QUIRK(0x17aa, 0x5026, "Thinkpad", ALC269_FIXUP_LIMIT_INT_MIC_BOOST),
> > > +	SND_PCI_QUIRK(0x17aa, 0x5036, "Thinkpad T450s", ALC292_FIXUP_TPT440_DOCK),
> > >  	SND_PCI_QUIRK(0x17aa, 0x5109, "Thinkpad", ALC269_FIXUP_LIMIT_INT_MIC_BOOST),
> > >  	SND_PCI_QUIRK(0x17aa, 0x3bf8, "Quanta FL1", ALC269_FIXUP_PCM_44K),
> > >  	SND_PCI_QUIRK(0x17aa, 0x9e54, "LENOVO NB", ALC269_FIXUP_LENOVO_EAPD),
> > > @@ -5173,6 +5182,16 @@ static const struct snd_hda_pin_quirk alc269_pin_fixup_tbl[] = {
> > >  		{0x17, 0x40000000},
> > >  		{0x1d, 0x40700001},
> > >  		{0x21, 0x02211050}),
> > > +	SND_HDA_PIN_QUIRK(0x10ec0256, 0x1028, "Dell", ALC255_FIXUP_DELL1_MIC_NO_PRESENCE,
> > > +		{0x12, 0x90a60140},
> > > +		{0x13, 0x40000000},
> > > +		{0x14, 0x90170110},
> > > +		{0x19, 0x411111f0},
> > > +		{0x1a, 0x411111f0},
> > > +		{0x1b, 0x411111f0},
> > > +		{0x1d, 0x40700001},
> > > +		{0x1e, 0x411111f0},
> > > +		{0x21, 0x02211020}),
> > >  	SND_HDA_PIN_QUIRK(0x10ec0280, 0x103c, "HP", ALC280_FIXUP_HP_GPIO4,
> > >  		{0x12, 0x90a60130},
> > >  		{0x13, 0x40000000},
> > > diff --git a/sound/usb/quirks.c b/sound/usb/quirks.c
> > > index 353532b8aee4..8f63e8c8b46c 100644
> > > --- a/sound/usb/quirks.c
> > > +++ b/sound/usb/quirks.c
> > > @@ -1113,8 +1113,13 @@ void snd_usb_set_format_quirk(struct snd_usb_substream *subs,
> > >  
> > >  bool snd_usb_get_sample_rate_quirk(struct snd_usb_audio *chip)
> > >  {
> > > -	/* MS Lifecam HD-5000 doesn't support reading the sample rate. */
> > > -	return chip->usb_id == USB_ID(0x045E, 0x076D);
> > > +	/* devices which do not support reading the sample rate. */
> > > +	switch (chip->usb_id) {
> > > +	case USB_ID(0x045E, 0x076D): /* MS Lifecam HD-5000 */
> > > +	case USB_ID(0x04D8, 0xFEEA): /* Benchmark DAC1 Pre */
> > > +		return true;
> > > +	}
> > > +	return false;
> > >  }
> > >  
> > >  /* Marantz/Denon USB DACs need a vendor cmd to switch
> > > 
> > 
> > 


_______________________________________________
Intel-gfx mailing list
Intel-gfx@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/intel-gfx

^ permalink raw reply	[flat|nested] 6+ messages in thread

* Re: [PATCH 15/19] drm/i915: HSW cdclk support
  2015-04-13  9:43                           ` Mika Kahola
@ 2015-04-13 10:33                             ` Ville Syrjälä
  0 siblings, 0 replies; 6+ messages in thread
From: Ville Syrjälä @ 2015-04-13 10:33 UTC (permalink / raw)
  To: Mika Kahola; +Cc: Takashi Iwai, intel-gfx, alsa-devel

On Mon, Apr 13, 2015 at 12:43:14PM +0300, Mika Kahola wrote:
> On Fri, 2015-04-10 at 16:10 +0200, Takashi Iwai wrote:
> > At Fri, 10 Apr 2015 16:27:39 +0300,
> > Mika Kahola wrote:
> > > 
> > > On Thu, 2015-04-09 at 17:17 +0200, Takashi Iwai wrote:
> > > > At Thu, 9 Apr 2015 15:51:27 +0200,
> > > > Daniel Vetter wrote:
> > > > > 
> > > > > On Thu, Apr 09, 2015 at 04:41:26PM +0300, Mika Kahola wrote:
> > > > > > On Thu, 2015-04-09 at 11:32 +0200, Daniel Vetter wrote:
> > > > > > > On Thu, Apr 09, 2015 at 10:24:24AM +0300, Mika Kahola wrote:
> > > > > > > > I did some testing on audio part with HDMI-HDMI and DP-HDMI cables
> > > > > > > > connected to my Haswell box. Before applying the patch I tested as a
> > > > > > > > reference with the latest -nightly (04-08-2015), 4.0-rc7. Unfortunately,
> > > > > > > > I failed to get any audio over HDMI cable. For a reference I tested with
> > > > > > > > the very same setup the vanillla kernel from Linus tree 4.0-rc7 and with
> > > > > > > > that kernel the audio worked ok. Then I did some GIT bisecting and it
> > > > > > > > turned out that the first commit that I failed to get audio working was
> > > > > > > > aa2fee4286e43b4784982b17669b02cc99c1ae55.
> > > > > > > 
> > > > > > I rerun the bisecting and this time the result was
> > > > > > 
> > > > > > commit 0a599838737a2527c35e4d94f794aefe59df1781
> > > > > > Merge: 2d846c7 a59d719
> > > > > > Author: Takashi Iwai <tiwai@suse.de>
> > > > > > Date:   Wed Apr 8 11:29:56 2015 +0200
> > > > > > 
> > > > > >     Merge branch 'for-linus' into for-next
> > > > > >     
> > > > > >     Back merge HD-audio quirks to for-next branch, so that we can apply
> > > > > >     a couple of more quirks.
> > > > > >     
> > > > > >     Signed-off-by: Takashi Iwai <tiwai@suse.de>
> > > > > 
> > > > > Adding Takashi and intel audio folks.
> > > > 
> > > > The bisecting looks odd.  The commit you pointed is a back-merge from
> > > > 4.0-rc to next branch, so this merge itself shouldn't bring so many
> > > > stuff -- at least about the sound part.
> > > > 
> > > > The diff in sound/* is found below.  As you can see, the only change
> > > > relevant with HDMI is the chunk in sound/pci/hda/hda_intel.c for
> > > > HD-audio controller, but it's specific to Skylake, thus this must be
> > > > irrelevant with your hardware.
> > > > 
> > > > Please double-check.
> > > 
> > > I double-checked the bisecting and I ended up with the same result. You're
> > > right, it does seems odd why audio on my Haswell box stopped working.
> > > 
> > > Any ideas how to proceed from here?
> > 
> > Try to check whether the reverting the diff of sound/* manually fixes
> > the problem.  (i.e. apply diff -R for the diff I showed in the
> > previous mail.)
> > 
> > If it doesn't fix but still reverting the whole commit does fix, it
> > means that something else got broken by the merge.
> > 
> > 
> > Takashi
> > 
> 
> I reverted the diff but unfortunately there were no difference. 
> 
> For curiosity, I tested the audio with the latest -nightly and I got
> the audio working again. I wonder what has changed but it seems that
> the problem is now solved.

BTW we now have a WARN triggering on BSW due to hda trying to query
the current cdclk frequency.
https://bugs.freedesktop.org/show_bug.cgi?id=90012

I'm not sure if hda really needs to know the cdclk freq on BSW or not.
But in either case I think we should just kill the HAS_DDI check. Once
these patches land the code will anyway work on all platforms. Mika,
can you add that to your list of things to do on top of these patches?

> 
> -Mika-
> 
> > 
> > > 
> > > Cheers,
> > > Mika
> > > 
> > > 
> > > > thanks,
> > > > 
> > > > Takashi
> > > > 
> > > > ===
> > > > % git diff 0a599838737a2527c35e4d94f794aefe59df1781^..0a599838737a2527c35e4d94f794aefe59df1781 sound
> > > > diff --git a/sound/pci/hda/hda_intel.c b/sound/pci/hda/hda_intel.c
> > > > index 9bcc5457a83e..e1c210515581 100644
> > > > --- a/sound/pci/hda/hda_intel.c
> > > > +++ b/sound/pci/hda/hda_intel.c
> > > > @@ -1967,7 +1967,7 @@ static const struct pci_device_id azx_ids[] = {
> > > >  	  .driver_data = AZX_DRIVER_PCH | AZX_DCAPS_INTEL_PCH },
> > > >  	/* Sunrise Point */
> > > >  	{ PCI_DEVICE(0x8086, 0xa170),
> > > > -	  .driver_data = AZX_DRIVER_PCH | AZX_DCAPS_INTEL_PCH },
> > > > +	  .driver_data = AZX_DRIVER_PCH | AZX_DCAPS_INTEL_SKYLAKE },
> > > >  	/* Sunrise Point-LP */
> > > >  	{ PCI_DEVICE(0x8086, 0x9d70),
> > > >  	  .driver_data = AZX_DRIVER_PCH | AZX_DCAPS_INTEL_SKYLAKE },
> > > > diff --git a/sound/pci/hda/patch_realtek.c b/sound/pci/hda/patch_realtek.c
> > > > index e0c06f9a0e80..7f46d063af57 100644
> > > > --- a/sound/pci/hda/patch_realtek.c
> > > > +++ b/sound/pci/hda/patch_realtek.c
> > > > @@ -396,7 +396,7 @@ static void alc_auto_setup_eapd(struct hda_codec *codec, bool on)
> > > >  {
> > > >  	/* We currently only handle front, HP */
> > > >  	static hda_nid_t pins[] = {
> > > > -		0x0f, 0x10, 0x14, 0x15, 0
> > > > +		0x0f, 0x10, 0x14, 0x15, 0x17, 0
> > > >  	};
> > > >  	hda_nid_t *p;
> > > >  	for (p = pins; *p; p++)
> > > > @@ -2870,6 +2870,8 @@ static void alc283_init(struct hda_codec *codec)
> > > >  
> > > >  	if (!hp_pin)
> > > >  		return;
> > > > +
> > > > +	msleep(30);
> > > >  	hp_pin_sense = snd_hda_jack_detect(codec, hp_pin);
> > > >  
> > > >  	/* Index 0x43 Direct Drive HP AMP LPM Control 1 */
> > > > @@ -3564,6 +3566,7 @@ static void alc_headset_mode_unplugged(struct hda_codec *codec)
> > > >  
> > > >  	switch (codec->core.vendor_id) {
> > > >  	case 0x10ec0255:
> > > > +	case 0x10ec0256:
> > > >  		alc_process_coef_fw(codec, coef0255);
> > > >  		break;
> > > >  	case 0x10ec0233:
> > > > @@ -3619,6 +3622,7 @@ static void alc_headset_mode_mic_in(struct hda_codec *codec, hda_nid_t hp_pin,
> > > >  
> > > >  	switch (codec->core.vendor_id) {
> > > >  	case 0x10ec0255:
> > > > +	case 0x10ec0256:
> > > >  		alc_write_coef_idx(codec, 0x45, 0xc489);
> > > >  		snd_hda_set_pin_ctl_cache(codec, hp_pin, 0);
> > > >  		alc_process_coef_fw(codec, coef0255);
> > > > @@ -3688,6 +3692,7 @@ static void alc_headset_mode_default(struct hda_codec *codec)
> > > >  
> > > >  	switch (codec->core.vendor_id) {
> > > >  	case 0x10ec0255:
> > > > +	case 0x10ec0256:
> > > >  		alc_process_coef_fw(codec, coef0255);
> > > >  		break;
> > > >  	case 0x10ec0233:
> > > > @@ -3742,6 +3747,7 @@ static void alc_headset_mode_ctia(struct hda_codec *codec)
> > > >  
> > > >  	switch (codec->core.vendor_id) {
> > > >  	case 0x10ec0255:
> > > > +	case 0x10ec0256:
> > > >  		alc_process_coef_fw(codec, coef0255);
> > > >  		break;
> > > >  	case 0x10ec0233:
> > > > @@ -3796,6 +3802,7 @@ static void alc_headset_mode_omtp(struct hda_codec *codec)
> > > >  
> > > >  	switch (codec->core.vendor_id) {
> > > >  	case 0x10ec0255:
> > > > +	case 0x10ec0256:
> > > >  		alc_process_coef_fw(codec, coef0255);
> > > >  		break;
> > > >  	case 0x10ec0233:
> > > > @@ -3841,6 +3848,7 @@ static void alc_determine_headset_type(struct hda_codec *codec)
> > > >  
> > > >  	switch (codec->core.vendor_id) {
> > > >  	case 0x10ec0255:
> > > > +	case 0x10ec0256:
> > > >  		alc_process_coef_fw(codec, coef0255);
> > > >  		msleep(300);
> > > >  		val = alc_read_coef_idx(codec, 0x46);
> > > > @@ -4993,6 +5001,7 @@ static const struct snd_pci_quirk alc269_fixup_tbl[] = {
> > > >  	SND_PCI_QUIRK(0x17aa, 0x501a, "Thinkpad", ALC283_FIXUP_INT_MIC),
> > > >  	SND_PCI_QUIRK(0x17aa, 0x501e, "Thinkpad L440", ALC292_FIXUP_TPT440_DOCK),
> > > >  	SND_PCI_QUIRK(0x17aa, 0x5026, "Thinkpad", ALC269_FIXUP_LIMIT_INT_MIC_BOOST),
> > > > +	SND_PCI_QUIRK(0x17aa, 0x5036, "Thinkpad T450s", ALC292_FIXUP_TPT440_DOCK),
> > > >  	SND_PCI_QUIRK(0x17aa, 0x5109, "Thinkpad", ALC269_FIXUP_LIMIT_INT_MIC_BOOST),
> > > >  	SND_PCI_QUIRK(0x17aa, 0x3bf8, "Quanta FL1", ALC269_FIXUP_PCM_44K),
> > > >  	SND_PCI_QUIRK(0x17aa, 0x9e54, "LENOVO NB", ALC269_FIXUP_LENOVO_EAPD),
> > > > @@ -5173,6 +5182,16 @@ static const struct snd_hda_pin_quirk alc269_pin_fixup_tbl[] = {
> > > >  		{0x17, 0x40000000},
> > > >  		{0x1d, 0x40700001},
> > > >  		{0x21, 0x02211050}),
> > > > +	SND_HDA_PIN_QUIRK(0x10ec0256, 0x1028, "Dell", ALC255_FIXUP_DELL1_MIC_NO_PRESENCE,
> > > > +		{0x12, 0x90a60140},
> > > > +		{0x13, 0x40000000},
> > > > +		{0x14, 0x90170110},
> > > > +		{0x19, 0x411111f0},
> > > > +		{0x1a, 0x411111f0},
> > > > +		{0x1b, 0x411111f0},
> > > > +		{0x1d, 0x40700001},
> > > > +		{0x1e, 0x411111f0},
> > > > +		{0x21, 0x02211020}),
> > > >  	SND_HDA_PIN_QUIRK(0x10ec0280, 0x103c, "HP", ALC280_FIXUP_HP_GPIO4,
> > > >  		{0x12, 0x90a60130},
> > > >  		{0x13, 0x40000000},
> > > > diff --git a/sound/usb/quirks.c b/sound/usb/quirks.c
> > > > index 353532b8aee4..8f63e8c8b46c 100644
> > > > --- a/sound/usb/quirks.c
> > > > +++ b/sound/usb/quirks.c
> > > > @@ -1113,8 +1113,13 @@ void snd_usb_set_format_quirk(struct snd_usb_substream *subs,
> > > >  
> > > >  bool snd_usb_get_sample_rate_quirk(struct snd_usb_audio *chip)
> > > >  {
> > > > -	/* MS Lifecam HD-5000 doesn't support reading the sample rate. */
> > > > -	return chip->usb_id == USB_ID(0x045E, 0x076D);
> > > > +	/* devices which do not support reading the sample rate. */
> > > > +	switch (chip->usb_id) {
> > > > +	case USB_ID(0x045E, 0x076D): /* MS Lifecam HD-5000 */
> > > > +	case USB_ID(0x04D8, 0xFEEA): /* Benchmark DAC1 Pre */
> > > > +		return true;
> > > > +	}
> > > > +	return false;
> > > >  }
> > > >  
> > > >  /* Marantz/Denon USB DACs need a vendor cmd to switch
> > > > 
> > > 
> > > 
> 
> 
> _______________________________________________
> Intel-gfx mailing list
> Intel-gfx@lists.freedesktop.org
> http://lists.freedesktop.org/mailman/listinfo/intel-gfx

-- 
Ville Syrjälä
Intel OTC
_______________________________________________
Intel-gfx mailing list
Intel-gfx@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/intel-gfx

^ permalink raw reply	[flat|nested] 6+ messages in thread

end of thread, other threads:[~2015-04-13 10:33 UTC | newest]

Thread overview: 6+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
     [not found] <1427800454-5236-1-git-send-email-mika.kahola@intel.com>
     [not found] ` <552378CB.7@intel.com>
     [not found]   ` <5523814C.9070505@intel.com>
     [not found]     ` <20150407082934.GG17410@intel.com>
     [not found]       ` <55239722.9030505@intel.com>
     [not found]         ` <20150407092925.GA3027@sorvi>
     [not found]           ` <20150407135238.GI6354@phenom.ffwll.local>
     [not found]             ` <1428564264.7745.14.camel@sorvi>
     [not found]               ` <20150409093200.GB12038@phenom.ffwll.local>
     [not found]                 ` <1428586886.3155.5.camel@sorvi>
2015-04-09 13:51                   ` [PATCH 15/19] drm/i915: HSW cdclk support Daniel Vetter
2015-04-09 15:17                     ` Takashi Iwai
2015-04-10 13:27                       ` Mika Kahola
2015-04-10 14:10                         ` Takashi Iwai
2015-04-13  9:43                           ` Mika Kahola
2015-04-13 10:33                             ` Ville Syrjälä

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).