mirror of https://gitee.com/openkylin/linux.git
drm/vc4: Use the helper to retrieve vc4_dev when needed
We have a helper to retrieve the vc4_dev structure from the drm_device one when needed, so let's use it consistently. Acked-by: Daniel Vetter <daniel.vetter@ffwll.ch> Signed-off-by: Maxime Ripard <maxime@cerno.tech> Link: https://patchwork.freedesktop.org/patch/msgid/20201029190104.2181730-4-maxime@cerno.tech
This commit is contained in:
parent
171a072b46
commit
88e085896a
|
@ -560,7 +560,7 @@ static int vc4_hvs_bind(struct device *dev, struct device *master, void *data)
|
|||
{
|
||||
struct platform_device *pdev = to_platform_device(dev);
|
||||
struct drm_device *drm = dev_get_drvdata(master);
|
||||
struct vc4_dev *vc4 = drm->dev_private;
|
||||
struct vc4_dev *vc4 = to_vc4_dev(drm);
|
||||
struct vc4_hvs *hvs = NULL;
|
||||
int ret;
|
||||
u32 dispctrl;
|
||||
|
@ -679,7 +679,7 @@ static void vc4_hvs_unbind(struct device *dev, struct device *master,
|
|||
void *data)
|
||||
{
|
||||
struct drm_device *drm = dev_get_drvdata(master);
|
||||
struct vc4_dev *vc4 = drm->dev_private;
|
||||
struct vc4_dev *vc4 = to_vc4_dev(drm);
|
||||
struct vc4_hvs *hvs = vc4->hvs;
|
||||
|
||||
if (drm_mm_node_allocated(&vc4->hvs->mitchell_netravali_filter))
|
||||
|
|
|
@ -51,7 +51,7 @@ static struct vc4_ctm_state *vc4_get_ctm_state(struct drm_atomic_state *state,
|
|||
struct drm_private_obj *manager)
|
||||
{
|
||||
struct drm_device *dev = state->dev;
|
||||
struct vc4_dev *vc4 = dev->dev_private;
|
||||
struct vc4_dev *vc4 = to_vc4_dev(dev);
|
||||
struct drm_private_state *priv_state;
|
||||
int ret;
|
||||
|
||||
|
|
Loading…
Reference in New Issue