Re: [PATCH 1/2] drm/i915: Check num_pipes before initializing audio component

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



> 
> On Fri, 16 Dec 2016, Wang Elaine <elaine.wang@xxxxxxxxx> wrote:
> > From: Elaine Wang <elaine.wang@xxxxxxxxx>
> >
> > when num_pipes is zero, it indicates there is no display and HDMI
> > audio doesn't exist.
> >
> > Cc: Chris Wilson <chris@xxxxxxxxxxxxxxxxxx>
> > Cc: Joonas Lahtinen <joonas.lahtinen@xxxxxxxxxxxxxxx>
> > Signed-off-by: Elaine Wang <elaine.wang@xxxxxxxxx>
> > ---
> >  drivers/gpu/drm/i915/i915_drv.c | 3 ++-
> >  1 file changed, 2 insertions(+), 1 deletion(-)
> >
> > diff --git a/drivers/gpu/drm/i915/i915_drv.c
> > b/drivers/gpu/drm/i915/i915_drv.c index 6428588..c94e26d 100644
> > --- a/drivers/gpu/drm/i915/i915_drv.c
> > +++ b/drivers/gpu/drm/i915/i915_drv.c
> > @@ -1132,7 +1132,8 @@ static void i915_driver_register(struct
> drm_i915_private *dev_priv)
> >  	if (IS_GEN5(dev_priv))
> >  		intel_gpu_ips_init(dev_priv);
> >
> > -	i915_audio_component_init(dev_priv);
> > +	if (INTEL_INFO(dev_priv)->num_pipes)
> > +		i915_audio_component_init(dev_priv);
> 
> I just wonder why on some patches in the series the check is on the caller
> side and on some others on the callee side. I'd like consistency.
> 
> BR,
> Jani.

Thanks for the comment. I'll revise the patch and made all the check on callee side.
Elaine
> 
> >
> >  	/*
> >  	 * Some ports require correctly set-up hpd registers for detection
> > to
> 
> --
> Jani Nikula, Intel Open Source Technology Center
_______________________________________________
Intel-gfx mailing list
Intel-gfx@xxxxxxxxxxxxxxxxxxxxx
https://lists.freedesktop.org/mailman/listinfo/intel-gfx




[Index of Archives]     [Linux USB Devel]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]
  Powered by Linux