drm/amdgpu: remove duplicated codes

Submitted by Zhou, David(ChunMing) on June 27, 2018, 7:28 a.m.

Details

Message ID BY1PR12MB0502E0CB36964B09BB3536EEB4480@BY1PR12MB0502.namprd12.prod.outlook.com
State New
Headers show
Series "drm/amdgpu: remove duplicated codes" ( rev: 4 ) in AMD X.Org drivers

Not browsing as part of any series.

Commit Message

Zhou, David(ChunMing) June 27, 2018, 7:28 a.m.
Feel free add my RB on that.

Thanks,
David Zhou

-----Original Message-----
From: amd-gfx [mailto:amd-gfx-bounces@lists.freedesktop.org] On Behalf Of Flora Cui

Sent: Wednesday, June 27, 2018 3:06 PM
To: Zhou, David(ChunMing) <David1.Zhou@amd.com>
Cc: amd-gfx@lists.freedesktop.org
Subject: Re: [PATCH] drm/amdgpu: remove duplicated codes


the fence_context and seqno is init in amdgpu_vm_manager_init() & amdgpu_vmid_mgr_init(). remove the amdgpu_vmid_mgr_init() copy.

Change-Id: Ic0dbd693bac093e54eb95b5e547c89b64a5743b8
Signed-off-by: Flora Cui <Flora.Cui@amd.com>

---
 drivers/gpu/drm/amd/amdgpu/amdgpu_ids.c | 5 -----
 1 file changed, 5 deletions(-)

--
2.7.4

On Wed, Jun 27, 2018 at 02:38:09PM +0800, Zhou, David(ChunMing) wrote:
> Please add patch's comment to describe where and where are duplicated.

> 

> -----Original Message-----

> From: amd-gfx [mailto:amd-gfx-bounces@lists.freedesktop.org] On Behalf 

> Of Flora Cui

> Sent: Wednesday, June 27, 2018 2:10 PM

> To: amd-gfx@lists.freedesktop.org

> Cc: Cui, Flora <Flora.Cui@amd.com>

> Subject: [PATCH] drm/amdgpu: remove duplicated codes

> 

> Change-Id: Ic0dbd693bac093e54eb95b5e547c89b64a5743b8

> Signed-off-by: Flora Cui <Flora.Cui@amd.com>

> ---

>  drivers/gpu/drm/amd/amdgpu/amdgpu_ids.c | 5 -----

>  1 file changed, 5 deletions(-)

> 

> diff --git a/drivers/gpu/drm/amd/amdgpu/amdgpu_ids.c 

> b/drivers/gpu/drm/amd/amdgpu/amdgpu_ids.c

> index a1c78f9..3a072a7 100644

> --- a/drivers/gpu/drm/amd/amdgpu/amdgpu_ids.c

> +++ b/drivers/gpu/drm/amd/amdgpu/amdgpu_ids.c

> @@ -578,11 +578,6 @@ void amdgpu_vmid_mgr_init(struct amdgpu_device *adev)

>  			list_add_tail(&id_mgr->ids[j].list, &id_mgr->ids_lru);

>  		}

>  	}

> -

> -	adev->vm_manager.fence_context =

> -		dma_fence_context_alloc(AMDGPU_MAX_RINGS);

> -	for (i = 0; i < AMDGPU_MAX_RINGS; ++i)

> -		adev->vm_manager.seqno[i] = 0;

>  }

>  

>  /**

> --

> 2.7.4

> 

> _______________________________________________

> amd-gfx mailing list

> amd-gfx@lists.freedesktop.org

> https://lists.freedesktop.org/mailman/listinfo/amd-gfx

_______________________________________________
amd-gfx mailing list
amd-gfx@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/amd-gfx

Patch hide | download patch | download mbox

diff --git a/drivers/gpu/drm/amd/amdgpu/amdgpu_ids.c b/drivers/gpu/drm/amd/amdgpu/amdgpu_ids.c
index a1c78f9..3a072a7 100644
--- a/drivers/gpu/drm/amd/amdgpu/amdgpu_ids.c
+++ b/drivers/gpu/drm/amd/amdgpu/amdgpu_ids.c
@@ -578,11 +578,6 @@  void amdgpu_vmid_mgr_init(struct amdgpu_device *adev)
 			list_add_tail(&id_mgr->ids[j].list, &id_mgr->ids_lru);
 		}
 	}
-
-	adev->vm_manager.fence_context =
-		dma_fence_context_alloc(AMDGPU_MAX_RINGS);
-	for (i = 0; i < AMDGPU_MAX_RINGS; ++i)
-		adev->vm_manager.seqno[i] = 0;
 }
 
 /**