[PATCH v5 20/25] drm: kirin: Rename plane_init and crtc_init
John Stultz
john.stultz at linaro.org
Tue Aug 20 23:06:21 UTC 2019
From: Xu YiPing <xuyiping at hisilicon.com>
As part of refactoring the kirin driver to better support
different hardware revisions, this patch renames
ade_crtc/plane_init kirin_plane/crtc_init, as they will later be
moved to kirin drm drv and shared with the kirin960 hardware
support.
Cc: Rongrong Zou <zourongrong at gmail.com>
Cc: Xinliang Liu <z.liuxinliang at hisilicon.com>
Cc: David Airlie <airlied at linux.ie>
Cc: Daniel Vetter <daniel at ffwll.ch>
Cc: dri-devel <dri-devel at lists.freedesktop.org>
Cc: Sam Ravnborg <sam at ravnborg.org>
Acked-by: Xinliang Liu <z.liuxinliang at hisilicon.com>
Reviewed-by: Sam Ravnborg <sam at ravnborg.org>
Signed-off-by: Xu YiPing <xuyiping at hisilicon.com>
[jstultz: reworded commit message]
Signed-off-by: John Stultz <john.stultz at linaro.org>
---
v5: checkpatch --strict whitespace fixups noticed by Sam
---
drivers/gpu/drm/hisilicon/kirin/kirin_drm_ade.c | 17 ++++++++++-------
1 file changed, 10 insertions(+), 7 deletions(-)
diff --git a/drivers/gpu/drm/hisilicon/kirin/kirin_drm_ade.c b/drivers/gpu/drm/hisilicon/kirin/kirin_drm_ade.c
index 89bdc0388138..e390b1b657b8 100644
--- a/drivers/gpu/drm/hisilicon/kirin/kirin_drm_ade.c
+++ b/drivers/gpu/drm/hisilicon/kirin/kirin_drm_ade.c
@@ -571,8 +571,8 @@ static const struct drm_crtc_funcs ade_crtc_funcs = {
.disable_vblank = ade_crtc_disable_vblank,
};
-static int ade_crtc_init(struct drm_device *dev, struct drm_crtc *crtc,
- struct drm_plane *plane)
+static int kirin_drm_crtc_init(struct drm_device *dev, struct drm_crtc *crtc,
+ struct drm_plane *plane)
{
struct device_node *port;
int ret;
@@ -892,8 +892,9 @@ static struct drm_plane_funcs ade_plane_funcs = {
.atomic_destroy_state = drm_atomic_helper_plane_destroy_state,
};
-static int ade_plane_init(struct drm_device *dev, struct kirin_plane *kplane,
- enum drm_plane_type type)
+static int kirin_drm_plane_init(struct drm_device *dev,
+ struct kirin_plane *kplane,
+ enum drm_plane_type type)
{
int ret = 0;
@@ -989,6 +990,7 @@ static int ade_drm_init(struct platform_device *pdev)
struct kirin_crtc *kcrtc;
struct kirin_plane *kplane;
enum drm_plane_type type;
+ int prim_plane;
int ret;
u32 ch;
@@ -1024,14 +1026,15 @@ static int ade_drm_init(struct platform_device *pdev)
else
type = DRM_PLANE_TYPE_OVERLAY;
- ret = ade_plane_init(dev, kplane, type);
+ ret = kirin_drm_plane_init(dev, kplane, type);
if (ret)
return ret;
}
/* crtc init */
- ret = ade_crtc_init(dev, &kcrtc->base,
- &ade->planes[ade_driver_data.prim_plane].base);
+ prim_plane = ade_driver_data.prim_plane;
+ ret = kirin_drm_crtc_init(dev, &kcrtc->base,
+ &ade->planes[prim_plane].base);
if (ret)
return ret;
--
2.17.1
More information about the dri-devel
mailing list