All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH] iio: Be consistent with allocation result tests.
@ 2022-07-18  2:03 Joe Simmons-Talbott
  2022-07-18 16:44 ` Jonathan Cameron
  0 siblings, 1 reply; 3+ messages in thread
From: Joe Simmons-Talbott @ 2022-07-18  2:03 UTC (permalink / raw)
  To: Jonathan Cameron, Lars-Peter Clausen, linux-iio, linux-kernel
  Cc: Joe Simmons-Talbott

Make both allocation result tests use the same format

    if (!ptr)

Signed-off-by: Joe Simmons-Talbott <joetalbott@gmail.com>
---
 drivers/iio/industrialio-trigger.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/drivers/iio/industrialio-trigger.c b/drivers/iio/industrialio-trigger.c
index f504ed351b3e..e22c47f20b4d 100644
--- a/drivers/iio/industrialio-trigger.c
+++ b/drivers/iio/industrialio-trigger.c
@@ -369,7 +369,7 @@ struct iio_poll_func
 	struct iio_poll_func *pf;
 
 	pf = kmalloc(sizeof *pf, GFP_KERNEL);
-	if (pf == NULL)
+	if (!pf)
 		return NULL;
 	va_start(vargs, fmt);
 	pf->name = kvasprintf(GFP_KERNEL, fmt, vargs);
-- 
2.35.3


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

* Re: [PATCH] iio: Be consistent with allocation result tests.
  2022-07-18  2:03 [PATCH] iio: Be consistent with allocation result tests Joe Simmons-Talbott
@ 2022-07-18 16:44 ` Jonathan Cameron
  2022-07-31 14:19   ` Joe Simmons-Talbott
  0 siblings, 1 reply; 3+ messages in thread
From: Jonathan Cameron @ 2022-07-18 16:44 UTC (permalink / raw)
  To: Joe Simmons-Talbott; +Cc: Lars-Peter Clausen, linux-iio, linux-kernel

On Sun, 17 Jul 2022 22:03:48 -0400
Joe Simmons-Talbott <joetalbott@gmail.com> wrote:

> Make both allocation result tests use the same format
> 
>     if (!ptr)
> 
> Signed-off-by: Joe Simmons-Talbott <joetalbott@gmail.com>
If you post two patches to the list that will cause each other to not
apply, please base one on top of the other and say so in the
patch description.

Anyhow, fixed up and applied by hand.

Thanks,

Jonathan

> ---
>  drivers/iio/industrialio-trigger.c | 2 +-
>  1 file changed, 1 insertion(+), 1 deletion(-)
> 
> diff --git a/drivers/iio/industrialio-trigger.c b/drivers/iio/industrialio-trigger.c
> index f504ed351b3e..e22c47f20b4d 100644
> --- a/drivers/iio/industrialio-trigger.c
> +++ b/drivers/iio/industrialio-trigger.c
> @@ -369,7 +369,7 @@ struct iio_poll_func
>  	struct iio_poll_func *pf;
>  
>  	pf = kmalloc(sizeof *pf, GFP_KERNEL);
> -	if (pf == NULL)
> +	if (!pf)
>  		return NULL;
>  	va_start(vargs, fmt);
>  	pf->name = kvasprintf(GFP_KERNEL, fmt, vargs);


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

* Re: [PATCH] iio: Be consistent with allocation result tests.
  2022-07-18 16:44 ` Jonathan Cameron
@ 2022-07-31 14:19   ` Joe Simmons-Talbott
  0 siblings, 0 replies; 3+ messages in thread
From: Joe Simmons-Talbott @ 2022-07-31 14:19 UTC (permalink / raw)
  To: Jonathan Cameron; +Cc: Lars-Peter Clausen, linux-iio, linux-kernel

On Mon, Jul 18, 2022 at 05:44:41PM +0100, Jonathan Cameron wrote:
> On Sun, 17 Jul 2022 22:03:48 -0400
> Joe Simmons-Talbott <joetalbott@gmail.com> wrote:
> 
> > Make both allocation result tests use the same format
> > 
> >     if (!ptr)
> > 
> > Signed-off-by: Joe Simmons-Talbott <joetalbott@gmail.com>
> If you post two patches to the list that will cause each other to not
> apply, please base one on top of the other and say so in the
> patch description.
> 
> Anyhow, fixed up and applied by hand.

I'm sorry for neglecting that and for creating extra work.  Thank you
for fixing it.

Thanks,
Joe

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

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

Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2022-07-18  2:03 [PATCH] iio: Be consistent with allocation result tests Joe Simmons-Talbott
2022-07-18 16:44 ` Jonathan Cameron
2022-07-31 14:19   ` Joe Simmons-Talbott

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.