Commit 6091ede9 authored by Su Hui's avatar Su Hui Committed by Alex Deucher

drm/radeon: Remove unnecessary (void*) conversions

No need cast (void*) to (struct radeon_device *)
or (struct radeon_ring *).
Signed-off-by: default avatarSu Hui <suhui@nfschina.com>
Signed-off-by: default avatarAlex Deucher <alexander.deucher@amd.com>
parent 1385d88c
...@@ -2929,7 +2929,7 @@ static void r100_set_safe_registers(struct radeon_device *rdev) ...@@ -2929,7 +2929,7 @@ static void r100_set_safe_registers(struct radeon_device *rdev)
#if defined(CONFIG_DEBUG_FS) #if defined(CONFIG_DEBUG_FS)
static int r100_debugfs_rbbm_info_show(struct seq_file *m, void *unused) static int r100_debugfs_rbbm_info_show(struct seq_file *m, void *unused)
{ {
struct radeon_device *rdev = (struct radeon_device *)m->private; struct radeon_device *rdev = m->private;
uint32_t reg, value; uint32_t reg, value;
unsigned i; unsigned i;
...@@ -2948,7 +2948,7 @@ static int r100_debugfs_rbbm_info_show(struct seq_file *m, void *unused) ...@@ -2948,7 +2948,7 @@ static int r100_debugfs_rbbm_info_show(struct seq_file *m, void *unused)
static int r100_debugfs_cp_ring_info_show(struct seq_file *m, void *unused) static int r100_debugfs_cp_ring_info_show(struct seq_file *m, void *unused)
{ {
struct radeon_device *rdev = (struct radeon_device *)m->private; struct radeon_device *rdev = m->private;
struct radeon_ring *ring = &rdev->ring[RADEON_RING_TYPE_GFX_INDEX]; struct radeon_ring *ring = &rdev->ring[RADEON_RING_TYPE_GFX_INDEX];
uint32_t rdp, wdp; uint32_t rdp, wdp;
unsigned count, i, j; unsigned count, i, j;
...@@ -2974,7 +2974,7 @@ static int r100_debugfs_cp_ring_info_show(struct seq_file *m, void *unused) ...@@ -2974,7 +2974,7 @@ static int r100_debugfs_cp_ring_info_show(struct seq_file *m, void *unused)
static int r100_debugfs_cp_csq_fifo_show(struct seq_file *m, void *unused) static int r100_debugfs_cp_csq_fifo_show(struct seq_file *m, void *unused)
{ {
struct radeon_device *rdev = (struct radeon_device *)m->private; struct radeon_device *rdev = m->private;
uint32_t csq_stat, csq2_stat, tmp; uint32_t csq_stat, csq2_stat, tmp;
unsigned r_rptr, r_wptr, ib1_rptr, ib1_wptr, ib2_rptr, ib2_wptr; unsigned r_rptr, r_wptr, ib1_rptr, ib1_wptr, ib2_rptr, ib2_wptr;
unsigned i; unsigned i;
...@@ -3022,7 +3022,7 @@ static int r100_debugfs_cp_csq_fifo_show(struct seq_file *m, void *unused) ...@@ -3022,7 +3022,7 @@ static int r100_debugfs_cp_csq_fifo_show(struct seq_file *m, void *unused)
static int r100_debugfs_mc_info_show(struct seq_file *m, void *unused) static int r100_debugfs_mc_info_show(struct seq_file *m, void *unused)
{ {
struct radeon_device *rdev = (struct radeon_device *)m->private; struct radeon_device *rdev = m->private;
uint32_t tmp; uint32_t tmp;
tmp = RREG32(RADEON_CONFIG_MEMSIZE); tmp = RREG32(RADEON_CONFIG_MEMSIZE);
......
...@@ -589,7 +589,7 @@ int rv370_get_pcie_lanes(struct radeon_device *rdev) ...@@ -589,7 +589,7 @@ int rv370_get_pcie_lanes(struct radeon_device *rdev)
#if defined(CONFIG_DEBUG_FS) #if defined(CONFIG_DEBUG_FS)
static int rv370_debugfs_pcie_gart_info_show(struct seq_file *m, void *unused) static int rv370_debugfs_pcie_gart_info_show(struct seq_file *m, void *unused)
{ {
struct radeon_device *rdev = (struct radeon_device *)m->private; struct radeon_device *rdev = m->private;
uint32_t tmp; uint32_t tmp;
tmp = RREG32_PCIE(RADEON_PCIE_TX_GART_CNTL); tmp = RREG32_PCIE(RADEON_PCIE_TX_GART_CNTL);
......
...@@ -474,7 +474,7 @@ int r420_init(struct radeon_device *rdev) ...@@ -474,7 +474,7 @@ int r420_init(struct radeon_device *rdev)
#if defined(CONFIG_DEBUG_FS) #if defined(CONFIG_DEBUG_FS)
static int r420_debugfs_pipes_info_show(struct seq_file *m, void *unused) static int r420_debugfs_pipes_info_show(struct seq_file *m, void *unused)
{ {
struct radeon_device *rdev = (struct radeon_device *)m->private; struct radeon_device *rdev = m->private;
uint32_t tmp; uint32_t tmp;
tmp = RREG32(R400_GB_PIPE_SELECT); tmp = RREG32(R400_GB_PIPE_SELECT);
......
...@@ -4345,7 +4345,7 @@ int r600_irq_process(struct radeon_device *rdev) ...@@ -4345,7 +4345,7 @@ int r600_irq_process(struct radeon_device *rdev)
static int r600_debugfs_mc_info_show(struct seq_file *m, void *unused) static int r600_debugfs_mc_info_show(struct seq_file *m, void *unused)
{ {
struct radeon_device *rdev = (struct radeon_device *)m->private; struct radeon_device *rdev = m->private;
DREG32_SYS(m, rdev, R_000E50_SRBM_STATUS); DREG32_SYS(m, rdev, R_000E50_SRBM_STATUS);
DREG32_SYS(m, rdev, VM_L2_STATUS); DREG32_SYS(m, rdev, VM_L2_STATUS);
......
...@@ -955,7 +955,7 @@ void radeon_fence_driver_force_completion(struct radeon_device *rdev, int ring) ...@@ -955,7 +955,7 @@ void radeon_fence_driver_force_completion(struct radeon_device *rdev, int ring)
#if defined(CONFIG_DEBUG_FS) #if defined(CONFIG_DEBUG_FS)
static int radeon_debugfs_fence_info_show(struct seq_file *m, void *data) static int radeon_debugfs_fence_info_show(struct seq_file *m, void *data)
{ {
struct radeon_device *rdev = (struct radeon_device *)m->private; struct radeon_device *rdev = m->private;
int i, j; int i, j;
for (i = 0; i < RADEON_NUM_RINGS; ++i) { for (i = 0; i < RADEON_NUM_RINGS; ++i) {
......
...@@ -879,7 +879,7 @@ int radeon_mode_dumb_create(struct drm_file *file_priv, ...@@ -879,7 +879,7 @@ int radeon_mode_dumb_create(struct drm_file *file_priv,
#if defined(CONFIG_DEBUG_FS) #if defined(CONFIG_DEBUG_FS)
static int radeon_debugfs_gem_info_show(struct seq_file *m, void *unused) static int radeon_debugfs_gem_info_show(struct seq_file *m, void *unused)
{ {
struct radeon_device *rdev = (struct radeon_device *)m->private; struct radeon_device *rdev = m->private;
struct radeon_bo *rbo; struct radeon_bo *rbo;
unsigned i = 0; unsigned i = 0;
......
...@@ -292,7 +292,7 @@ int radeon_ib_ring_tests(struct radeon_device *rdev) ...@@ -292,7 +292,7 @@ int radeon_ib_ring_tests(struct radeon_device *rdev)
static int radeon_debugfs_sa_info_show(struct seq_file *m, void *unused) static int radeon_debugfs_sa_info_show(struct seq_file *m, void *unused)
{ {
struct radeon_device *rdev = (struct radeon_device *)m->private; struct radeon_device *rdev = m->private;
radeon_sa_bo_dump_debug_info(&rdev->ring_tmp_bo, m); radeon_sa_bo_dump_debug_info(&rdev->ring_tmp_bo, m);
......
...@@ -1916,7 +1916,7 @@ static void radeon_dynpm_idle_work_handler(struct work_struct *work) ...@@ -1916,7 +1916,7 @@ static void radeon_dynpm_idle_work_handler(struct work_struct *work)
static int radeon_debugfs_pm_info_show(struct seq_file *m, void *unused) static int radeon_debugfs_pm_info_show(struct seq_file *m, void *unused)
{ {
struct radeon_device *rdev = (struct radeon_device *)m->private; struct radeon_device *rdev = m->private;
struct drm_device *ddev = rdev->ddev; struct drm_device *ddev = rdev->ddev;
if ((rdev->flags & RADEON_IS_PX) && if ((rdev->flags & RADEON_IS_PX) &&
......
...@@ -464,7 +464,7 @@ void radeon_ring_fini(struct radeon_device *rdev, struct radeon_ring *ring) ...@@ -464,7 +464,7 @@ void radeon_ring_fini(struct radeon_device *rdev, struct radeon_ring *ring)
static int radeon_debugfs_ring_info_show(struct seq_file *m, void *unused) static int radeon_debugfs_ring_info_show(struct seq_file *m, void *unused)
{ {
struct radeon_ring *ring = (struct radeon_ring *) m->private; struct radeon_ring *ring = m->private;
struct radeon_device *rdev = ring->rdev; struct radeon_device *rdev = ring->rdev;
uint32_t rptr, wptr, rptr_next; uint32_t rptr, wptr, rptr_next;
......
...@@ -780,7 +780,7 @@ void radeon_ttm_set_active_vram_size(struct radeon_device *rdev, u64 size) ...@@ -780,7 +780,7 @@ void radeon_ttm_set_active_vram_size(struct radeon_device *rdev, u64 size)
static int radeon_ttm_page_pool_show(struct seq_file *m, void *data) static int radeon_ttm_page_pool_show(struct seq_file *m, void *data)
{ {
struct radeon_device *rdev = (struct radeon_device *)m->private; struct radeon_device *rdev = m->private;
return ttm_pool_debugfs(&rdev->mman.bdev.pool, m); return ttm_pool_debugfs(&rdev->mman.bdev.pool, m);
} }
......
...@@ -307,7 +307,7 @@ void rs400_mc_wreg(struct radeon_device *rdev, uint32_t reg, uint32_t v) ...@@ -307,7 +307,7 @@ void rs400_mc_wreg(struct radeon_device *rdev, uint32_t reg, uint32_t v)
#if defined(CONFIG_DEBUG_FS) #if defined(CONFIG_DEBUG_FS)
static int rs400_debugfs_gart_info_show(struct seq_file *m, void *unused) static int rs400_debugfs_gart_info_show(struct seq_file *m, void *unused)
{ {
struct radeon_device *rdev = (struct radeon_device *)m->private; struct radeon_device *rdev = m->private;
uint32_t tmp; uint32_t tmp;
tmp = RREG32(RADEON_HOST_PATH_CNTL); tmp = RREG32(RADEON_HOST_PATH_CNTL);
......
...@@ -221,7 +221,7 @@ void rv515_mc_wreg(struct radeon_device *rdev, uint32_t reg, uint32_t v) ...@@ -221,7 +221,7 @@ void rv515_mc_wreg(struct radeon_device *rdev, uint32_t reg, uint32_t v)
#if defined(CONFIG_DEBUG_FS) #if defined(CONFIG_DEBUG_FS)
static int rv515_debugfs_pipes_info_show(struct seq_file *m, void *unused) static int rv515_debugfs_pipes_info_show(struct seq_file *m, void *unused)
{ {
struct radeon_device *rdev = (struct radeon_device *)m->private; struct radeon_device *rdev = m->private;
uint32_t tmp; uint32_t tmp;
tmp = RREG32(GB_PIPE_SELECT); tmp = RREG32(GB_PIPE_SELECT);
...@@ -237,7 +237,7 @@ static int rv515_debugfs_pipes_info_show(struct seq_file *m, void *unused) ...@@ -237,7 +237,7 @@ static int rv515_debugfs_pipes_info_show(struct seq_file *m, void *unused)
static int rv515_debugfs_ga_info_show(struct seq_file *m, void *unused) static int rv515_debugfs_ga_info_show(struct seq_file *m, void *unused)
{ {
struct radeon_device *rdev = (struct radeon_device *)m->private; struct radeon_device *rdev = m->private;
uint32_t tmp; uint32_t tmp;
tmp = RREG32(0x2140); tmp = RREG32(0x2140);
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment