All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH] drm/i915: fix definition of the DRM_IOCTL_I915_GET_SPRITE_COLORKEY ioctl
@ 2015-03-26 19:47 Tommi Rantala
  2015-03-27  6:39 ` Jani Nikula
  0 siblings, 1 reply; 7+ messages in thread
From: Tommi Rantala @ 2015-03-26 19:47 UTC (permalink / raw)
  To: Daniel Vetter, Jani Nikula; +Cc: linux-api, intel-gfx, dri-devel

Fix definition of the DRM_IOCTL_I915_GET_SPRITE_COLORKEY ioctl, so that it
is different from the DRM_IOCTL_I915_SET_SPRITE_COLORKEY ioctl.

Signed-off-by: Tommi Rantala <tt.rantala@gmail.com>
---
 include/uapi/drm/i915_drm.h | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/include/uapi/drm/i915_drm.h b/include/uapi/drm/i915_drm.h
index 6eed16b..0e9c835 100644
--- a/include/uapi/drm/i915_drm.h
+++ b/include/uapi/drm/i915_drm.h
@@ -270,7 +270,7 @@ typedef struct _drm_i915_sarea {
 #define DRM_IOCTL_I915_OVERLAY_PUT_IMAGE	DRM_IOW(DRM_COMMAND_BASE + DRM_I915_OVERLAY_PUT_IMAGE, struct drm_intel_overlay_put_image)
 #define DRM_IOCTL_I915_OVERLAY_ATTRS	DRM_IOWR(DRM_COMMAND_BASE + DRM_I915_OVERLAY_ATTRS, struct drm_intel_overlay_attrs)
 #define DRM_IOCTL_I915_SET_SPRITE_COLORKEY DRM_IOWR(DRM_COMMAND_BASE + DRM_I915_SET_SPRITE_COLORKEY, struct drm_intel_sprite_colorkey)
-#define DRM_IOCTL_I915_GET_SPRITE_COLORKEY DRM_IOWR(DRM_COMMAND_BASE + DRM_I915_SET_SPRITE_COLORKEY, struct drm_intel_sprite_colorkey)
+#define DRM_IOCTL_I915_GET_SPRITE_COLORKEY DRM_IOWR(DRM_COMMAND_BASE + DRM_I915_GET_SPRITE_COLORKEY, struct drm_intel_sprite_colorkey)
 #define DRM_IOCTL_I915_GEM_WAIT		DRM_IOWR(DRM_COMMAND_BASE + DRM_I915_GEM_WAIT, struct drm_i915_gem_wait)
 #define DRM_IOCTL_I915_GEM_CONTEXT_CREATE	DRM_IOWR (DRM_COMMAND_BASE + DRM_I915_GEM_CONTEXT_CREATE, struct drm_i915_gem_context_create)
 #define DRM_IOCTL_I915_GEM_CONTEXT_DESTROY	DRM_IOW (DRM_COMMAND_BASE + DRM_I915_GEM_CONTEXT_DESTROY, struct drm_i915_gem_context_destroy)
-- 
2.1.0

_______________________________________________
dri-devel mailing list
dri-devel@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/dri-devel

^ permalink raw reply related	[flat|nested] 7+ messages in thread

* Re: [PATCH] drm/i915: fix definition of the DRM_IOCTL_I915_GET_SPRITE_COLORKEY ioctl
  2015-03-26 19:47 [PATCH] drm/i915: fix definition of the DRM_IOCTL_I915_GET_SPRITE_COLORKEY ioctl Tommi Rantala
@ 2015-03-27  6:39 ` Jani Nikula
       [not found]   ` <87a8yzq6yr.fsf-ral2JQCrhuEAvxtiuMwx3w@public.gmane.org>
  2015-03-27 15:17   ` Jesse Barnes
  0 siblings, 2 replies; 7+ messages in thread
From: Jani Nikula @ 2015-03-27  6:39 UTC (permalink / raw)
  To: Tommi Rantala, Daniel Vetter
  Cc: David Airlie, linux-api, intel-gfx, dri-devel, Barnes, Jesse

On Thu, 26 Mar 2015, Tommi Rantala <tt.rantala@gmail.com> wrote:
> Fix definition of the DRM_IOCTL_I915_GET_SPRITE_COLORKEY ioctl, so that it
> is different from the DRM_IOCTL_I915_SET_SPRITE_COLORKEY ioctl.
>
> Signed-off-by: Tommi Rantala <tt.rantala@gmail.com>

Whoa. Broken since its introduction in

commit 8ea30864229e54b01ac0e9fe88c4b733a940ec4e
Author: Jesse Barnes <jbarnes@virtuousgeek.org>
Date:   Tue Jan 3 08:05:39 2012 -0800

    drm/i915: add color key support v4

Cc: stable@vger.kernel.org

BR,
Jani.


> ---
>  include/uapi/drm/i915_drm.h | 2 +-
>  1 file changed, 1 insertion(+), 1 deletion(-)
>
> diff --git a/include/uapi/drm/i915_drm.h b/include/uapi/drm/i915_drm.h
> index 6eed16b..0e9c835 100644
> --- a/include/uapi/drm/i915_drm.h
> +++ b/include/uapi/drm/i915_drm.h
> @@ -270,7 +270,7 @@ typedef struct _drm_i915_sarea {
>  #define DRM_IOCTL_I915_OVERLAY_PUT_IMAGE	DRM_IOW(DRM_COMMAND_BASE + DRM_I915_OVERLAY_PUT_IMAGE, struct drm_intel_overlay_put_image)
>  #define DRM_IOCTL_I915_OVERLAY_ATTRS	DRM_IOWR(DRM_COMMAND_BASE + DRM_I915_OVERLAY_ATTRS, struct drm_intel_overlay_attrs)
>  #define DRM_IOCTL_I915_SET_SPRITE_COLORKEY DRM_IOWR(DRM_COMMAND_BASE + DRM_I915_SET_SPRITE_COLORKEY, struct drm_intel_sprite_colorkey)
> -#define DRM_IOCTL_I915_GET_SPRITE_COLORKEY DRM_IOWR(DRM_COMMAND_BASE + DRM_I915_SET_SPRITE_COLORKEY, struct drm_intel_sprite_colorkey)
> +#define DRM_IOCTL_I915_GET_SPRITE_COLORKEY DRM_IOWR(DRM_COMMAND_BASE + DRM_I915_GET_SPRITE_COLORKEY, struct drm_intel_sprite_colorkey)
>  #define DRM_IOCTL_I915_GEM_WAIT		DRM_IOWR(DRM_COMMAND_BASE + DRM_I915_GEM_WAIT, struct drm_i915_gem_wait)
>  #define DRM_IOCTL_I915_GEM_CONTEXT_CREATE	DRM_IOWR (DRM_COMMAND_BASE + DRM_I915_GEM_CONTEXT_CREATE, struct drm_i915_gem_context_create)
>  #define DRM_IOCTL_I915_GEM_CONTEXT_DESTROY	DRM_IOW (DRM_COMMAND_BASE + DRM_I915_GEM_CONTEXT_DESTROY, struct drm_i915_gem_context_destroy)
> -- 
> 2.1.0
>

-- 
Jani Nikula, Intel Open Source Technology Center
_______________________________________________
Intel-gfx mailing list
Intel-gfx@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/intel-gfx

^ permalink raw reply	[flat|nested] 7+ messages in thread

* Re: [Intel-gfx] [PATCH] drm/i915: fix definition of the DRM_IOCTL_I915_GET_SPRITE_COLORKEY ioctl
       [not found]   ` <87a8yzq6yr.fsf-ral2JQCrhuEAvxtiuMwx3w@public.gmane.org>
@ 2015-03-27  8:04     ` Daniel Vetter
       [not found]       ` <20150327080427.GB23521-dv86pmgwkMBes7Z6vYuT8azUEOm+Xw19@public.gmane.org>
  0 siblings, 1 reply; 7+ messages in thread
From: Daniel Vetter @ 2015-03-27  8:04 UTC (permalink / raw)
  To: Jani Nikula
  Cc: Tommi Rantala, Daniel Vetter, David Airlie,
	linux-api-u79uwXL29TY76Z2rM5mHXA,
	intel-gfx-PD4FTy7X32lNgt0PjOBp9y5qC8QIuHrW,
	dri-devel-PD4FTy7X32lNgt0PjOBp9y5qC8QIuHrW, Barnes, Jesse

On Fri, Mar 27, 2015 at 08:39:56AM +0200, Jani Nikula wrote:
> On Thu, 26 Mar 2015, Tommi Rantala <tt.rantala-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org> wrote:
> > Fix definition of the DRM_IOCTL_I915_GET_SPRITE_COLORKEY ioctl, so that it
> > is different from the DRM_IOCTL_I915_SET_SPRITE_COLORKEY ioctl.
> >
> > Signed-off-by: Tommi Rantala <tt.rantala-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org>
> 
> Whoa. Broken since its introduction in
> 
> commit 8ea30864229e54b01ac0e9fe88c4b733a940ec4e
> Author: Jesse Barnes <jbarnes-Y1mF5jBUw70BENJcbMCuUQ@public.gmane.org>
> Date:   Tue Jan 3 08:05:39 2012 -0800
> 
>     drm/i915: add color key support v4
> 
> Cc: stable-u79uwXL29TY76Z2rM5mHXA@public.gmane.org

Nope, we'll just rip it out and replace it all with the drm_noop ioctl. At
least I didn't find any userspace anywhere and only broken definitions.
Proof enough this isn't useful.

Even more so since that means we don't have to convert the get ioctl over
to atomic, yay! I'll send patches.
-Daniel
-- 
Daniel Vetter
Software Engineer, Intel Corporation
http://blog.ffwll.ch

^ permalink raw reply	[flat|nested] 7+ messages in thread

* Re: [PATCH] drm/i915: fix definition of the DRM_IOCTL_I915_GET_SPRITE_COLORKEY ioctl
  2015-03-27  6:39 ` Jani Nikula
       [not found]   ` <87a8yzq6yr.fsf-ral2JQCrhuEAvxtiuMwx3w@public.gmane.org>
@ 2015-03-27 15:17   ` Jesse Barnes
  1 sibling, 0 replies; 7+ messages in thread
From: Jesse Barnes @ 2015-03-27 15:17 UTC (permalink / raw)
  To: Jani Nikula, Tommi Rantala, Daniel Vetter
  Cc: David Airlie, linux-api, intel-gfx, dri-devel

On 03/26/2015 11:39 PM, Jani Nikula wrote:
> On Thu, 26 Mar 2015, Tommi Rantala <tt.rantala@gmail.com> wrote:
>> Fix definition of the DRM_IOCTL_I915_GET_SPRITE_COLORKEY ioctl, so that it
>> is different from the DRM_IOCTL_I915_SET_SPRITE_COLORKEY ioctl.
>>
>> Signed-off-by: Tommi Rantala <tt.rantala@gmail.com>
> 
> Whoa. Broken since its introduction in
> 
> commit 8ea30864229e54b01ac0e9fe88c4b733a940ec4e
> Author: Jesse Barnes <jbarnes@virtuousgeek.org>
> Date:   Tue Jan 3 08:05:39 2012 -0800
> 
>     drm/i915: add color key support v4
> 
> Cc: stable@vger.kernel.org
> 
> BR,
> Jani.
> 
> 
>> ---
>>  include/uapi/drm/i915_drm.h | 2 +-
>>  1 file changed, 1 insertion(+), 1 deletion(-)
>>
>> diff --git a/include/uapi/drm/i915_drm.h b/include/uapi/drm/i915_drm.h
>> index 6eed16b..0e9c835 100644
>> --- a/include/uapi/drm/i915_drm.h
>> +++ b/include/uapi/drm/i915_drm.h
>> @@ -270,7 +270,7 @@ typedef struct _drm_i915_sarea {
>>  #define DRM_IOCTL_I915_OVERLAY_PUT_IMAGE	DRM_IOW(DRM_COMMAND_BASE + DRM_I915_OVERLAY_PUT_IMAGE, struct drm_intel_overlay_put_image)
>>  #define DRM_IOCTL_I915_OVERLAY_ATTRS	DRM_IOWR(DRM_COMMAND_BASE + DRM_I915_OVERLAY_ATTRS, struct drm_intel_overlay_attrs)
>>  #define DRM_IOCTL_I915_SET_SPRITE_COLORKEY DRM_IOWR(DRM_COMMAND_BASE + DRM_I915_SET_SPRITE_COLORKEY, struct drm_intel_sprite_colorkey)
>> -#define DRM_IOCTL_I915_GET_SPRITE_COLORKEY DRM_IOWR(DRM_COMMAND_BASE + DRM_I915_SET_SPRITE_COLORKEY, struct drm_intel_sprite_colorkey)
>> +#define DRM_IOCTL_I915_GET_SPRITE_COLORKEY DRM_IOWR(DRM_COMMAND_BASE + DRM_I915_GET_SPRITE_COLORKEY, struct drm_intel_sprite_colorkey)
>>  #define DRM_IOCTL_I915_GEM_WAIT		DRM_IOWR(DRM_COMMAND_BASE + DRM_I915_GEM_WAIT, struct drm_i915_gem_wait)
>>  #define DRM_IOCTL_I915_GEM_CONTEXT_CREATE	DRM_IOWR (DRM_COMMAND_BASE + DRM_I915_GEM_CONTEXT_CREATE, struct drm_i915_gem_context_create)
>>  #define DRM_IOCTL_I915_GEM_CONTEXT_DESTROY	DRM_IOW (DRM_COMMAND_BASE + DRM_I915_GEM_CONTEXT_DESTROY, struct drm_i915_gem_context_destroy)

Hah, I guess that must be a well used ioctl!  Not even the test program
does a get call!

Jesse

_______________________________________________
Intel-gfx mailing list
Intel-gfx@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/intel-gfx

^ permalink raw reply	[flat|nested] 7+ messages in thread

* Re: [Intel-gfx] [PATCH] drm/i915: fix definition of the DRM_IOCTL_I915_GET_SPRITE_COLORKEY ioctl
       [not found]       ` <20150327080427.GB23521-dv86pmgwkMBes7Z6vYuT8azUEOm+Xw19@public.gmane.org>
@ 2015-03-27 15:18         ` Jesse Barnes
       [not found]           ` <551574C4.6000804-ral2JQCrhuEAvxtiuMwx3w@public.gmane.org>
  0 siblings, 1 reply; 7+ messages in thread
From: Jesse Barnes @ 2015-03-27 15:18 UTC (permalink / raw)
  To: Daniel Vetter, Jani Nikula
  Cc: Tommi Rantala, Daniel Vetter, David Airlie,
	linux-api-u79uwXL29TY76Z2rM5mHXA,
	intel-gfx-PD4FTy7X32lNgt0PjOBp9y5qC8QIuHrW,
	dri-devel-PD4FTy7X32lNgt0PjOBp9y5qC8QIuHrW

On 03/27/2015 01:04 AM, Daniel Vetter wrote:
> On Fri, Mar 27, 2015 at 08:39:56AM +0200, Jani Nikula wrote:
>> On Thu, 26 Mar 2015, Tommi Rantala <tt.rantala-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org> wrote:
>>> Fix definition of the DRM_IOCTL_I915_GET_SPRITE_COLORKEY ioctl, so that it
>>> is different from the DRM_IOCTL_I915_SET_SPRITE_COLORKEY ioctl.
>>>
>>> Signed-off-by: Tommi Rantala <tt.rantala-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org>
>>
>> Whoa. Broken since its introduction in
>>
>> commit 8ea30864229e54b01ac0e9fe88c4b733a940ec4e
>> Author: Jesse Barnes <jbarnes-Y1mF5jBUw70BENJcbMCuUQ@public.gmane.org>
>> Date:   Tue Jan 3 08:05:39 2012 -0800
>>
>>     drm/i915: add color key support v4
>>
>> Cc: stable-u79uwXL29TY76Z2rM5mHXA@public.gmane.org
> 
> Nope, we'll just rip it out and replace it all with the drm_noop ioctl. At
> least I didn't find any userspace anywhere and only broken definitions.
> Proof enough this isn't useful.
> 
> Even more so since that means we don't have to convert the get ioctl over
> to atomic, yay! I'll send patches.

Can we just skip the noop part and delete it altogether?  It was only
added speculatively and obviously never used at all...

^ permalink raw reply	[flat|nested] 7+ messages in thread

* Re: [Intel-gfx] [PATCH] drm/i915: fix definition of the DRM_IOCTL_I915_GET_SPRITE_COLORKEY ioctl
       [not found]           ` <551574C4.6000804-ral2JQCrhuEAvxtiuMwx3w@public.gmane.org>
@ 2015-03-30  6:54             ` Daniel Vetter
  2015-03-30  8:00               ` Ville Syrjälä
  0 siblings, 1 reply; 7+ messages in thread
From: Daniel Vetter @ 2015-03-30  6:54 UTC (permalink / raw)
  To: Jesse Barnes
  Cc: Daniel Vetter, Jani Nikula, Tommi Rantala, Daniel Vetter,
	David Airlie, linux-api-u79uwXL29TY76Z2rM5mHXA,
	intel-gfx-PD4FTy7X32lNgt0PjOBp9y5qC8QIuHrW,
	dri-devel-PD4FTy7X32lNgt0PjOBp9y5qC8QIuHrW

On Fri, Mar 27, 2015 at 08:18:28AM -0700, Jesse Barnes wrote:
> On 03/27/2015 01:04 AM, Daniel Vetter wrote:
> > On Fri, Mar 27, 2015 at 08:39:56AM +0200, Jani Nikula wrote:
> >> On Thu, 26 Mar 2015, Tommi Rantala <tt.rantala-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org> wrote:
> >>> Fix definition of the DRM_IOCTL_I915_GET_SPRITE_COLORKEY ioctl, so that it
> >>> is different from the DRM_IOCTL_I915_SET_SPRITE_COLORKEY ioctl.
> >>>
> >>> Signed-off-by: Tommi Rantala <tt.rantala-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org>
> >>
> >> Whoa. Broken since its introduction in
> >>
> >> commit 8ea30864229e54b01ac0e9fe88c4b733a940ec4e
> >> Author: Jesse Barnes <jbarnes-Y1mF5jBUw70BENJcbMCuUQ@public.gmane.org>
> >> Date:   Tue Jan 3 08:05:39 2012 -0800
> >>
> >>     drm/i915: add color key support v4
> >>
> >> Cc: stable-u79uwXL29TY76Z2rM5mHXA@public.gmane.org
> > 
> > Nope, we'll just rip it out and replace it all with the drm_noop ioctl. At
> > least I didn't find any userspace anywhere and only broken definitions.
> > Proof enough this isn't useful.
> > 
> > Even more so since that means we don't have to convert the get ioctl over
> > to atomic, yay! I'll send patches.
> 
> Can we just skip the noop part and delete it altogether?  It was only
> added speculatively and obviously never used at all...

The table is indexed, we need a dummy entry. I guess we could do a
drm_invalid_ioctl function too for these, but then whether you get an
error or not doesn't really matter for unused ioctls. Hence I've stuck
with drm_noop for all these removed ioctl (except when we need a more
tailore-made lie to keep userspace happy).
-Daniel
-- 
Daniel Vetter
Software Engineer, Intel Corporation
http://blog.ffwll.ch

^ permalink raw reply	[flat|nested] 7+ messages in thread

* Re: [PATCH] drm/i915: fix definition of the DRM_IOCTL_I915_GET_SPRITE_COLORKEY ioctl
  2015-03-30  6:54             ` Daniel Vetter
@ 2015-03-30  8:00               ` Ville Syrjälä
  0 siblings, 0 replies; 7+ messages in thread
From: Ville Syrjälä @ 2015-03-30  8:00 UTC (permalink / raw)
  To: Daniel Vetter
  Cc: linux-api, intel-gfx, Jesse Barnes, dri-devel, Daniel Vetter

On Mon, Mar 30, 2015 at 08:54:55AM +0200, Daniel Vetter wrote:
> On Fri, Mar 27, 2015 at 08:18:28AM -0700, Jesse Barnes wrote:
> > On 03/27/2015 01:04 AM, Daniel Vetter wrote:
> > > On Fri, Mar 27, 2015 at 08:39:56AM +0200, Jani Nikula wrote:
> > >> On Thu, 26 Mar 2015, Tommi Rantala <tt.rantala@gmail.com> wrote:
> > >>> Fix definition of the DRM_IOCTL_I915_GET_SPRITE_COLORKEY ioctl, so that it
> > >>> is different from the DRM_IOCTL_I915_SET_SPRITE_COLORKEY ioctl.
> > >>>
> > >>> Signed-off-by: Tommi Rantala <tt.rantala@gmail.com>
> > >>
> > >> Whoa. Broken since its introduction in
> > >>
> > >> commit 8ea30864229e54b01ac0e9fe88c4b733a940ec4e
> > >> Author: Jesse Barnes <jbarnes@virtuousgeek.org>
> > >> Date:   Tue Jan 3 08:05:39 2012 -0800
> > >>
> > >>     drm/i915: add color key support v4
> > >>
> > >> Cc: stable@vger.kernel.org
> > > 
> > > Nope, we'll just rip it out and replace it all with the drm_noop ioctl. At
> > > least I didn't find any userspace anywhere and only broken definitions.
> > > Proof enough this isn't useful.
> > > 
> > > Even more so since that means we don't have to convert the get ioctl over
> > > to atomic, yay! I'll send patches.
> > 
> > Can we just skip the noop part and delete it altogether?  It was only
> > added speculatively and obviously never used at all...
> 
> The table is indexed, we need a dummy entry.

We shouldn't need any dummies. Any missing entry in the table will
be zeroed, so we should simply return -EINVAL due to ioctl->func==NULL.

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

^ permalink raw reply	[flat|nested] 7+ messages in thread

end of thread, other threads:[~2015-03-30  8:00 UTC | newest]

Thread overview: 7+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2015-03-26 19:47 [PATCH] drm/i915: fix definition of the DRM_IOCTL_I915_GET_SPRITE_COLORKEY ioctl Tommi Rantala
2015-03-27  6:39 ` Jani Nikula
     [not found]   ` <87a8yzq6yr.fsf-ral2JQCrhuEAvxtiuMwx3w@public.gmane.org>
2015-03-27  8:04     ` [Intel-gfx] " Daniel Vetter
     [not found]       ` <20150327080427.GB23521-dv86pmgwkMBes7Z6vYuT8azUEOm+Xw19@public.gmane.org>
2015-03-27 15:18         ` Jesse Barnes
     [not found]           ` <551574C4.6000804-ral2JQCrhuEAvxtiuMwx3w@public.gmane.org>
2015-03-30  6:54             ` Daniel Vetter
2015-03-30  8:00               ` Ville Syrjälä
2015-03-27 15:17   ` Jesse Barnes

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.