[SRU][D/OEM-B-OSP1][PATCH 2/2] UBUNTU: SAUCE: drm/i915: extend audio CDCLK>=2*BCLK constraint to more platforms

Stefan Bader stefan.bader at canonical.com
Tue Oct 8 12:29:33 UTC 2019


On 08.10.19 13:55, Hui Wang wrote:
> From: Kai Vehmanen <kai.vehmanen at linux.intel.com>
> 
> BugLink: https://bugs.launchpad.net/bugs/1847192
> 
> The CDCLK>=2*BCLK constraint applies to all generations since gen10.
> Extend the constraint logic in audio get/put_power().
> 
> Signed-off-by: Kai Vehmanen <kai.vehmanen at linux.intel.com>
> Signed-off-by: Jani Nikula <jani.nikula at intel.com>
> Link: https://patchwork.freedesktop.org/patch/msgid/20191003085531.30990-2-kai.vehmanen@linux.intel.com
> (backported from commit f6ec9483091f8e67adab0311a4e2f90aab523310
> git://anongit.freedesktop.org/drm-intel)
> Signed-off-by: Hui Wang <hui.wang at canonical.com>
> ---
>  drivers/gpu/drm/i915/intel_audio.c | 4 ++--
>  1 file changed, 2 insertions(+), 2 deletions(-)
> 
> diff --git a/drivers/gpu/drm/i915/intel_audio.c b/drivers/gpu/drm/i915/intel_audio.c
> index 1661a8606017..57346bf1342e 100644
> --- a/drivers/gpu/drm/i915/intel_audio.c
> +++ b/drivers/gpu/drm/i915/intel_audio.c
> @@ -794,7 +794,7 @@ static void i915_audio_component_get_power(struct device *kdev)
>  
>  	/* Force CDCLK to 2*BCLK as long as we need audio to be powered. */
>  	if (dev_priv->audio_power_refcount++ == 0) {
> -		if (IS_CANNONLAKE(dev_priv) || IS_GEMINILAKE(dev_priv))
> +		if (INTEL_GEN(dev_priv) >= 10 || IS_GEMINILAKE(dev_priv))

This second patch replaces an IS_CANONLAKE test with a INTEL_GEN test, while the
previous one added and additional section. I have no way to judge whether this
is ok or not, but it looks odd.


>  			glk_force_audio_cdclk(dev_priv, true);
>  
>  		if (INTEL_GEN(dev_priv) >= 10 || IS_GEMINILAKE(dev_priv))
> @@ -810,7 +810,7 @@ static void i915_audio_component_put_power(struct device *kdev)
>  
>  	/* Stop forcing CDCLK to 2*BCLK if no need for audio to be powered. */
>  	if (--dev_priv->audio_power_refcount == 0)
> -		if (IS_CANNONLAKE(dev_priv) || IS_GEMINILAKE(dev_priv))
> +		if (INTEL_GEN(dev_priv) >= 10 || IS_GEMINILAKE(dev_priv))
>  			glk_force_audio_cdclk(dev_priv, false);
>  
>  	intel_display_power_put(kdev_to_i915(kdev), POWER_DOMAIN_AUDIO);
> 


-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 833 bytes
Desc: OpenPGP digital signature
URL: <https://lists.ubuntu.com/archives/kernel-team/attachments/20191008/ea2d07e1/attachment.sig>


More information about the kernel-team mailing list