public inbox for intel-gfx@lists.freedesktop.org
 help / color / mirror / Atom feed
* [PATCH] drm: Nuke drm_framebuffer->helper_private
@ 2015-09-10 20:39 Daniel Vetter
  2015-09-11  1:47 ` David Herrmann
  0 siblings, 1 reply; 3+ messages in thread
From: Daniel Vetter @ 2015-09-10 20:39 UTC (permalink / raw)
  To: Intel Graphics Development, DRI Development
  Cc: Daniel Vetter, gary.k.smith, Daniel Vetter

It's completely unused and there's really no reason for this:
- drm_framebuffer structures are invariant after creation, no need for
  helpers to manipulate them.
- drm_framebuffer structures should just be embedded (and that's what
  all the drivers do).

Stumbled over this since some folks are apparently concerned with the
overhead of struct drm_framebuffer and this is an easy 8 byte saving.

More could be gained by ditching the legacy fields and recomputing
stuff from the fourcc value. But that would require some drm-wide
cocci and real justification.

Cc: gary.k.smith@intel.com
Signed-off-by: Daniel Vetter <daniel.vetter@intel.com>
---
 include/drm/drm_crtc.h | 2 --
 1 file changed, 2 deletions(-)

diff --git a/include/drm/drm_crtc.h b/include/drm/drm_crtc.h
index 75f49c1ef8bb..c0366e9152e2 100644
--- a/include/drm/drm_crtc.h
+++ b/include/drm/drm_crtc.h
@@ -210,8 +210,6 @@ struct drm_framebuffer {
 	int flags;
 	uint32_t pixel_format; /* fourcc format */
 	struct list_head filp_head;
-	/* if you are using the helper */
-	void *helper_private;
 };
 
 struct drm_property_blob {
-- 
2.5.1

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

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

* Re: [PATCH] drm: Nuke drm_framebuffer->helper_private
  2015-09-10 20:39 [PATCH] drm: Nuke drm_framebuffer->helper_private Daniel Vetter
@ 2015-09-11  1:47 ` David Herrmann
  2015-09-11  7:18   ` Daniel Vetter
  0 siblings, 1 reply; 3+ messages in thread
From: David Herrmann @ 2015-09-11  1:47 UTC (permalink / raw)
  To: Daniel Vetter; +Cc: Daniel Vetter, Intel Graphics Development, DRI Development

Hi

On Thu, Sep 10, 2015 at 10:39 PM, Daniel Vetter <daniel.vetter@ffwll.ch> wrote:
> It's completely unused and there's really no reason for this:
> - drm_framebuffer structures are invariant after creation, no need for
>   helpers to manipulate them.
> - drm_framebuffer structures should just be embedded (and that's what
>   all the drivers do).
>
> Stumbled over this since some folks are apparently concerned with the
> overhead of struct drm_framebuffer and this is an easy 8 byte saving.
>
> More could be gained by ditching the legacy fields and recomputing
> stuff from the fourcc value. But that would require some drm-wide
> cocci and real justification.
>
> Cc: gary.k.smith@intel.com
> Signed-off-by: Daniel Vetter <daniel.vetter@intel.com>
> ---
>  include/drm/drm_crtc.h | 2 --
>  1 file changed, 2 deletions(-)

Reviewed-by: David Herrmann <dh.herrmann@gmail.com>

Thanks
David

> diff --git a/include/drm/drm_crtc.h b/include/drm/drm_crtc.h
> index 75f49c1ef8bb..c0366e9152e2 100644
> --- a/include/drm/drm_crtc.h
> +++ b/include/drm/drm_crtc.h
> @@ -210,8 +210,6 @@ struct drm_framebuffer {
>         int flags;
>         uint32_t pixel_format; /* fourcc format */
>         struct list_head filp_head;
> -       /* if you are using the helper */
> -       void *helper_private;
>  };
>
>  struct drm_property_blob {
> --
> 2.5.1
>
> _______________________________________________
> dri-devel mailing list
> dri-devel@lists.freedesktop.org
> http://lists.freedesktop.org/mailman/listinfo/dri-devel
_______________________________________________
Intel-gfx mailing list
Intel-gfx@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/intel-gfx

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

* Re: [PATCH] drm: Nuke drm_framebuffer->helper_private
  2015-09-11  1:47 ` David Herrmann
@ 2015-09-11  7:18   ` Daniel Vetter
  0 siblings, 0 replies; 3+ messages in thread
From: Daniel Vetter @ 2015-09-11  7:18 UTC (permalink / raw)
  To: David Herrmann
  Cc: Daniel Vetter, Intel Graphics Development, DRI Development,
	Daniel Vetter

On Fri, Sep 11, 2015 at 03:47:25AM +0200, David Herrmann wrote:
> Hi
> 
> On Thu, Sep 10, 2015 at 10:39 PM, Daniel Vetter <daniel.vetter@ffwll.ch> wrote:
> > It's completely unused and there's really no reason for this:
> > - drm_framebuffer structures are invariant after creation, no need for
> >   helpers to manipulate them.
> > - drm_framebuffer structures should just be embedded (and that's what
> >   all the drivers do).
> >
> > Stumbled over this since some folks are apparently concerned with the
> > overhead of struct drm_framebuffer and this is an easy 8 byte saving.
> >
> > More could be gained by ditching the legacy fields and recomputing
> > stuff from the fourcc value. But that would require some drm-wide
> > cocci and real justification.
> >
> > Cc: gary.k.smith@intel.com
> > Signed-off-by: Daniel Vetter <daniel.vetter@intel.com>
> > ---
> >  include/drm/drm_crtc.h | 2 --
> >  1 file changed, 2 deletions(-)
> 
> Reviewed-by: David Herrmann <dh.herrmann@gmail.com>

Thanks for the review, patch applied to drm-misc.
-Daniel

> 
> Thanks
> David
> 
> > diff --git a/include/drm/drm_crtc.h b/include/drm/drm_crtc.h
> > index 75f49c1ef8bb..c0366e9152e2 100644
> > --- a/include/drm/drm_crtc.h
> > +++ b/include/drm/drm_crtc.h
> > @@ -210,8 +210,6 @@ struct drm_framebuffer {
> >         int flags;
> >         uint32_t pixel_format; /* fourcc format */
> >         struct list_head filp_head;
> > -       /* if you are using the helper */
> > -       void *helper_private;
> >  };
> >
> >  struct drm_property_blob {
> > --
> > 2.5.1
> >
> > _______________________________________________
> > dri-devel mailing list
> > dri-devel@lists.freedesktop.org
> > http://lists.freedesktop.org/mailman/listinfo/dri-devel

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

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

end of thread, other threads:[~2015-09-11  7:16 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2015-09-10 20:39 [PATCH] drm: Nuke drm_framebuffer->helper_private Daniel Vetter
2015-09-11  1:47 ` David Herrmann
2015-09-11  7:18   ` Daniel Vetter

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox