dri-devel Archive on lore.kernel.org
 help / color / mirror / Atom feed
From: Daniel Vetter <daniel@ffwll.ch>
To: Dave Airlie <airlied@gmail.com>
Cc: dri-devel@lists.freedesktop.org
Subject: Re: [PATCH] drm: fix drm_drv_uses_atomic_modeset on non modesetting drivers.
Date: Tue, 18 Sep 2018 11:18:30 +0200	[thread overview]
Message-ID: <20180918091830.GS11082@phenom.ffwll.local> (raw)
In-Reply-To: <20180918062018.24942-1-airlied@gmail.com>

On Tue, Sep 18, 2018 at 04:20:18PM +1000, Dave Airlie wrote:
> From: Dave Airlie <airlied@redhat.com>
> 
> vgem seems to oops on the intel CI due to the vgem debugfs init
> hitting this path now.
> 
> Check if we have mode_config funcs before checking one.
> 
> Signed-off-by: Dave Airlie <airlied@redhat.com>

I thought Dave would apply, but I guess too late for him, and since CI is
burning I went ahead and pushed to drm-misc-fixes.

I kinda wonder why we didn't blow up on vgem earlier. I guess not a whole
lot of fuzzing going on ...
-Daniel

> ---
>  include/drm/drm_drv.h | 2 +-
>  1 file changed, 1 insertion(+), 1 deletion(-)
> 
> diff --git a/include/drm/drm_drv.h b/include/drm/drm_drv.h
> index 8830e3de3a86..3199ef70c007 100644
> --- a/include/drm/drm_drv.h
> +++ b/include/drm/drm_drv.h
> @@ -674,7 +674,7 @@ static inline bool drm_core_check_feature(struct drm_device *dev, u32 feature)
>  static inline bool drm_drv_uses_atomic_modeset(struct drm_device *dev)
>  {
>  	return drm_core_check_feature(dev, DRIVER_ATOMIC) ||
> -		dev->mode_config.funcs->atomic_commit != NULL;
> +		(dev->mode_config.funcs && dev->mode_config.funcs->atomic_commit != NULL);
>  }
>  
>  
> -- 
> 2.17.1
> 
> _______________________________________________
> dri-devel mailing list
> dri-devel@lists.freedesktop.org
> https://lists.freedesktop.org/mailman/listinfo/dri-devel

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

      reply	other threads:[~2018-09-18  9:18 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2018-09-18  6:20 [PATCH] drm: fix drm_drv_uses_atomic_modeset on non modesetting drivers Dave Airlie
2018-09-18  9:18 ` Daniel Vetter [this message]

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20180918091830.GS11082@phenom.ffwll.local \
    --to=daniel@ffwll.ch \
    --cc=airlied@gmail.com \
    --cc=dri-devel@lists.freedesktop.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox