当前位置: 首页>>代码示例>>C++>>正文


C++ drm_vblank_cleanup函数代码示例

本文整理汇总了C++中drm_vblank_cleanup函数的典型用法代码示例。如果您正苦于以下问题:C++ drm_vblank_cleanup函数的具体用法?C++ drm_vblank_cleanup怎么用?C++ drm_vblank_cleanup使用的例子?那么恭喜您, 这里精选的函数代码示例或许可以为您提供帮助。


在下文中一共展示了drm_vblank_cleanup函数的15个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C++代码示例。

示例1: evdi_driver_unload

int evdi_driver_unload(struct drm_device *dev)
{
    struct evdi_device *evdi = dev->dev_private;

    EVDI_CHECKPT();

    drm_vblank_cleanup(dev);
    drm_kms_helper_poll_fini(dev);
#if KERNEL_VERSION(4, 8, 0) <= LINUX_VERSION_CODE

#elif KERNEL_VERSION(4, 7, 0) <= LINUX_VERSION_CODE
    drm_connector_unregister_all(dev);
#else
    drm_connector_unplug_all(dev);
#endif

    evdi_fbdev_unplug(dev);
    if (evdi->cursor)
        evdi_cursor_free(evdi->cursor);
    evdi_painter_cleanup(evdi);
    evdi_stats_cleanup(evdi);
    evdi_fbdev_cleanup(dev);
    evdi_modeset_cleanup(dev);

    kfree(evdi);
    return 0;
}
开发者ID:DisplayLink,项目名称:evdi,代码行数:27,代码来源:evdi_main.c

示例2: amdgpu_irq_fini

/**
 * amdgpu_irq_fini - tear down driver interrupt info
 *
 * @adev: amdgpu device pointer
 *
 * Tears down the work irq handlers, vblank handlers, MSIs, etc. (all asics).
 */
void amdgpu_irq_fini(struct amdgpu_device *adev)
{
    unsigned i;

    drm_vblank_cleanup(adev->ddev);
    if (adev->irq.installed) {
        drm_irq_uninstall(adev->ddev);
        adev->irq.installed = false;
        if (adev->irq.msi_enabled)
            pci_disable_msi(adev->pdev);
        flush_work(&adev->hotplug_work);
    }

    for (i = 0; i < AMDGPU_MAX_IRQ_SRC_ID; ++i) {
        struct amdgpu_irq_src *src = adev->irq.sources[i];

        if (!src)
            continue;

        kfree(src->enabled_types);
        src->enabled_types = NULL;
        if (src->data) {
            kfree(src->data);
            kfree(src);
            adev->irq.sources[i] = NULL;
        }
    }
}
开发者ID:RadeonOpenCompute,项目名称:ROCK-Kernel-Driver,代码行数:35,代码来源:amdgpu_irq.c

示例3: dev_unload

static int dev_unload(struct drm_device *dev)
{
	struct omap_drm_private *priv = dev->dev_private;
	int i;

	DBG("unload: dev=%p", dev);

	drm_kms_helper_poll_fini(dev);

	if (priv->fbdev)
		omap_fbdev_free(dev);

	/* flush crtcs so the fbs get released */
	for (i = 0; i < priv->num_crtcs; i++)
		omap_crtc_flush(priv->crtcs[i]);

	omap_modeset_free(dev);
	omap_gem_deinit(dev);

	destroy_workqueue(priv->wq);

	drm_vblank_cleanup(dev);
	omap_drm_irq_uninstall(dev);

	kfree(dev->dev_private);
	dev->dev_private = NULL;

	dev_set_drvdata(dev->dev, NULL);

	return 0;
}
开发者ID:ninjablocks,项目名称:kernel-VAR-SOM-AMxx,代码行数:31,代码来源:omap_drv.c

示例4: malidp_unbind

static void malidp_unbind(struct device *dev)
{
	struct drm_device *drm = dev_get_drvdata(dev);
	struct malidp_drm *malidp = drm->dev_private;
	struct malidp_hw_device *hwdev = malidp->dev;

	if (malidp->fbdev) {
		drm_fbdev_cma_fini(malidp->fbdev);
		malidp->fbdev = NULL;
	}
	drm_kms_helper_poll_fini(drm);
	malidp_se_irq_fini(drm);
	malidp_de_irq_fini(drm);
	drm_vblank_cleanup(drm);
	component_unbind_all(dev, drm);
	of_node_put(malidp->crtc.port);
	malidp->crtc.port = NULL;
	drm_dev_unregister(drm);
	malidp_de_planes_destroy(drm);
	drm_mode_config_cleanup(drm);
	drm->dev_private = NULL;
	dev_set_drvdata(dev, NULL);
	clk_disable_unprepare(hwdev->mclk);
	clk_disable_unprepare(hwdev->aclk);
	clk_disable_unprepare(hwdev->pclk);
	drm_dev_unref(drm);
	of_reserved_mem_device_release(dev);
}
开发者ID:acton393,项目名称:linux,代码行数:28,代码来源:malidp_drv.c

示例5: vmw_kms_sou_close_display

int vmw_kms_sou_close_display(struct vmw_private *dev_priv)
{
	struct drm_device *dev = dev_priv->dev;

	drm_vblank_cleanup(dev);

	return 0;
}
开发者ID:020gzh,项目名称:linux,代码行数:8,代码来源:vmwgfx_scrn.c

示例6: radeon_irq_kms_fini

/**
 * radeon_irq_kms_fini - tear down driver interrrupt info
 *
 * @rdev: radeon device pointer
 *
 * Tears down the work irq handlers, vblank handlers, MSIs, etc. (all asics).
 */
void radeon_irq_kms_fini(struct radeon_device *rdev)
{
	drm_vblank_cleanup(rdev->ddev);
	if (rdev->irq.installed) {
		drm_irq_uninstall(rdev->ddev);
		rdev->irq.installed = false;
	}
	taskqueue_drain(rdev->tq, &rdev->hotplug_work);
}
开发者ID:mihaicarabas,项目名称:dragonfly,代码行数:16,代码来源:radeon_irq_kms.c

示例7: sun4i_drv_unbind

static void sun4i_drv_unbind(struct device *dev)
{
	struct drm_device *drm = dev_get_drvdata(dev);

	drm_dev_unregister(drm);
	drm_kms_helper_poll_fini(drm);
	sun4i_framebuffer_free(drm);
	drm_vblank_cleanup(drm);
	drm_dev_unref(drm);
}
开发者ID:AK101111,项目名称:linux,代码行数:10,代码来源:sun4i_drv.c

示例8: fsl_dcu_unload

static int fsl_dcu_unload(struct drm_device *dev)
{
	drm_mode_config_cleanup(dev);
	drm_vblank_cleanup(dev);
	drm_irq_uninstall(dev);

	dev->dev_private = NULL;

	return 0;
}
开发者ID:BigeyeDestroyer,项目名称:linux,代码行数:10,代码来源:fsl_dcu_drm_drv.c

示例9: radeon_irq_kms_fini

void radeon_irq_kms_fini(struct radeon_device *rdev)
{
	drm_vblank_cleanup(rdev->ddev);
	if (rdev->irq.installed) {
		drm_irq_uninstall(rdev->ddev);
		rdev->irq.installed = false;
		if (rdev->msi_enabled)
			pci_disable_msi(rdev->pdev);
	}
}
开发者ID:AdrianHuang,项目名称:uclinux-robutest,代码行数:10,代码来源:radeon_irq_kms.c

示例10: shmob_drm_unload

static int shmob_drm_unload(struct drm_device *dev)
{
	drm_kms_helper_poll_fini(dev);
	drm_mode_config_cleanup(dev);
	drm_vblank_cleanup(dev);
	drm_irq_uninstall(dev);

	dev->dev_private = NULL;

	return 0;
}
开发者ID:03199618,项目名称:linux,代码行数:11,代码来源:shmob_drm_drv.c

示例11: sun4i_drv_unbind

static void sun4i_drv_unbind(struct device *dev)
{
	struct drm_device *drm = dev_get_drvdata(dev);

	drm_dev_unregister(drm);
	drm_kms_helper_poll_fini(drm);
	sun4i_framebuffer_free(drm);
	drm_mode_config_cleanup(drm);
	drm_vblank_cleanup(drm);
	of_reserved_mem_device_release(dev);
	drm_dev_unref(drm);
}
开发者ID:asmalldev,项目名称:linux,代码行数:12,代码来源:sun4i_drv.c

示例12: vmw_kms_close_screen_object_display

int vmw_kms_close_screen_object_display(struct vmw_private *dev_priv)
{
	struct drm_device *dev = dev_priv->dev;

	if (!dev_priv->sou_priv)
		return -ENOSYS;

	drm_vblank_cleanup(dev);

	kfree(dev_priv->sou_priv);

	return 0;
}
开发者ID:Astralix,项目名称:mainline-dss11,代码行数:13,代码来源:vmwgfx_scrn.c

示例13: udl_driver_unload

int udl_driver_unload(struct drm_device *dev)
{
	struct udl_device *udl = dev->dev_private;

	drm_vblank_cleanup(dev);

	if (udl->urbs.count)
		udl_free_urb_list(dev);

	udl_fbdev_cleanup(dev);
	udl_modeset_cleanup(dev);
	kfree(udl);
	return 0;
}
开发者ID:forgivemyheart,项目名称:linux,代码行数:14,代码来源:udl_main.c

示例14: arcpgu_unload

static int arcpgu_unload(struct drm_device *drm)
{
	struct arcpgu_drm_private *arcpgu = drm->dev_private;

	if (arcpgu->fbdev) {
		drm_fbdev_cma_fini(arcpgu->fbdev);
		arcpgu->fbdev = NULL;
	}
	drm_kms_helper_poll_fini(drm);
	drm_vblank_cleanup(drm);
	drm_mode_config_cleanup(drm);

	return 0;
}
开发者ID:AK101111,项目名称:linux,代码行数:14,代码来源:arcpgu_drv.c

示例15: vmw_kms_sou_init_display

int vmw_kms_sou_init_display(struct vmw_private *dev_priv)
{
	struct drm_device *dev = dev_priv->dev;
	int i, ret;

	if (dev_priv->sou_priv) {
		DRM_INFO("sou system already on\n");
		return -EINVAL;
	}

	if (!(dev_priv->capabilities & SVGA_CAP_SCREEN_OBJECT_2)) {
		DRM_INFO("Not using screen objects,"
			 " missing cap SCREEN_OBJECT_2\n");
		return -ENOSYS;
	}

	ret = -ENOMEM;
	dev_priv->sou_priv = kmalloc(sizeof(*dev_priv->sou_priv), GFP_KERNEL);
	if (unlikely(!dev_priv->sou_priv))
		goto err_no_mem;

	dev_priv->sou_priv->num_implicit = 0;
	dev_priv->sou_priv->implicit_fb = NULL;

	ret = drm_vblank_init(dev, VMWGFX_NUM_DISPLAY_UNITS);
	if (unlikely(ret != 0))
		goto err_free;

	ret = drm_mode_create_dirty_info_property(dev);
	if (unlikely(ret != 0))
		goto err_vblank_cleanup;

	for (i = 0; i < VMWGFX_NUM_DISPLAY_UNITS; ++i)
		vmw_sou_init(dev_priv, i);

	dev_priv->active_display_unit = vmw_du_screen_object;

	DRM_INFO("Screen Objects Display Unit initialized\n");

	return 0;

err_vblank_cleanup:
	drm_vblank_cleanup(dev);
err_free:
	kfree(dev_priv->sou_priv);
	dev_priv->sou_priv = NULL;
err_no_mem:
	return ret;
}
开发者ID:DenisLug,项目名称:mptcp,代码行数:49,代码来源:vmwgfx_scrn.c


注:本文中的drm_vblank_cleanup函数示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。