[PATCH] drm: Make sure drm_vblank_no_hw_counter isn't abused

Vivi, Rodrigo rodrigo.vivi at intel.com
Mon Aug 8 16:27:34 UTC 2016


Reviewed-by: Rodrigo Vivi <rdorigo.vivi at intel.com>

On Mon, 2016-08-08 at 18:24 +0200, Daniel Vetter wrote:
> Shouldn't be possible since everyone kzallocs this, but better safe
> than sorry. Random drive-by-idea really.
> 
> Cc: Rodrigo Vivi <rodrigo.vivi at intel.com>
> Signed-off-by: Daniel Vetter <daniel.vetter at intel.com>
> ---
>  drivers/gpu/drm/drm_irq.c | 1 +
>  1 file changed, 1 insertion(+)
> 
> diff --git a/drivers/gpu/drm/drm_irq.c b/drivers/gpu/drm/drm_irq.c
> index f5a9f8cef360..10611a936059 100644
> --- a/drivers/gpu/drm/drm_irq.c
> +++ b/drivers/gpu/drm/drm_irq.c
> @@ -1795,6 +1795,7 @@ EXPORT_SYMBOL(drm_crtc_handle_vblank);
>   */
>  u32 drm_vblank_no_hw_counter(struct drm_device *dev, unsigned int
> pipe)
>  {
> +	WARN_ON_ONCE(dev->max_vblank_count != 0);
>  	return 0;
>  }
>  EXPORT_SYMBOL(drm_vblank_no_hw_counter);


More information about the dri-devel mailing list