search for: vram_base

Displaying 20 results from an estimated 38 matches for "vram_base".

2019 Sep 09
5
[PATCH 0/4] Merge VRAM MM and GEM VRAM source files
VRAM MM and GEM VRAM are only used with each other. This patch set moves VRAM MM into GEM VRAM source files and cleans up the helper's public interface. Thomas Zimmermann (4): drm/vram: Move VRAM memory manager to GEM VRAM implementation drm/vram: Have VRAM MM call GEM VRAM functions directly drm/vram: Unexport internal functions of VRAM MM drm/vram: Unconditonally set BO call-back
2019 Sep 11
4
[PATCH v2 0/4] Merge VRAM MM and GEM VRAM source files
VRAM MM and GEM VRAM are only used with each other. This patch set moves VRAM MM into GEM VRAM source files and cleans up the helper's public interface. Version 2 of the patch set doesn't contain functional changes. I'm reposting due to the rebasing onto the debugfs patches. v2: * updated for debugfs support * fixed typos in comments Thomas Zimmermann (4): drm/vram: Move VRAM
2019 Sep 13
2
[PATCH 8/8] drm/vram: drop DRM_VRAM_MM_FILE_OPERATIONS
...--git a/include/drm/drm_gem_vram_helper.h b/include/drm/drm_gem_vram_helper.h index 9d5526650291..3503ff784803 100644 --- a/include/drm/drm_gem_vram_helper.h +++ b/include/drm/drm_gem_vram_helper.h @@ -180,22 +180,4 @@ struct drm_vram_mm *drm_vram_helper_alloc_mm( struct drm_device *dev, uint64_t vram_base, size_t vram_size); void drm_vram_helper_release_mm(struct drm_device *dev); -/** - * define DRM_VRAM_MM_FILE_OPERATIONS - default callback functions for \ - &struct file_operations - * - * Drivers that use VRAM MM can use this macro to initialize - * &struct file_operations with default...
2019 Sep 13
2
[PATCH 8/8] drm/vram: drop DRM_VRAM_MM_FILE_OPERATIONS
...--git a/include/drm/drm_gem_vram_helper.h b/include/drm/drm_gem_vram_helper.h index 9d5526650291..3503ff784803 100644 --- a/include/drm/drm_gem_vram_helper.h +++ b/include/drm/drm_gem_vram_helper.h @@ -180,22 +180,4 @@ struct drm_vram_mm *drm_vram_helper_alloc_mm( struct drm_device *dev, uint64_t vram_base, size_t vram_size); void drm_vram_helper_release_mm(struct drm_device *dev); -/** - * define DRM_VRAM_MM_FILE_OPERATIONS - default callback functions for \ - &struct file_operations - * - * Drivers that use VRAM MM can use this macro to initialize - * &struct file_operations with default...
2019 Apr 24
0
[PATCH v2 05/17] drm: Add VRAM MM, a simple memory manager for dedicated VRAM
...<< PAGE_SHIFT; + + switch (mem->mem_type) { + case TTM_PL_SYSTEM: /* nothing to do */ + mem->bus.offset = 0; + mem->bus.base = 0; + mem->bus.is_iomem = false; + break; + case TTM_PL_VRAM: + mem->bus.offset = mem->start << PAGE_SHIFT; + mem->bus.base = vmm->vram_base; + mem->bus.is_iomem = true; + break; + default: + return -EINVAL; + } + + return 0; +} + +static void bo_driver_io_mem_free(struct ttm_bo_device *bdev, + struct ttm_mem_reg *mem) +{ } + +static struct ttm_bo_driver bo_driver = { + .ttm_tt_create = bo_driver_ttm_tt_create, + .ttm_tt_popu...
2019 Sep 13
0
[PATCH 8/8] drm/vram: drop DRM_VRAM_MM_FILE_OPERATIONS
...em_vram_helper.h b/include/drm/drm_gem_vram_helper.h > index 9d5526650291..3503ff784803 100644 > --- a/include/drm/drm_gem_vram_helper.h > +++ b/include/drm/drm_gem_vram_helper.h > @@ -180,22 +180,4 @@ struct drm_vram_mm *drm_vram_helper_alloc_mm( > struct drm_device *dev, uint64_t vram_base, size_t vram_size); > void drm_vram_helper_release_mm(struct drm_device *dev); > > -/** > - * define DRM_VRAM_MM_FILE_OPERATIONS - default callback functions for \ > - &struct file_operations > - * > - * Drivers that use VRAM MM can use this macro to initialize > - *...
2018 Dec 12
0
[PATCH v2 03/18] drm/qxl: simplify slot management
...nit(qdev); if (r) { DRM_ERROR("Unable to init qxl irq\n"); - goto mem_slots_free; + goto release_ring_free; } /* * Note that virtual is surface0. We rely on the single ioremap done * before. */ - qdev->main_mem_slot = setup_slot(qdev, 0, - (unsigned long)qdev->vram_base, - (unsigned long)qdev->vram_base + qdev->rom->ram_header_offset); - qdev->surfaces_mem_slot = setup_slot(qdev, 1, - (unsigned long)qdev->surfaceram_base, - (unsigned long)qdev->surfaceram_base + qdev->surfaceram_size); - DRM_INFO("main mem slot %d [%lx,%x]\n", -...
2018 Jul 27
1
[PATCH] drm: qxl: Fix error handling at qxl_device_init
...Unable to init drm dev"); + goto error; + } qdev->ddev.pdev = pdev; pci_set_drvdata(pdev, &qdev->ddev); @@ -121,6 +123,11 @@ int qxl_device_init(struct qxl_device *qdev, qdev->io_base = pci_resource_start(pdev, 3); qdev->vram_mapping = io_mapping_create_wc(qdev->vram_base, pci_resource_len(pdev, 0)); + if (!qdev->vram_mapping) { + pr_err("Unable to create vram_mapping"); + r = -ENOMEM; + goto error; + } if (pci_resource_len(pdev, 4) > 0) { /* 64bit surface bar present */ @@ -139,6 +146,11 @@ int qxl_device_init(struct qxl_device *qdev, q...
2020 Apr 15
2
[PATCH 26/59] drm/qxl: Use devm_drm_dev_alloc
...ev); qdev->ddev.dev_private = qdev; - drmm_add_final_kfree(&qdev->ddev, qdev); mutex_init(&qdev->gem.mutex); mutex_init(&qdev->update_area_mutex); @@ -138,8 +130,7 @@ int qxl_device_init(struct qxl_device *qdev, qdev->vram_mapping = io_mapping_create_wc(qdev->vram_base, pci_resource_len(pdev, 0)); if (!qdev->vram_mapping) { pr_err("Unable to create vram_mapping"); - r = -ENOMEM; - goto error; + return -ENOMEM; } if (pci_resource_len(pdev, 4) > 0) { @@ -293,7 +284,6 @@ int qxl_device_init(struct qxl_device *qdev, io_mapping_free(qde...
2020 Apr 15
2
[PATCH 26/59] drm/qxl: Use devm_drm_dev_alloc
...ev); qdev->ddev.dev_private = qdev; - drmm_add_final_kfree(&qdev->ddev, qdev); mutex_init(&qdev->gem.mutex); mutex_init(&qdev->update_area_mutex); @@ -138,8 +130,7 @@ int qxl_device_init(struct qxl_device *qdev, qdev->vram_mapping = io_mapping_create_wc(qdev->vram_base, pci_resource_len(pdev, 0)); if (!qdev->vram_mapping) { pr_err("Unable to create vram_mapping"); - r = -ENOMEM; - goto error; + return -ENOMEM; } if (pci_resource_len(pdev, 4) > 0) { @@ -293,7 +284,6 @@ int qxl_device_init(struct qxl_device *qdev, io_mapping_free(qde...
2020 Apr 03
3
[PATCH 30/44] drm/qxl: Use devm_drm_dev_alloc
...ev); qdev->ddev.dev_private = qdev; - drmm_add_final_kfree(&qdev->ddev, qdev); mutex_init(&qdev->gem.mutex); mutex_init(&qdev->update_area_mutex); @@ -138,8 +130,7 @@ int qxl_device_init(struct qxl_device *qdev, qdev->vram_mapping = io_mapping_create_wc(qdev->vram_base, pci_resource_len(pdev, 0)); if (!qdev->vram_mapping) { pr_err("Unable to create vram_mapping"); - r = -ENOMEM; - goto error; + return -ENOMEM; } if (pci_resource_len(pdev, 4) > 0) { @@ -293,7 +284,6 @@ int qxl_device_init(struct qxl_device *qdev, io_mapping_free(qde...
2020 Apr 03
3
[PATCH 30/44] drm/qxl: Use devm_drm_dev_alloc
...ev); qdev->ddev.dev_private = qdev; - drmm_add_final_kfree(&qdev->ddev, qdev); mutex_init(&qdev->gem.mutex); mutex_init(&qdev->update_area_mutex); @@ -138,8 +130,7 @@ int qxl_device_init(struct qxl_device *qdev, qdev->vram_mapping = io_mapping_create_wc(qdev->vram_base, pci_resource_len(pdev, 0)); if (!qdev->vram_mapping) { pr_err("Unable to create vram_mapping"); - r = -ENOMEM; - goto error; + return -ENOMEM; } if (pci_resource_len(pdev, 4) > 0) { @@ -293,7 +284,6 @@ int qxl_device_init(struct qxl_device *qdev, io_mapping_free(qde...
2020 Apr 28
2
[PATCH 26/59] drm/qxl: Use devm_drm_dev_alloc
...d_final_kfree(&qdev->ddev, qdev); > > > > mutex_init(&qdev->gem.mutex); > > mutex_init(&qdev->update_area_mutex); > > @@ -138,8 +130,7 @@ int qxl_device_init(struct qxl_device *qdev, > > qdev->vram_mapping = io_mapping_create_wc(qdev->vram_base, pci_resource_len(pdev, 0)); > > if (!qdev->vram_mapping) { > > pr_err("Unable to create vram_mapping"); > > - r = -ENOMEM; > > - goto error; > > + return -ENOMEM; > > } > > > > if (pci_resource_len(pdev, 4) > 0) { > &...
2020 Apr 28
2
[PATCH 26/59] drm/qxl: Use devm_drm_dev_alloc
...d_final_kfree(&qdev->ddev, qdev); > > > > mutex_init(&qdev->gem.mutex); > > mutex_init(&qdev->update_area_mutex); > > @@ -138,8 +130,7 @@ int qxl_device_init(struct qxl_device *qdev, > > qdev->vram_mapping = io_mapping_create_wc(qdev->vram_base, pci_resource_len(pdev, 0)); > > if (!qdev->vram_mapping) { > > pr_err("Unable to create vram_mapping"); > > - r = -ENOMEM; > > - goto error; > > + return -ENOMEM; > > } > > > > if (pci_resource_len(pdev, 4) > 0) { > &...
2018 Aug 08
0
[PATCH v3] drm/cirrus: flip default from 24bpp to 16bpp
...e..91128b1d8d 100644 --- a/drivers/gpu/drm/cirrus/cirrus_mode.c +++ b/drivers/gpu/drm/cirrus/cirrus_mode.c @@ -518,7 +518,7 @@ int cirrus_modeset_init(struct cirrus_device *cdev) cdev->dev->mode_config.max_height = CIRRUS_MAX_FB_HEIGHT; cdev->dev->mode_config.fb_base = cdev->mc.vram_base; - cdev->dev->mode_config.preferred_depth = 24; + cdev->dev->mode_config.preferred_depth = cirrus_bpp; /* don't prefer a shadow on virt GPU */ cdev->dev->mode_config.prefer_shadow = 0; -- 2.9.3
2019 Oct 16
0
[PATCH v4 11/11] drm/vram: drop DRM_VRAM_MM_FILE_OPERATIONS
...--git a/include/drm/drm_gem_vram_helper.h b/include/drm/drm_gem_vram_helper.h index 5e48fdac4a1d..b8ad4531ebb4 100644 --- a/include/drm/drm_gem_vram_helper.h +++ b/include/drm/drm_gem_vram_helper.h @@ -184,22 +184,4 @@ struct drm_vram_mm *drm_vram_helper_alloc_mm( struct drm_device *dev, uint64_t vram_base, size_t vram_size); void drm_vram_helper_release_mm(struct drm_device *dev); -/** - * define DRM_VRAM_MM_FILE_OPERATIONS - default callback functions for \ - &struct file_operations - * - * Drivers that use VRAM MM can use this macro to initialize - * &struct file_operations with default...
2019 Sep 17
0
[PATCH v2 11/11] drm/vram: drop DRM_VRAM_MM_FILE_OPERATIONS
...--git a/include/drm/drm_gem_vram_helper.h b/include/drm/drm_gem_vram_helper.h index 9d5526650291..3503ff784803 100644 --- a/include/drm/drm_gem_vram_helper.h +++ b/include/drm/drm_gem_vram_helper.h @@ -180,22 +180,4 @@ struct drm_vram_mm *drm_vram_helper_alloc_mm( struct drm_device *dev, uint64_t vram_base, size_t vram_size); void drm_vram_helper_release_mm(struct drm_device *dev); -/** - * define DRM_VRAM_MM_FILE_OPERATIONS - default callback functions for \ - &struct file_operations - * - * Drivers that use VRAM MM can use this macro to initialize - * &struct file_operations with default...
2019 Sep 19
0
[PATCH v3 11/11] drm/vram: drop DRM_VRAM_MM_FILE_OPERATIONS
...--git a/include/drm/drm_gem_vram_helper.h b/include/drm/drm_gem_vram_helper.h index 05a762c87305..84b31373ddf5 100644 --- a/include/drm/drm_gem_vram_helper.h +++ b/include/drm/drm_gem_vram_helper.h @@ -183,22 +183,4 @@ struct drm_vram_mm *drm_vram_helper_alloc_mm( struct drm_device *dev, uint64_t vram_base, size_t vram_size); void drm_vram_helper_release_mm(struct drm_device *dev); -/** - * define DRM_VRAM_MM_FILE_OPERATIONS - default callback functions for \ - &struct file_operations - * - * Drivers that use VRAM MM can use this macro to initialize - * &struct file_operations with default...
2019 Apr 24
21
[PATCH v2 00/17] Share TTM code among DRM framebuffer drivers
Several simple framebuffer drivers copy most of the TTM code from each other. The implementation is always the same; except for the name of some data structures. As recently discussed, this patch set provides generic memory-management code for simple framebuffers with dedicated video memory. It further converts the respective drivers to the generic code. The shared code is basically the same
2020 Apr 24
0
[PATCH 26/59] drm/qxl: Use devm_drm_dev_alloc
...te = qdev; > - drmm_add_final_kfree(&qdev->ddev, qdev); > > mutex_init(&qdev->gem.mutex); > mutex_init(&qdev->update_area_mutex); > @@ -138,8 +130,7 @@ int qxl_device_init(struct qxl_device *qdev, > qdev->vram_mapping = io_mapping_create_wc(qdev->vram_base, pci_resource_len(pdev, 0)); > if (!qdev->vram_mapping) { > pr_err("Unable to create vram_mapping"); > - r = -ENOMEM; > - goto error; > + return -ENOMEM; > } > > if (pci_resource_len(pdev, 4) > 0) { > @@ -293,7 +284,6 @@ int qxl_device_init(s...