Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > linux.kernel > #1320631 > unrolled thread

Re: [PATCH] gpu: drm: amd: amdkfd: Remove unnecessary cast in kfree

Started byOded Gabbay <oded.gabbay@gmail.com>
First post2016-01-28 13:50 +0100
Last post2016-01-28 14:00 +0100
Articles 2 — 2 participants

Back to article view | Back to linux.kernel

This discussion starts older than the indexed window; earlier articles aren't shown. The article labeled Started by below is the oldest one visible, not the original post.


Contents

  Re: [PATCH] gpu: drm: amd: amdkfd: Remove unnecessary cast in kfree Oded Gabbay <oded.gabbay@gmail.com> - 2016-01-28 13:50 +0100
    Re: [PATCH] gpu: drm: amd: amdkfd: Remove unnecessary cast in kfree Amitoj Kaur Chawla <amitoj1606@gmail.com> - 2016-01-28 14:00 +0100

#1320631 — Re: [PATCH] gpu: drm: amd: amdkfd: Remove unnecessary cast in kfree

FromOded Gabbay <oded.gabbay@gmail.com>
Date2016-01-28 13:50 +0100
SubjectRe: [PATCH] gpu: drm: amd: amdkfd: Remove unnecessary cast in kfree
Message-ID<qVUbo-3sP-7@gated-at.bofh.it>
On Mon, Jan 25, 2016 at 7:33 PM, Amitoj Kaur Chawla
<amitoj1606@gmail.com> wrote:
> Remove an unnecassary cast in the argument to kfree.
>
> Found using Coccinelle. The semantic patch used to find this is as follows:
>
> //<smpl>
> @@
> type T;
> expression *f;
> @@
>
> - kfree((T *)(f));
> + kfree(f);
> //</smpl>
>
> Signed-off-by: Amitoj Kaur Chawla <amitoj1606@gmail.com>
> ---
>  drivers/gpu/drm/amd/amdkfd/kfd_process.c | 2 +-
>  1 file changed, 1 insertion(+), 1 deletion(-)
>
> diff --git a/drivers/gpu/drm/amd/amdkfd/kfd_process.c b/drivers/gpu/drm/amd/amdkfd/kfd_process.c
> index 9be0070..a902ae0 100644
> --- a/drivers/gpu/drm/amd/amdkfd/kfd_process.c
> +++ b/drivers/gpu/drm/amd/amdkfd/kfd_process.c
> @@ -194,7 +194,7 @@ static void kfd_process_wq_release(struct work_struct *work)
>
>         kfree(p);
>
> -       kfree((void *)work);
> +       kfree(work);
>  }
>
>  static void kfd_process_destroy_delayed(struct rcu_head *rcu)
> --
> 1.9.1
>

Thanks!
Applied to my -fixes tree.
For future reference, use "drm/amdkfd: ..." as the prefix of the
subject line. I fixed it for this patch.

       Oded

[toc] | [next] | [standalone]


#1320639

FromAmitoj Kaur Chawla <amitoj1606@gmail.com>
Date2016-01-28 14:00 +0100
Message-ID<qVUl3-3wq-5@gated-at.bofh.it>
In reply to#1320631
On Thu, Jan 28, 2016 at 6:11 PM, Oded Gabbay <oded.gabbay@gmail.com> wrote:
> Thanks!
> Applied to my -fixes tree.
> For future reference, use "drm/amdkfd: ..." as the prefix of the
> subject line. I fixed it for this patch.
>
>        Oded

Will do.

Thanks,
Amitoj

[toc] | [prev] | [standalone]


Back to top | Article view | linux.kernel


csiph-web