All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH] optee: Use bitmap_free() to free bitmap
@ 2021-12-26 14:32 Christophe JAILLET
  2021-12-27  5:36 ` Sumit Garg
  0 siblings, 1 reply; 3+ messages in thread
From: Christophe JAILLET @ 2021-12-26 14:32 UTC (permalink / raw)
  To: jens.wiklander, sumit.garg
  Cc: op-tee, linux-kernel, kernel-janitors, Christophe JAILLET

kfree() and bitmap_free() are the same. But using the latter is more
consistent when freeing memory allocated with bitmap_zalloc().

Signed-off-by: Christophe JAILLET <christophe.jaillet@wanadoo.fr>
---
 drivers/tee/optee/notif.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/drivers/tee/optee/notif.c b/drivers/tee/optee/notif.c
index a28fa03dcd0e..05212842b0a5 100644
--- a/drivers/tee/optee/notif.c
+++ b/drivers/tee/optee/notif.c
@@ -121,5 +121,5 @@ int optee_notif_init(struct optee *optee, u_int max_key)
 
 void optee_notif_uninit(struct optee *optee)
 {
-	kfree(optee->notif.bitmap);
+	bitmap_free(optee->notif.bitmap);
 }
-- 
2.32.0


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

* Re: [PATCH] optee: Use bitmap_free() to free bitmap
  2021-12-26 14:32 [PATCH] optee: Use bitmap_free() to free bitmap Christophe JAILLET
@ 2021-12-27  5:36 ` Sumit Garg
  2022-01-14 10:01   ` Jens Wiklander
  0 siblings, 1 reply; 3+ messages in thread
From: Sumit Garg @ 2021-12-27  5:36 UTC (permalink / raw)
  To: Christophe JAILLET; +Cc: jens.wiklander, op-tee, linux-kernel, kernel-janitors

On Sun, 26 Dec 2021 at 20:02, Christophe JAILLET
<christophe.jaillet@wanadoo.fr> wrote:
>
> kfree() and bitmap_free() are the same. But using the latter is more
> consistent when freeing memory allocated with bitmap_zalloc().
>
> Signed-off-by: Christophe JAILLET <christophe.jaillet@wanadoo.fr>
> ---
>  drivers/tee/optee/notif.c | 2 +-
>  1 file changed, 1 insertion(+), 1 deletion(-)
>

Looks reasonable to me.

Reviewed-by: Sumit Garg <sumit.garg@linaro.org>

-Sumit

> diff --git a/drivers/tee/optee/notif.c b/drivers/tee/optee/notif.c
> index a28fa03dcd0e..05212842b0a5 100644
> --- a/drivers/tee/optee/notif.c
> +++ b/drivers/tee/optee/notif.c
> @@ -121,5 +121,5 @@ int optee_notif_init(struct optee *optee, u_int max_key)
>
>  void optee_notif_uninit(struct optee *optee)
>  {
> -       kfree(optee->notif.bitmap);
> +       bitmap_free(optee->notif.bitmap);
>  }
> --
> 2.32.0
>

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

* Re: [PATCH] optee: Use bitmap_free() to free bitmap
  2021-12-27  5:36 ` Sumit Garg
@ 2022-01-14 10:01   ` Jens Wiklander
  0 siblings, 0 replies; 3+ messages in thread
From: Jens Wiklander @ 2022-01-14 10:01 UTC (permalink / raw)
  To: Sumit Garg; +Cc: Christophe JAILLET, op-tee, linux-kernel, kernel-janitors

On Mon, Dec 27, 2021 at 6:36 AM Sumit Garg <sumit.garg@linaro.org> wrote:
>
> On Sun, 26 Dec 2021 at 20:02, Christophe JAILLET
> <christophe.jaillet@wanadoo.fr> wrote:
> >
> > kfree() and bitmap_free() are the same. But using the latter is more
> > consistent when freeing memory allocated with bitmap_zalloc().
> >
> > Signed-off-by: Christophe JAILLET <christophe.jaillet@wanadoo.fr>
> > ---
> >  drivers/tee/optee/notif.c | 2 +-
> >  1 file changed, 1 insertion(+), 1 deletion(-)
> >
>
> Looks reasonable to me.
>
> Reviewed-by: Sumit Garg <sumit.garg@linaro.org>
>

Looks good, picking up this.

Thanks,
Jens

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

end of thread, other threads:[~2022-01-14 10:01 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2021-12-26 14:32 [PATCH] optee: Use bitmap_free() to free bitmap Christophe JAILLET
2021-12-27  5:36 ` Sumit Garg
2022-01-14 10:01   ` Jens Wiklander

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.