RE: [PATCH] drm/amdgpu: drop some kernel messages in VCN code

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



[AMD Official Use Only - AMD Internal Distribution Only]

Acked-by: Leo Liu <leo.liu@xxxxxxx>

> -----Original Message-----
> From: Wu, David <David.Wu3@xxxxxxx>
> Sent: Thursday, May 30, 2024 10:59 AM
> To: amd-gfx@xxxxxxxxxxxxxxxxxxxxx; Koenig, Christian
> <Christian.Koenig@xxxxxxx>
> Cc: Deucher, Alexander <Alexander.Deucher@xxxxxxx>; Liu, Leo
> <Leo.Liu@xxxxxxx>; Jiang, Sonny <Sonny.Jiang@xxxxxxx>; Dong, Ruijing
> <Ruijing.Dong@xxxxxxx>
> Subject: [PATCH] drm/amdgpu: drop some kernel messages in VCN code
>
> Similar to commit 15681da214b where some kernel log messages are dropped.
> With this commit, more log messages in older version of VCN/JPEG code are
> dropped.
>
> Signed-off-by: David (Ming Qiang) Wu <David.Wu3@xxxxxxx>
> ---
>  drivers/gpu/drm/amd/amdgpu/jpeg_v1_0.c   |  1 -
>  drivers/gpu/drm/amd/amdgpu/jpeg_v2_0.c   |  8 +-------
>  drivers/gpu/drm/amd/amdgpu/jpeg_v2_5.c   |  3 ---
>  drivers/gpu/drm/amd/amdgpu/jpeg_v3_0.c   | 10 +---------
>  drivers/gpu/drm/amd/amdgpu/jpeg_v4_0.c   |  3 ---
>  drivers/gpu/drm/amd/amdgpu/jpeg_v4_0_3.c |  2 --
> drivers/gpu/drm/amd/amdgpu/jpeg_v4_0_5.c |  5 -----
>  drivers/gpu/drm/amd/amdgpu/vcn_v1_0.c    | 14 ++------------
>  drivers/gpu/drm/amd/amdgpu/vcn_v2_0.c    | 14 +++-----------
>  drivers/gpu/drm/amd/amdgpu/vcn_v2_5.c    | 11 ++---------
>  drivers/gpu/drm/amd/amdgpu/vcn_v3_0.c    | 16 +++-------------
>  drivers/gpu/drm/amd/amdgpu/vcn_v4_0.c    | 14 ++------------
>  drivers/gpu/drm/amd/amdgpu/vcn_v4_0_3.c  | 10 ++--------
> drivers/gpu/drm/amd/amdgpu/vcn_v4_0_5.c  | 10 +---------
>  14 files changed, 17 insertions(+), 104 deletions(-)
>
> diff --git a/drivers/gpu/drm/amd/amdgpu/jpeg_v1_0.c
> b/drivers/gpu/drm/amd/amdgpu/jpeg_v1_0.c
> index 77595e9622da..71f43a5c7f72 100644
> --- a/drivers/gpu/drm/amd/amdgpu/jpeg_v1_0.c
> +++ b/drivers/gpu/drm/amd/amdgpu/jpeg_v1_0.c
> @@ -581,7 +581,6 @@ static const struct amdgpu_ring_funcs
> jpeg_v1_0_decode_ring_vm_funcs = {  static void
> jpeg_v1_0_set_dec_ring_funcs(struct amdgpu_device *adev)  {
>       adev->jpeg.inst->ring_dec->funcs =
> &jpeg_v1_0_decode_ring_vm_funcs;
> -     DRM_INFO("JPEG decode is enabled in VM mode\n");
>  }
>
>  static const struct amdgpu_irq_src_funcs jpeg_v1_0_irq_funcs = { diff --git
> a/drivers/gpu/drm/amd/amdgpu/jpeg_v2_0.c
> b/drivers/gpu/drm/amd/amdgpu/jpeg_v2_0.c
> index ef3e42f6b841..99adf3625657 100644
> --- a/drivers/gpu/drm/amd/amdgpu/jpeg_v2_0.c
> +++ b/drivers/gpu/drm/amd/amdgpu/jpeg_v2_0.c
> @@ -131,16 +131,11 @@ static int jpeg_v2_0_hw_init(void *handle)  {
>       struct amdgpu_device *adev = (struct amdgpu_device *)handle;
>       struct amdgpu_ring *ring = adev->jpeg.inst->ring_dec;
> -     int r;
>
>       adev->nbio.funcs->vcn_doorbell_range(adev, ring->use_doorbell,
>               (adev->doorbell_index.vcn.vcn_ring0_1 << 1), 0);
>
> -     r = amdgpu_ring_test_helper(ring);
> -     if (!r)
> -             DRM_INFO("JPEG decode initialized successfully.\n");
> -
> -     return r;
> +     return amdgpu_ring_test_helper(ring);
>  }
>
>  /**
> @@ -795,7 +790,6 @@ static const struct amdgpu_ring_funcs
> jpeg_v2_0_dec_ring_vm_funcs = {  static void
> jpeg_v2_0_set_dec_ring_funcs(struct amdgpu_device *adev)  {
>       adev->jpeg.inst->ring_dec->funcs = &jpeg_v2_0_dec_ring_vm_funcs;
> -     DRM_INFO("JPEG decode is enabled in VM mode\n");
>  }
>
>  static const struct amdgpu_irq_src_funcs jpeg_v2_0_irq_funcs = { diff --git
> a/drivers/gpu/drm/amd/amdgpu/jpeg_v2_5.c
> b/drivers/gpu/drm/amd/amdgpu/jpeg_v2_5.c
> index afeaf3c64e27..d8ef95c847c2 100644
> --- a/drivers/gpu/drm/amd/amdgpu/jpeg_v2_5.c
> +++ b/drivers/gpu/drm/amd/amdgpu/jpeg_v2_5.c
> @@ -196,8 +196,6 @@ static int jpeg_v2_5_hw_init(void *handle)
>                       return r;
>       }
>
> -     DRM_INFO("JPEG decode initialized successfully.\n");
> -
>       return 0;
>  }
>
> @@ -728,7 +726,6 @@ static void jpeg_v2_5_set_dec_ring_funcs(struct
> amdgpu_device *adev)
>               else  /* CHIP_ALDEBARAN */
>                       adev->jpeg.inst[i].ring_dec->funcs =
> &jpeg_v2_6_dec_ring_vm_funcs;
>               adev->jpeg.inst[i].ring_dec->me = i;
> -             DRM_INFO("JPEG(%d) JPEG decode is enabled in VM mode\n",
> i);
>       }
>  }
>
> diff --git a/drivers/gpu/drm/amd/amdgpu/jpeg_v3_0.c
> b/drivers/gpu/drm/amd/amdgpu/jpeg_v3_0.c
> index 1c7cf4800bf7..31cfa3ce6528 100644
> --- a/drivers/gpu/drm/amd/amdgpu/jpeg_v3_0.c
> +++ b/drivers/gpu/drm/amd/amdgpu/jpeg_v3_0.c
> @@ -146,18 +146,11 @@ static int jpeg_v3_0_hw_init(void *handle)  {
>       struct amdgpu_device *adev = (struct amdgpu_device *)handle;
>       struct amdgpu_ring *ring = adev->jpeg.inst->ring_dec;
> -     int r;
>
>       adev->nbio.funcs->vcn_doorbell_range(adev, ring->use_doorbell,
>               (adev->doorbell_index.vcn.vcn_ring0_1 << 1), 0);
>
> -     r = amdgpu_ring_test_helper(ring);
> -     if (r)
> -             return r;
> -
> -     DRM_INFO("JPEG decode initialized successfully.\n");
> -
> -     return 0;
> +     return amdgpu_ring_test_helper(ring);
>  }
>
>  /**
> @@ -593,7 +586,6 @@ static const struct amdgpu_ring_funcs
> jpeg_v3_0_dec_ring_vm_funcs = {  static void
> jpeg_v3_0_set_dec_ring_funcs(struct amdgpu_device *adev)  {
>       adev->jpeg.inst->ring_dec->funcs = &jpeg_v3_0_dec_ring_vm_funcs;
> -     DRM_INFO("JPEG decode is enabled in VM mode\n");
>  }
>
>  static const struct amdgpu_irq_src_funcs jpeg_v3_0_irq_funcs = { diff --git
> a/drivers/gpu/drm/amd/amdgpu/jpeg_v4_0.c
> b/drivers/gpu/drm/amd/amdgpu/jpeg_v4_0.c
> index 237fe5df5a8f..3dac8f259d7f 100644
> --- a/drivers/gpu/drm/amd/amdgpu/jpeg_v4_0.c
> +++ b/drivers/gpu/drm/amd/amdgpu/jpeg_v4_0.c
> @@ -181,8 +181,6 @@ static int jpeg_v4_0_hw_init(void *handle)
>                       return r;
>       }
>
> -     DRM_DEV_INFO(adev->dev, "JPEG decode initialized successfully.\n");
> -
>       return 0;
>  }
>
> @@ -755,7 +753,6 @@ static const struct amdgpu_ring_funcs
> jpeg_v4_0_dec_ring_vm_funcs = {  static void
> jpeg_v4_0_set_dec_ring_funcs(struct amdgpu_device *adev)  {
>       adev->jpeg.inst->ring_dec->funcs = &jpeg_v4_0_dec_ring_vm_funcs;
> -     DRM_DEV_INFO(adev->dev, "JPEG decode is enabled in VM mode\n");
>  }
>
>  static const struct amdgpu_irq_src_funcs jpeg_v4_0_irq_funcs = { diff --git
> a/drivers/gpu/drm/amd/amdgpu/jpeg_v4_0_3.c
> b/drivers/gpu/drm/amd/amdgpu/jpeg_v4_0_3.c
> index d66af11aa66c..04d8966423de 100644
> --- a/drivers/gpu/drm/amd/amdgpu/jpeg_v4_0_3.c
> +++ b/drivers/gpu/drm/amd/amdgpu/jpeg_v4_0_3.c
> @@ -341,7 +341,6 @@ static int jpeg_v4_0_3_hw_init(void *handle)
>                       }
>               }
>       }
> -     DRM_DEV_INFO(adev->dev, "JPEG decode initialized successfully.\n");
>
>       return 0;
>  }
> @@ -1100,7 +1099,6 @@ static void jpeg_v4_0_3_set_dec_ring_funcs(struct
> amdgpu_device *adev)
>               adev->jpeg.inst[i].aid_id =
>                       jpeg_inst / adev->jpeg.num_inst_per_aid;
>       }
> -     DRM_DEV_INFO(adev->dev, "JPEG decode is enabled in VM mode\n");
>  }
>
>  static const struct amdgpu_irq_src_funcs jpeg_v4_0_3_irq_funcs = { diff --git
> a/drivers/gpu/drm/amd/amdgpu/jpeg_v4_0_5.c
> b/drivers/gpu/drm/amd/amdgpu/jpeg_v4_0_5.c
> index 4c8f9772437b..f96ac6bce526 100644
> --- a/drivers/gpu/drm/amd/amdgpu/jpeg_v4_0_5.c
> +++ b/drivers/gpu/drm/amd/amdgpu/jpeg_v4_0_5.c
> @@ -191,7 +191,6 @@ static int jpeg_v4_0_5_hw_init(void *handle)
>
>       // TODO: Enable ring test with DPG support
>       if (adev->pg_flags & AMD_PG_SUPPORT_JPEG_DPG) {
> -             DRM_DEV_INFO(adev->dev, "JPEG decode initialized
> successfully under DPG Mode");
>               return 0;
>       }
>
> @@ -205,9 +204,6 @@ static int jpeg_v4_0_5_hw_init(void *handle)
>                       return r;
>       }
>
> -     if (!r)
> -             DRM_INFO("JPEG decode initialized successfully under SPG
> Mode\n");
> -
>       return 0;
>  }
>
> @@ -805,7 +801,6 @@ static void jpeg_v4_0_5_set_dec_ring_funcs(struct
> amdgpu_device *adev)
>
>               adev->jpeg.inst[i].ring_dec->funcs =
> &jpeg_v4_0_5_dec_ring_vm_funcs;
>               adev->jpeg.inst[i].ring_dec->me = i;
> -             DRM_DEV_INFO(adev->dev, "JPEG%d decode is enabled in VM
> mode\n", i);
>       }
>  }
>
> diff --git a/drivers/gpu/drm/amd/amdgpu/vcn_v1_0.c
> b/drivers/gpu/drm/amd/amdgpu/vcn_v1_0.c
> index cb253bd3a2a2..a280b9fecb77 100644
> --- a/drivers/gpu/drm/amd/amdgpu/vcn_v1_0.c
> +++ b/drivers/gpu/drm/amd/amdgpu/vcn_v1_0.c
> @@ -202,24 +202,17 @@ static int vcn_v1_0_hw_init(void *handle)
>
>       r = amdgpu_ring_test_helper(ring);
>       if (r)
> -             goto done;
> +             return r;
>
>       for (i = 0; i < adev->vcn.num_enc_rings; ++i) {
>               ring = &adev->vcn.inst->ring_enc[i];
>               r = amdgpu_ring_test_helper(ring);
>               if (r)
> -                     goto done;
> +                     return r;
>       }
>
>       ring = adev->jpeg.inst->ring_dec;
>       r = amdgpu_ring_test_helper(ring);
> -     if (r)
> -             goto done;
> -
> -done:
> -     if (!r)
> -             DRM_INFO("VCN decode and encode initialized
> successfully(under %s).\n",
> -                     (adev->pg_flags &
> AMD_PG_SUPPORT_VCN_DPG)?"DPG Mode":"SPG Mode");
>
>       return r;
>  }
> @@ -2043,7 +2036,6 @@ static const struct amdgpu_ring_funcs
> vcn_v1_0_enc_ring_vm_funcs = {  static void
> vcn_v1_0_set_dec_ring_funcs(struct amdgpu_device *adev)  {
>       adev->vcn.inst->ring_dec.funcs = &vcn_v1_0_dec_ring_vm_funcs;
> -     DRM_INFO("VCN decode is enabled in VM mode\n");
>  }
>
>  static void vcn_v1_0_set_enc_ring_funcs(struct amdgpu_device *adev) @@ -
> 2052,8 +2044,6 @@ static void vcn_v1_0_set_enc_ring_funcs(struct
> amdgpu_device *adev)
>
>       for (i = 0; i < adev->vcn.num_enc_rings; ++i)
>               adev->vcn.inst->ring_enc[i].funcs =
> &vcn_v1_0_enc_ring_vm_funcs;
> -
> -     DRM_INFO("VCN encode is enabled in VM mode\n");
>  }
>
>  static const struct amdgpu_irq_src_funcs vcn_v1_0_irq_funcs = { diff --git
> a/drivers/gpu/drm/amd/amdgpu/vcn_v2_0.c
> b/drivers/gpu/drm/amd/amdgpu/vcn_v2_0.c
> index f18fd61c435e..d3d096909a7f 100644
> --- a/drivers/gpu/drm/amd/amdgpu/vcn_v2_0.c
> +++ b/drivers/gpu/drm/amd/amdgpu/vcn_v2_0.c
> @@ -237,7 +237,7 @@ static int vcn_v2_0_hw_init(void *handle)
>
>       r = amdgpu_ring_test_helper(ring);
>       if (r)
> -             goto done;
> +             return r;
>
>       //Disable vcn decode for sriov
>       if (amdgpu_sriov_vf(adev))
> @@ -247,15 +247,10 @@ static int vcn_v2_0_hw_init(void *handle)
>               ring = &adev->vcn.inst->ring_enc[i];
>               r = amdgpu_ring_test_helper(ring);
>               if (r)
> -                     goto done;
> +                     return r;
>       }
>
> -done:
> -     if (!r)
> -             DRM_INFO("VCN decode and encode initialized
> successfully(under %s).\n",
> -                     (adev->pg_flags &
> AMD_PG_SUPPORT_VCN_DPG)?"DPG Mode":"SPG Mode");
> -
> -     return r;
> +     return 0;
>  }
>
>  /**
> @@ -2074,7 +2069,6 @@ static const struct amdgpu_ring_funcs
> vcn_v2_0_enc_ring_vm_funcs = {  static void
> vcn_v2_0_set_dec_ring_funcs(struct amdgpu_device *adev)  {
>       adev->vcn.inst->ring_dec.funcs = &vcn_v2_0_dec_ring_vm_funcs;
> -     DRM_INFO("VCN decode is enabled in VM mode\n");
>  }
>
>  static void vcn_v2_0_set_enc_ring_funcs(struct amdgpu_device *adev) @@ -
> 2083,8 +2077,6 @@ static void vcn_v2_0_set_enc_ring_funcs(struct
> amdgpu_device *adev)
>
>       for (i = 0; i < adev->vcn.num_enc_rings; ++i)
>               adev->vcn.inst->ring_enc[i].funcs =
> &vcn_v2_0_enc_ring_vm_funcs;
> -
> -     DRM_INFO("VCN encode is enabled in VM mode\n");
>  }
>
>  static const struct amdgpu_irq_src_funcs vcn_v2_0_irq_funcs = { diff --git
> a/drivers/gpu/drm/amd/amdgpu/vcn_v2_5.c
> b/drivers/gpu/drm/amd/amdgpu/vcn_v2_5.c
> index baec14bde2a2..96f60c303161 100644
> --- a/drivers/gpu/drm/amd/amdgpu/vcn_v2_5.c
> +++ b/drivers/gpu/drm/amd/amdgpu/vcn_v2_5.c
> @@ -314,22 +314,17 @@ static int vcn_v2_5_hw_init(void *handle)
>
>                       r = amdgpu_ring_test_helper(ring);
>                       if (r)
> -                             goto done;
> +                             return r;
>
>                       for (i = 0; i < adev->vcn.num_enc_rings; ++i) {
>                               ring = &adev->vcn.inst[j].ring_enc[i];
>                               r = amdgpu_ring_test_helper(ring);
>                               if (r)
> -                                     goto done;
> +                                     return r;
>                       }
>               }
>       }
>
> -done:
> -     if (!r)
> -             DRM_INFO("VCN decode and encode initialized
> successfully(under %s).\n",
> -                     (adev->pg_flags &
> AMD_PG_SUPPORT_VCN_DPG)?"DPG Mode":"SPG Mode");
> -
>       return r;
>  }
>
> @@ -1710,7 +1705,6 @@ static void vcn_v2_5_set_dec_ring_funcs(struct
> amdgpu_device *adev)
>                       continue;
>               adev->vcn.inst[i].ring_dec.funcs =
> &vcn_v2_5_dec_ring_vm_funcs;
>               adev->vcn.inst[i].ring_dec.me = i;
> -             DRM_INFO("VCN(%d) decode is enabled in VM mode\n", i);
>       }
>  }
>
> @@ -1725,7 +1719,6 @@ static void vcn_v2_5_set_enc_ring_funcs(struct
> amdgpu_device *adev)
>                       adev->vcn.inst[j].ring_enc[i].funcs =
> &vcn_v2_5_enc_ring_vm_funcs;
>                       adev->vcn.inst[j].ring_enc[i].me = j;
>               }
> -             DRM_INFO("VCN(%d) encode is enabled in VM mode\n", j);
>       }
>  }
>
> diff --git a/drivers/gpu/drm/amd/amdgpu/vcn_v3_0.c
> b/drivers/gpu/drm/amd/amdgpu/vcn_v3_0.c
> index 6b31cf4b8aac..24f947751c46 100644
> --- a/drivers/gpu/drm/amd/amdgpu/vcn_v3_0.c
> +++ b/drivers/gpu/drm/amd/amdgpu/vcn_v3_0.c
> @@ -303,7 +303,7 @@ static int vcn_v3_0_hw_init(void *handle)
>       if (amdgpu_sriov_vf(adev)) {
>               r = vcn_v3_0_start_sriov(adev);
>               if (r)
> -                     goto done;
> +                     return r;
>
>               /* initialize VCN dec and enc ring buffers */
>               for (i = 0; i < adev->vcn.num_vcn_inst; ++i) { @@ -348,24
> +348,18 @@ static int vcn_v3_0_hw_init(void *handle)
>
>                       r = amdgpu_ring_test_helper(ring);
>                       if (r)
> -                             goto done;
> +                             return r;
>
>                       for (j = 0; j < adev->vcn.num_enc_rings; ++j) {
>                               ring = &adev->vcn.inst[i].ring_enc[j];
>                               r = amdgpu_ring_test_helper(ring);
>                               if (r)
> -                                     goto done;
> +                                     return r;
>                       }
>               }
>       }
>
>       return 0;
> -done:
> -     if (!r)
> -             DRM_INFO("VCN decode and encode initialized
> successfully(under %s).\n",
> -                     (adev->pg_flags &
> AMD_PG_SUPPORT_VCN_DPG)?"DPG Mode":"SPG Mode");
> -
> -     return r;
>  }
>
>  /**
> @@ -2041,8 +2035,6 @@ static void vcn_v3_0_set_dec_ring_funcs(struct
> amdgpu_device *adev)
>               else
>                       adev->vcn.inst[i].ring_dec.funcs =
> &vcn_v3_0_dec_sw_ring_vm_funcs;
>               adev->vcn.inst[i].ring_dec.me = i;
> -             DRM_INFO("VCN(%d) decode%s is enabled in VM mode\n", i,
> -                       DEC_SW_RING_ENABLED?"(Software Ring)":"");
>       }
>  }
>
> @@ -2058,8 +2050,6 @@ static void vcn_v3_0_set_enc_ring_funcs(struct
> amdgpu_device *adev)
>                       adev->vcn.inst[i].ring_enc[j].funcs =
> &vcn_v3_0_enc_ring_vm_funcs;
>                       adev->vcn.inst[i].ring_enc[j].me = i;
>               }
> -             if (adev->vcn.num_enc_rings > 0)
> -                     DRM_INFO("VCN(%d) encode is enabled in VM
> mode\n", i);
>       }
>  }
>
> diff --git a/drivers/gpu/drm/amd/amdgpu/vcn_v4_0.c
> b/drivers/gpu/drm/amd/amdgpu/vcn_v4_0.c
> index ac1b8ead03b3..f6d96a44d75f 100644
> --- a/drivers/gpu/drm/amd/amdgpu/vcn_v4_0.c
> +++ b/drivers/gpu/drm/amd/amdgpu/vcn_v4_0.c
> @@ -258,7 +258,7 @@ static int vcn_v4_0_hw_init(void *handle)
>       if (amdgpu_sriov_vf(adev)) {
>               r = vcn_v4_0_start_sriov(adev);
>               if (r)
> -                     goto done;
> +                     return r;
>
>               for (i = 0; i < adev->vcn.num_vcn_inst; ++i) {
>                       if (adev->vcn.harvest_config & (1 << i)) @@ -269,7
> +269,6 @@ static int vcn_v4_0_hw_init(void *handle)
>                       ring->wptr_old = 0;
>                       vcn_v4_0_unified_ring_set_wptr(ring);
>                       ring->sched.ready = true;
> -
>               }
>       } else {
>               for (i = 0; i < adev->vcn.num_vcn_inst; ++i) { @@ -283,18
> +282,11 @@ static int vcn_v4_0_hw_init(void *handle)
>
>                       r = amdgpu_ring_test_helper(ring);
>                       if (r)
> -                             goto done;
> -
> +                             return r;
>               }
>       }
>
>       return 0;
> -done:
> -     if (!r)
> -             DRM_INFO("VCN decode and encode initialized
> successfully(under %s).\n",
> -                     (adev->pg_flags &
> AMD_PG_SUPPORT_VCN_DPG)?"DPG Mode":"SPG Mode");
> -
> -     return r;
>  }
>
>  /**
> @@ -1900,8 +1892,6 @@ static void vcn_v4_0_set_unified_ring_funcs(struct
> amdgpu_device *adev)
>               adev->vcn.inst[i].ring_enc[0].funcs =
>                      (const struct amdgpu_ring_funcs
> *)&vcn_v4_0_unified_ring_vm_funcs;
>               adev->vcn.inst[i].ring_enc[0].me = i;
> -
> -             DRM_INFO("VCN(%d) encode/decode are enabled in VM
> mode\n", i);
>       }
>  }
>
> diff --git a/drivers/gpu/drm/amd/amdgpu/vcn_v4_0_3.c
> b/drivers/gpu/drm/amd/amdgpu/vcn_v4_0_3.c
> index 2279d8fce03d..f53054e39ebb 100644
> --- a/drivers/gpu/drm/amd/amdgpu/vcn_v4_0_3.c
> +++ b/drivers/gpu/drm/amd/amdgpu/vcn_v4_0_3.c
> @@ -210,7 +210,7 @@ static int vcn_v4_0_3_hw_init(void *handle)
>       if (amdgpu_sriov_vf(adev)) {
>               r = vcn_v4_0_3_start_sriov(adev);
>               if (r)
> -                     goto done;
> +                     return r;
>
>               for (i = 0; i < adev->vcn.num_vcn_inst; ++i) {
>                       ring = &adev->vcn.inst[i].ring_enc[0]; @@ -246,15
> +246,10 @@ static int vcn_v4_0_3_hw_init(void *handle)
>
>                       r = amdgpu_ring_test_helper(ring);
>                       if (r)
> -                             goto done;
> +                             return r;
>               }
>       }
>
> -done:
> -     if (!r)
> -             DRM_DEV_INFO(adev->dev, "VCN decode initialized
> successfully(under %s).\n",
> -                     (adev->pg_flags &
> AMD_PG_SUPPORT_VCN_DPG)?"DPG Mode":"SPG Mode");
> -
>       return r;
>  }
>
> @@ -1450,7 +1445,6 @@ static void
> vcn_v4_0_3_set_unified_ring_funcs(struct amdgpu_device *adev)
>               adev->vcn.inst[i].aid_id =
>                       vcn_inst / adev->vcn.num_inst_per_aid;
>       }
> -     DRM_DEV_INFO(adev->dev, "VCN decode is enabled in VM mode\n");
>  }
>
>  /**
> diff --git a/drivers/gpu/drm/amd/amdgpu/vcn_v4_0_5.c
> b/drivers/gpu/drm/amd/amdgpu/vcn_v4_0_5.c
> index 81fb99729f37..f45495de6875 100644
> --- a/drivers/gpu/drm/amd/amdgpu/vcn_v4_0_5.c
> +++ b/drivers/gpu/drm/amd/amdgpu/vcn_v4_0_5.c
> @@ -234,16 +234,10 @@ static int vcn_v4_0_5_hw_init(void *handle)
>
>               r = amdgpu_ring_test_helper(ring);
>               if (r)
> -                     goto done;
> +                     return r;
>       }
>
>       return 0;
> -done:
> -     if (!r)
> -             DRM_INFO("VCN decode and encode initialized
> successfully(under %s).\n",
> -                     (adev->pg_flags &
> AMD_PG_SUPPORT_VCN_DPG)?"DPG Mode":"SPG Mode");
> -
> -     return r;
>  }
>
>  /**
> @@ -1558,8 +1552,6 @@ static void
> vcn_v4_0_5_set_unified_ring_funcs(struct amdgpu_device *adev)
>
>               adev->vcn.inst[i].ring_enc[0].funcs =
> &vcn_v4_0_5_unified_ring_vm_funcs;
>               adev->vcn.inst[i].ring_enc[0].me = i;
> -
> -             DRM_INFO("VCN(%d) encode/decode are enabled in VM
> mode\n", i);
>       }
>  }
>
> --
> 2.34.1





[Index of Archives]     [Linux USB Devel]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]

  Powered by Linux