Lines Matching refs:drm_dev

51 int rockchip_drm_dma_attach_device(struct drm_device *drm_dev,  in rockchip_drm_dma_attach_device()  argument
54 struct rockchip_drm_private *private = drm_dev->dev_private; in rockchip_drm_dma_attach_device()
78 void rockchip_drm_dma_detach_device(struct drm_device *drm_dev, in rockchip_drm_dma_detach_device() argument
81 struct rockchip_drm_private *private = drm_dev->dev_private; in rockchip_drm_dma_detach_device()
89 void rockchip_drm_dma_init_device(struct drm_device *drm_dev, in rockchip_drm_dma_init_device() argument
92 struct rockchip_drm_private *private = drm_dev->dev_private; in rockchip_drm_dma_init_device()
100 static int rockchip_drm_init_iommu(struct drm_device *drm_dev) in rockchip_drm_init_iommu() argument
102 struct rockchip_drm_private *private = drm_dev->dev_private; in rockchip_drm_init_iommu()
125 static void rockchip_iommu_cleanup(struct drm_device *drm_dev) in rockchip_iommu_cleanup() argument
127 struct rockchip_drm_private *private = drm_dev->dev_private; in rockchip_iommu_cleanup()
138 struct drm_device *drm_dev; in rockchip_drm_bind() local
151 drm_dev = drm_dev_alloc(&rockchip_drm_driver, dev); in rockchip_drm_bind()
152 if (IS_ERR(drm_dev)) in rockchip_drm_bind()
153 return PTR_ERR(drm_dev); in rockchip_drm_bind()
155 dev_set_drvdata(dev, drm_dev); in rockchip_drm_bind()
157 private = devm_kzalloc(drm_dev->dev, sizeof(*private), GFP_KERNEL); in rockchip_drm_bind()
163 drm_dev->dev_private = private; in rockchip_drm_bind()
165 ret = drmm_mode_config_init(drm_dev); in rockchip_drm_bind()
169 rockchip_drm_mode_config_init(drm_dev); in rockchip_drm_bind()
172 ret = component_bind_all(dev, drm_dev); in rockchip_drm_bind()
176 ret = rockchip_drm_init_iommu(drm_dev); in rockchip_drm_bind()
180 ret = drm_vblank_init(drm_dev, drm_dev->mode_config.num_crtc); in rockchip_drm_bind()
184 drm_mode_config_reset(drm_dev); in rockchip_drm_bind()
187 drm_kms_helper_poll_init(drm_dev); in rockchip_drm_bind()
189 ret = drm_dev_register(drm_dev, 0); in rockchip_drm_bind()
193 drm_fbdev_generic_setup(drm_dev, 0); in rockchip_drm_bind()
197 drm_kms_helper_poll_fini(drm_dev); in rockchip_drm_bind()
199 rockchip_iommu_cleanup(drm_dev); in rockchip_drm_bind()
201 component_unbind_all(dev, drm_dev); in rockchip_drm_bind()
203 drm_dev_put(drm_dev); in rockchip_drm_bind()
209 struct drm_device *drm_dev = dev_get_drvdata(dev); in rockchip_drm_unbind() local
211 drm_dev_unregister(drm_dev); in rockchip_drm_unbind()
213 drm_kms_helper_poll_fini(drm_dev); in rockchip_drm_unbind()
215 drm_atomic_helper_shutdown(drm_dev); in rockchip_drm_unbind()
216 component_unbind_all(dev, drm_dev); in rockchip_drm_unbind()
217 rockchip_iommu_cleanup(drm_dev); in rockchip_drm_unbind()
219 drm_dev_put(drm_dev); in rockchip_drm_unbind()