dri-devel.lists.freedesktop.org archive mirror
 help / color / mirror / Atom feed
* [PATCH 1/5] drm/imx: ipuv3 plane: Introduce ipu_plane_cleanup()
@ 2015-11-20  8:14 Liu Ying
  2015-11-20  8:14 ` [PATCH 2/5] drm/imx: ipuv3 crtc: Cleanup ipu planes in ipu_crtc_init() when necessary Liu Ying
                   ` (4 more replies)
  0 siblings, 5 replies; 15+ messages in thread
From: Liu Ying @ 2015-11-20  8:14 UTC (permalink / raw)
  To: dri-devel

This patch adds a helper ipu_plane_cleanup() to cleanup a IPU plane.
It can be used in the bailout path of ipu_crtc_init(), for instance.

Signed-off-by: Liu Ying <Ying.Liu@freescale.com>
---
This patch applies to the imx-drm/fixes branch of Philipp Zabel's open git.

 drivers/gpu/drm/imx/ipuv3-plane.c | 6 ++++++
 drivers/gpu/drm/imx/ipuv3-plane.h | 2 ++
 2 files changed, 8 insertions(+)

diff --git a/drivers/gpu/drm/imx/ipuv3-plane.c b/drivers/gpu/drm/imx/ipuv3-plane.c
index e2ff410..e60b382 100644
--- a/drivers/gpu/drm/imx/ipuv3-plane.c
+++ b/drivers/gpu/drm/imx/ipuv3-plane.c
@@ -410,3 +410,9 @@ struct ipu_plane *ipu_plane_init(struct drm_device *dev, struct ipu_soc *ipu,
 
 	return ipu_plane;
 }
+
+void ipu_plane_cleanup(struct ipu_plane *ipu_plane)
+{
+	drm_plane_cleanup(&ipu_plane->base);
+	kfree(ipu_plane);
+}
diff --git a/drivers/gpu/drm/imx/ipuv3-plane.h b/drivers/gpu/drm/imx/ipuv3-plane.h
index 3a443b4..dd2239c 100644
--- a/drivers/gpu/drm/imx/ipuv3-plane.h
+++ b/drivers/gpu/drm/imx/ipuv3-plane.h
@@ -36,6 +36,8 @@ struct ipu_plane *ipu_plane_init(struct drm_device *dev, struct ipu_soc *ipu,
 				 int dma, int dp, unsigned int possible_crtcs,
 				 enum drm_plane_type type);
 
+void ipu_plane_cleanup(struct ipu_plane *ipu_plane);
+
 /* Init IDMAC, DMFC, DP */
 int ipu_plane_mode_set(struct ipu_plane *plane, struct drm_crtc *crtc,
 		       struct drm_display_mode *mode,
-- 
2.5.0

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

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

end of thread, other threads:[~2016-01-25  9:56 UTC | newest]

Thread overview: 15+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2015-11-20  8:14 [PATCH 1/5] drm/imx: ipuv3 plane: Introduce ipu_plane_cleanup() Liu Ying
2015-11-20  8:14 ` [PATCH 2/5] drm/imx: ipuv3 crtc: Cleanup ipu planes in ipu_crtc_init() when necessary Liu Ying
2015-11-23 11:48   ` Philipp Zabel
2015-11-20  8:14 ` [PATCH 3/5] drm/imx: ipuv3 crtc: Cleanup ipu planes in ipu_drm_unbind() Liu Ying
2015-11-23 11:48   ` Philipp Zabel
2015-11-24  5:23     ` Liu Ying
2015-11-20  8:14 ` [PATCH 4/5] drm/imx: ipuv3 plane: Use the helper ipu_plane_cleanup() in ipu_plane_destroy() Liu Ying
2015-11-23 11:48   ` Philipp Zabel
2015-11-24  5:29     ` Liu Ying
2015-11-20  8:14 ` [PATCH 5/5] drm/imx: ipuv3 plane: Replace dev_info with dev_dbg if a plane's CRTC changes Liu Ying
2015-11-23 11:48   ` Philipp Zabel
2016-01-22  2:29     ` Liu Ying
2016-01-25  9:56       ` Philipp Zabel
2015-11-23 11:48 ` [PATCH 1/5] drm/imx: ipuv3 plane: Introduce ipu_plane_cleanup() Philipp Zabel
2015-11-24  3:31   ` Liu Ying

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).