linux-kernel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH] drm/amdgpu: fix repeated words in comments
@ 2022-09-07 11:34 Jilin Yuan
  2022-09-07 14:54 ` Robin Murphy
  0 siblings, 1 reply; 5+ messages in thread
From: Jilin Yuan @ 2022-09-07 11:34 UTC (permalink / raw)
  To: airlied, daniel, shaoyun.liu; +Cc: amd-gfx, dri-devel, linux-kernel, Jilin Yuan

Delete the redundant word 'and'.
Delete the redundant word 'in'.
Delete the redundant word 'the'.
Delete the redundant word 'are'.

Signed-off-by: Jilin Yuan <yuanjilin@cdjrlc.com>
---
 drivers/gpu/drm/amd/amdgpu/amdgpu_device.c | 6 +++---
 1 file changed, 3 insertions(+), 3 deletions(-)

diff --git a/drivers/gpu/drm/amd/amdgpu/amdgpu_device.c b/drivers/gpu/drm/amd/amdgpu/amdgpu_device.c
index afaa1056e039..71367b9dd590 100644
--- a/drivers/gpu/drm/amd/amdgpu/amdgpu_device.c
+++ b/drivers/gpu/drm/amd/amdgpu/amdgpu_device.c
@@ -958,7 +958,7 @@ static void amdgpu_device_vram_scratch_fini(struct amdgpu_device *adev)
  * @registers: pointer to the register array
  * @array_size: size of the register array
  *
- * Programs an array or registers with and and or masks.
+ * Programs an array or registers with and or masks.
  * This is a helper for setting golden registers.
  */
 void amdgpu_device_program_register_sequence(struct amdgpu_device *adev,
@@ -1569,7 +1569,7 @@ static int amdgpu_device_check_arguments(struct amdgpu_device *adev)
  * @state: vga_switcheroo state
  *
  * Callback for the switcheroo driver.  Suspends or resumes the
- * the asics before or after it is powered up using ACPI methods.
+ * asics before or after it is powered up using ACPI methods.
  */
 static void amdgpu_switcheroo_set_state(struct pci_dev *pdev,
 					enum vga_switcheroo_state state)
@@ -3203,7 +3203,7 @@ static int amdgpu_device_ip_resume_phase2(struct amdgpu_device *adev)
  *
  * Main resume function for hardware IPs.  The hardware IPs
  * are split into two resume functions because they are
- * are also used in in recovering from a GPU reset and some additional
+ * also used in recovering from a GPU reset and some additional
  * steps need to be take between them.  In this case (S3/S4) they are
  * run sequentially.
  * Returns 0 on success, negative error code on failure.
-- 
2.36.1


^ permalink raw reply related	[flat|nested] 5+ messages in thread

* Re: [PATCH] drm/amdgpu: fix repeated words in comments
  2022-09-07 11:34 [PATCH] drm/amdgpu: fix repeated words in comments Jilin Yuan
@ 2022-09-07 14:54 ` Robin Murphy
  0 siblings, 0 replies; 5+ messages in thread
From: Robin Murphy @ 2022-09-07 14:54 UTC (permalink / raw)
  To: Jilin Yuan, airlied, daniel, shaoyun.liu; +Cc: dri-devel, amd-gfx, linux-kernel

On 2022-09-07 12:34, Jilin Yuan wrote:
> Delete the redundant word 'and'.
> Delete the redundant word 'in'.
> Delete the redundant word 'the'.
> Delete the redundant word 'are'.
> 
> Signed-off-by: Jilin Yuan <yuanjilin@cdjrlc.com>
> ---
>   drivers/gpu/drm/amd/amdgpu/amdgpu_device.c | 6 +++---
>   1 file changed, 3 insertions(+), 3 deletions(-)
> 
> diff --git a/drivers/gpu/drm/amd/amdgpu/amdgpu_device.c b/drivers/gpu/drm/amd/amdgpu/amdgpu_device.c
> index afaa1056e039..71367b9dd590 100644
> --- a/drivers/gpu/drm/amd/amdgpu/amdgpu_device.c
> +++ b/drivers/gpu/drm/amd/amdgpu/amdgpu_device.c
> @@ -958,7 +958,7 @@ static void amdgpu_device_vram_scratch_fini(struct amdgpu_device *adev)
>    * @registers: pointer to the register array
>    * @array_size: size of the register array
>    *
> - * Programs an array or registers with and and or masks.

Not redundant - the first "and" refers to the boolean operation, the 
second is a conjunction. This is clear from the code if you look at it. 
You could perhaps restyle the comment as "with AND and OR masks" to make 
that stand out a bit better, but either way, please try to actually 
understand the changes you're proposing.

Robin.

> + * Programs an array or registers with and or masks.
>    * This is a helper for setting golden registers.
>    */
>   void amdgpu_device_program_register_sequence(struct amdgpu_device *adev,
> @@ -1569,7 +1569,7 @@ static int amdgpu_device_check_arguments(struct amdgpu_device *adev)
>    * @state: vga_switcheroo state
>    *
>    * Callback for the switcheroo driver.  Suspends or resumes the
> - * the asics before or after it is powered up using ACPI methods.
> + * asics before or after it is powered up using ACPI methods.
>    */
>   static void amdgpu_switcheroo_set_state(struct pci_dev *pdev,
>   					enum vga_switcheroo_state state)
> @@ -3203,7 +3203,7 @@ static int amdgpu_device_ip_resume_phase2(struct amdgpu_device *adev)
>    *
>    * Main resume function for hardware IPs.  The hardware IPs
>    * are split into two resume functions because they are
> - * are also used in in recovering from a GPU reset and some additional
> + * also used in recovering from a GPU reset and some additional
>    * steps need to be take between them.  In this case (S3/S4) they are
>    * run sequentially.
>    * Returns 0 on success, negative error code on failure.

^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: [PATCH] drm/amdgpu: fix repeated words in comments
  2022-09-07 14:50 ` Robin Murphy
@ 2022-09-07 14:56   ` Alex Deucher
  0 siblings, 0 replies; 5+ messages in thread
From: Alex Deucher @ 2022-09-07 14:56 UTC (permalink / raw)
  To: Robin Murphy
  Cc: Jilin Yuan, airlied, daniel, isabbasso, amd-gfx, dri-devel, linux-kernel

On Wed, Sep 7, 2022 at 10:50 AM Robin Murphy <robin.murphy@arm.com> wrote:
>
> On 2022-09-07 12:26, Jilin Yuan wrote:
> > Delete the redundant word 'we'.
>
> FWIW, to me it's not redundant because while indeed it is not correct,
> it looks exactly like the kind of typo I might make of "if we", and
> parsing it as *that* does make sense. The sentence you end up with here
> can hardly be considered an improvement since it is still ungrammatical
> nonsense.

Yes, I believe this was supposed to say "if we" rather than "we we".

Alex

>
> Robin.
>
> > Signed-off-by: Jilin Yuan <yuanjilin@cdjrlc.com>
> > ---
> >   drivers/gpu/drm/amd/amdgpu/amdgpu_vce.c | 2 +-
> >   1 file changed, 1 insertion(+), 1 deletion(-)
> >
> > diff --git a/drivers/gpu/drm/amd/amdgpu/amdgpu_vce.c b/drivers/gpu/drm/amd/amdgpu/amdgpu_vce.c
> > index 02cb3a12dd76..6d6cc4637d41 100644
> > --- a/drivers/gpu/drm/amd/amdgpu/amdgpu_vce.c
> > +++ b/drivers/gpu/drm/amd/amdgpu/amdgpu_vce.c
> > @@ -694,7 +694,7 @@ static int amdgpu_vce_cs_reloc(struct amdgpu_cs_parser *p, struct amdgpu_ib *ib,
> >    * @allocated: allocated a new handle?
> >    *
> >    * Validates the handle and return the found session index or -EINVAL
> > - * we we don't have another free session index.
> > + * we don't have another free session index.
> >    */
> >   static int amdgpu_vce_validate_handle(struct amdgpu_cs_parser *p,
> >                                     uint32_t handle, uint32_t *allocated)

^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: [PATCH] drm/amdgpu: fix repeated words in comments
  2022-09-07 11:26 Jilin Yuan
@ 2022-09-07 14:50 ` Robin Murphy
  2022-09-07 14:56   ` Alex Deucher
  0 siblings, 1 reply; 5+ messages in thread
From: Robin Murphy @ 2022-09-07 14:50 UTC (permalink / raw)
  To: Jilin Yuan, airlied, daniel, isabbasso; +Cc: dri-devel, amd-gfx, linux-kernel

On 2022-09-07 12:26, Jilin Yuan wrote:
> Delete the redundant word 'we'.

FWIW, to me it's not redundant because while indeed it is not correct, 
it looks exactly like the kind of typo I might make of "if we", and 
parsing it as *that* does make sense. The sentence you end up with here 
can hardly be considered an improvement since it is still ungrammatical 
nonsense.

Robin.

> Signed-off-by: Jilin Yuan <yuanjilin@cdjrlc.com>
> ---
>   drivers/gpu/drm/amd/amdgpu/amdgpu_vce.c | 2 +-
>   1 file changed, 1 insertion(+), 1 deletion(-)
> 
> diff --git a/drivers/gpu/drm/amd/amdgpu/amdgpu_vce.c b/drivers/gpu/drm/amd/amdgpu/amdgpu_vce.c
> index 02cb3a12dd76..6d6cc4637d41 100644
> --- a/drivers/gpu/drm/amd/amdgpu/amdgpu_vce.c
> +++ b/drivers/gpu/drm/amd/amdgpu/amdgpu_vce.c
> @@ -694,7 +694,7 @@ static int amdgpu_vce_cs_reloc(struct amdgpu_cs_parser *p, struct amdgpu_ib *ib,
>    * @allocated: allocated a new handle?
>    *
>    * Validates the handle and return the found session index or -EINVAL
> - * we we don't have another free session index.
> + * we don't have another free session index.
>    */
>   static int amdgpu_vce_validate_handle(struct amdgpu_cs_parser *p,
>   				      uint32_t handle, uint32_t *allocated)

^ permalink raw reply	[flat|nested] 5+ messages in thread

* [PATCH] drm/amdgpu: fix repeated words in comments
@ 2022-09-07 11:26 Jilin Yuan
  2022-09-07 14:50 ` Robin Murphy
  0 siblings, 1 reply; 5+ messages in thread
From: Jilin Yuan @ 2022-09-07 11:26 UTC (permalink / raw)
  To: airlied, daniel, isabbasso; +Cc: amd-gfx, dri-devel, linux-kernel, Jilin Yuan

Delete the redundant word 'we'.

Signed-off-by: Jilin Yuan <yuanjilin@cdjrlc.com>
---
 drivers/gpu/drm/amd/amdgpu/amdgpu_vce.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/drivers/gpu/drm/amd/amdgpu/amdgpu_vce.c b/drivers/gpu/drm/amd/amdgpu/amdgpu_vce.c
index 02cb3a12dd76..6d6cc4637d41 100644
--- a/drivers/gpu/drm/amd/amdgpu/amdgpu_vce.c
+++ b/drivers/gpu/drm/amd/amdgpu/amdgpu_vce.c
@@ -694,7 +694,7 @@ static int amdgpu_vce_cs_reloc(struct amdgpu_cs_parser *p, struct amdgpu_ib *ib,
  * @allocated: allocated a new handle?
  *
  * Validates the handle and return the found session index or -EINVAL
- * we we don't have another free session index.
+ * we don't have another free session index.
  */
 static int amdgpu_vce_validate_handle(struct amdgpu_cs_parser *p,
 				      uint32_t handle, uint32_t *allocated)
-- 
2.36.1


^ permalink raw reply related	[flat|nested] 5+ messages in thread

end of thread, other threads:[~2022-09-07 14:57 UTC | newest]

Thread overview: 5+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2022-09-07 11:34 [PATCH] drm/amdgpu: fix repeated words in comments Jilin Yuan
2022-09-07 14:54 ` Robin Murphy
  -- strict thread matches above, loose matches on Subject: below --
2022-09-07 11:26 Jilin Yuan
2022-09-07 14:50 ` Robin Murphy
2022-09-07 14:56   ` Alex Deucher

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).