[03/44] drm/device: Deprecate dev_private harder
diff mbox series

Message ID 20200403135828.2542770-4-daniel.vetter@ffwll.ch
State New
Headers show
Series
  • devm_drm_dev_alloc, no more drmm_add_final_kfree
Related show

Commit Message

Daniel Vetter April 3, 2020, 1:57 p.m. UTC
We've had lots of conversions to embeddeding, but didn't stop using
->dev_private. Which defeats the point of this.

Signed-off-by: Daniel Vetter <daniel.vetter@intel.com>
---
 include/drm/drm_device.h | 9 ++++++---
 1 file changed, 6 insertions(+), 3 deletions(-)

Comments

Sam Ravnborg April 8, 2020, 7:02 a.m. UTC | #1
On Fri, Apr 03, 2020 at 03:57:47PM +0200, Daniel Vetter wrote:
> We've had lots of conversions to embeddeding, but didn't stop using
> ->dev_private. Which defeats the point of this.
> 
> Signed-off-by: Daniel Vetter <daniel.vetter@intel.com>
Reviewed-by: Sam Ravnborg <sam@ravnborg.org>
> ---
>  include/drm/drm_device.h | 9 ++++++---
>  1 file changed, 6 insertions(+), 3 deletions(-)
> 
> diff --git a/include/drm/drm_device.h b/include/drm/drm_device.h
> index d39132b477dd..a55874db9dd4 100644
> --- a/include/drm/drm_device.h
> +++ b/include/drm/drm_device.h
> @@ -88,9 +88,12 @@ struct drm_device {
>  	/**
>  	 * @dev_private:
>  	 *
> -	 * DRM driver private data. Instead of using this pointer it is
> -	 * recommended that drivers use drm_dev_init() and embed struct
> -	 * &drm_device in their larger per-device structure.
> +	 * DRM driver private data. This is deprecated and should be left set to
> +	 * NULL.
> +	 *
> +	 * Instead of using this pointer it is recommended that drivers use
> +	 * drm_dev_init() and embed struct &drm_device in their larger
> +	 * per-device structure.
>  	 */
>  	void *dev_private;
>  
> -- 
> 2.25.1
> 
> _______________________________________________
> dri-devel mailing list
> dri-devel@lists.freedesktop.org
> https://lists.freedesktop.org/mailman/listinfo/dri-devel
Daniel Vetter April 14, 2020, 4:43 p.m. UTC | #2
On Wed, Apr 08, 2020 at 09:02:07AM +0200, Sam Ravnborg wrote:
> On Fri, Apr 03, 2020 at 03:57:47PM +0200, Daniel Vetter wrote:
> > We've had lots of conversions to embeddeding, but didn't stop using
> > ->dev_private. Which defeats the point of this.
> > 
> > Signed-off-by: Daniel Vetter <daniel.vetter@intel.com>
> Reviewed-by: Sam Ravnborg <sam@ravnborg.org>

Went right ahead and pushed this since a doc patch only, thanks for taking
a look!
-Daniel

> > ---
> >  include/drm/drm_device.h | 9 ++++++---
> >  1 file changed, 6 insertions(+), 3 deletions(-)
> > 
> > diff --git a/include/drm/drm_device.h b/include/drm/drm_device.h
> > index d39132b477dd..a55874db9dd4 100644
> > --- a/include/drm/drm_device.h
> > +++ b/include/drm/drm_device.h
> > @@ -88,9 +88,12 @@ struct drm_device {
> >  	/**
> >  	 * @dev_private:
> >  	 *
> > -	 * DRM driver private data. Instead of using this pointer it is
> > -	 * recommended that drivers use drm_dev_init() and embed struct
> > -	 * &drm_device in their larger per-device structure.
> > +	 * DRM driver private data. This is deprecated and should be left set to
> > +	 * NULL.
> > +	 *
> > +	 * Instead of using this pointer it is recommended that drivers use
> > +	 * drm_dev_init() and embed struct &drm_device in their larger
> > +	 * per-device structure.
> >  	 */
> >  	void *dev_private;
> >  
> > -- 
> > 2.25.1
> > 
> > _______________________________________________
> > dri-devel mailing list
> > dri-devel@lists.freedesktop.org
> > https://lists.freedesktop.org/mailman/listinfo/dri-devel

Patch
diff mbox series

diff --git a/include/drm/drm_device.h b/include/drm/drm_device.h
index d39132b477dd..a55874db9dd4 100644
--- a/include/drm/drm_device.h
+++ b/include/drm/drm_device.h
@@ -88,9 +88,12 @@  struct drm_device {
 	/**
 	 * @dev_private:
 	 *
-	 * DRM driver private data. Instead of using this pointer it is
-	 * recommended that drivers use drm_dev_init() and embed struct
-	 * &drm_device in their larger per-device structure.
+	 * DRM driver private data. This is deprecated and should be left set to
+	 * NULL.
+	 *
+	 * Instead of using this pointer it is recommended that drivers use
+	 * drm_dev_init() and embed struct &drm_device in their larger
+	 * per-device structure.
 	 */
 	void *dev_private;