Merge tag 'drm-misc-next-2017-01-09' of git://anongit.freedesktop.org/git/drm-misc into drm-next
Back to regular -misc pulls with reasonable sizes: - dma_fence error clarification (Chris) - drm_crtc_from_index helper (Shawn), pile more patches on the m-l to roll this out to drivers - mmu-less support for fbdev helpers from Benjamin - piles of kerneldoc work - some polish for crc support from Tomeu and Benjamin - odd misc stuff all over * tag 'drm-misc-next-2017-01-09' of git://anongit.freedesktop.org/git/drm-misc: (48 commits) dma-fence: Introduce drm_fence_set_error() helper dma-fence: Wrap querying the fence->status dma-fence: Clear fence->status during dma_fence_init() drm: fix compilations issues introduced by "drm: allow to use mmuless SoC" drm: Change the return type of the unload hook to void drm: add more document for drm_crtc_from_index() drm: remove useless parameters from drm_pick_cmdline_mode function drm: crc: Call wake_up_interruptible() each time there is a new CRC entry drm: allow to use mmuless SoC drm: compile drm_vm.c only when needed fbmem: add a default get_fb_unmapped_area function drm: crc: Wait for a frame before returning from open() drm: Move locking into drm_debugfs_crtc_crc_add drm/imx: imx-tve: Remove unused variable Revert "drm: nouveau: fix build when LEDS_CLASS=m" drm: Add kernel-doc for drm_crtc_commit_get/put drm/atomic: Fix outdated comment. drm: reference count event->completion gpu: drm: mgag200: mgag200_main:- Handle error from pci_iomap drm: Document deprecated load/unload hook ...
This commit is contained in:
@@ -1711,7 +1711,7 @@ extern const struct drm_ioctl_desc amdgpu_ioctls_kms[];
|
||||
extern const int amdgpu_max_kms_ioctl;
|
||||
|
||||
int amdgpu_driver_load_kms(struct drm_device *dev, unsigned long flags);
|
||||
int amdgpu_driver_unload_kms(struct drm_device *dev);
|
||||
void amdgpu_driver_unload_kms(struct drm_device *dev);
|
||||
void amdgpu_driver_lastclose_kms(struct drm_device *dev);
|
||||
int amdgpu_driver_open_kms(struct drm_device *dev, struct drm_file *file_priv);
|
||||
void amdgpu_driver_postclose_kms(struct drm_device *dev,
|
||||
|
@@ -235,9 +235,10 @@ static void amdgpu_gtt_mgr_debug(struct ttm_mem_type_manager *man,
|
||||
const char *prefix)
|
||||
{
|
||||
struct amdgpu_gtt_mgr *mgr = man->priv;
|
||||
struct drm_printer p = drm_debug_printer(prefix);
|
||||
|
||||
spin_lock(&mgr->lock);
|
||||
drm_mm_debug_table(&mgr->mm, prefix);
|
||||
drm_mm_print(&mgr->mm, &p);
|
||||
spin_unlock(&mgr->lock);
|
||||
}
|
||||
|
||||
|
@@ -50,12 +50,12 @@ static inline bool amdgpu_has_atpx(void) { return false; }
|
||||
* This is the main unload function for KMS (all asics).
|
||||
* Returns 0 on success.
|
||||
*/
|
||||
int amdgpu_driver_unload_kms(struct drm_device *dev)
|
||||
void amdgpu_driver_unload_kms(struct drm_device *dev)
|
||||
{
|
||||
struct amdgpu_device *adev = dev->dev_private;
|
||||
|
||||
if (adev == NULL)
|
||||
return 0;
|
||||
return;
|
||||
|
||||
if (adev->rmmio == NULL)
|
||||
goto done_free;
|
||||
@@ -74,7 +74,6 @@ int amdgpu_driver_unload_kms(struct drm_device *dev)
|
||||
done_free:
|
||||
kfree(adev);
|
||||
dev->dev_private = NULL;
|
||||
return 0;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@@ -1482,18 +1482,18 @@ static int amdgpu_mm_dump_table(struct seq_file *m, void *data)
|
||||
struct drm_device *dev = node->minor->dev;
|
||||
struct amdgpu_device *adev = dev->dev_private;
|
||||
struct drm_mm *mm = (struct drm_mm *)adev->mman.bdev.man[ttm_pl].priv;
|
||||
int ret;
|
||||
struct ttm_bo_global *glob = adev->mman.bdev.glob;
|
||||
struct drm_printer p = drm_seq_file_printer(m);
|
||||
|
||||
spin_lock(&glob->lru_lock);
|
||||
ret = drm_mm_dump_table(m, mm);
|
||||
drm_mm_print(mm, &p);
|
||||
spin_unlock(&glob->lru_lock);
|
||||
if (ttm_pl == TTM_PL_VRAM)
|
||||
seq_printf(m, "man size:%llu pages, ram usage:%lluMB, vis usage:%lluMB\n",
|
||||
adev->mman.bdev.man[ttm_pl].size,
|
||||
(u64)atomic64_read(&adev->vram_usage) >> 20,
|
||||
(u64)atomic64_read(&adev->vram_vis_usage) >> 20);
|
||||
return ret;
|
||||
return 0;
|
||||
}
|
||||
|
||||
static int ttm_pl_vram = TTM_PL_VRAM;
|
||||
|
@@ -207,9 +207,10 @@ static void amdgpu_vram_mgr_debug(struct ttm_mem_type_manager *man,
|
||||
const char *prefix)
|
||||
{
|
||||
struct amdgpu_vram_mgr *mgr = man->priv;
|
||||
struct drm_printer p = drm_debug_printer(prefix);
|
||||
|
||||
spin_lock(&mgr->lock);
|
||||
drm_mm_debug_table(&mgr->mm, prefix);
|
||||
drm_mm_print(&mgr->mm, &p);
|
||||
spin_unlock(&mgr->lock);
|
||||
}
|
||||
|
||||
|
Reference in New Issue
Block a user