All of lore.kernel.org
 help / color / mirror / Atom feed
From: "Ville Syrjälä" <ville.syrjala@linux.intel.com>
To: "José Roberto de Souza" <jose.souza@intel.com>
Cc: intel-gfx@lists.freedesktop.org, dri-devel@lists.freedesktop.org
Subject: Re: [PATCH v3] drm: Return -EOPNOTSUPP in drm_setclientcap() when driver do not support KMS
Date: Tue, 18 Sep 2018 21:02:04 +0300	[thread overview]
Message-ID: <20180918180204.GW5565@intel.com> (raw)
In-Reply-To: <20180918174809.17123-1-jose.souza@intel.com>

On Tue, Sep 18, 2018 at 10:48:09AM -0700, José Roberto de Souza wrote:
> All DRM_CLIENT capabilities are tied to KMS support, so returning
> -EOPNOTSUPP when KMS is not supported.
> 
> v2: returning -EOPNOTSUPP(same value as posix ENOTSUP and available
> in uapi) instead of -ENOTSUPP
> 
> v3: adding comments about the feature requirement about capabilities
> 
> Cc: Chris Wilson <chris@chris-wilson.co.uk>
> Signed-off-by: José Roberto de Souza <jose.souza@intel.com>
> ---
>  drivers/gpu/drm/drm_ioctl.c | 6 ++++++
>  1 file changed, 6 insertions(+)
> 
> diff --git a/drivers/gpu/drm/drm_ioctl.c b/drivers/gpu/drm/drm_ioctl.c
> index 60dfbfae6a02..94bd872d56c4 100644
> --- a/drivers/gpu/drm/drm_ioctl.c
> +++ b/drivers/gpu/drm/drm_ioctl.c
> @@ -306,6 +306,12 @@ drm_setclientcap(struct drm_device *dev, void *data, struct drm_file *file_priv)
>  {
>  	struct drm_set_client_cap *req = data;
>  
> +	/* No render-only settable capabilities for now */
> +
> +	/* Below caps that only works with KMS drivers */

That doesn't seem quite English.

> +	if (!drm_core_check_feature(dev, DRIVER_MODESET))
> +		return -EOPNOTSUPP;
> +
>  	switch (req->capability) {
>  	case DRM_CLIENT_CAP_STEREO_3D:
>  		if (req->value > 1)
> -- 
> 2.19.0
> 
> _______________________________________________
> Intel-gfx mailing list
> Intel-gfx@lists.freedesktop.org
> https://lists.freedesktop.org/mailman/listinfo/intel-gfx

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

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

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2018-09-18 17:48 [PATCH v3] drm: Return -EOPNOTSUPP in drm_setclientcap() when driver do not support KMS José Roberto de Souza
2018-09-18 18:02 ` Ville Syrjälä [this message]
2018-09-21  9:21   ` Daniel Vetter
2018-09-18 18:20 ` ✗ Fi.CI.BAT: failure for drm: Return -EOPNOTSUPP in drm_setclientcap() when driver do not support KMS (rev2) Patchwork

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=20180918180204.GW5565@intel.com \
    --to=ville.syrjala@linux.intel.com \
    --cc=dri-devel@lists.freedesktop.org \
    --cc=intel-gfx@lists.freedesktop.org \
    --cc=jose.souza@intel.com \
    /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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.