public inbox for kernel-janitors@vger.kernel.org
 help / color / mirror / Atom feed
* [bug report] rxrpc: Add some additional call tracing
@ 2016-10-12  6:10 Dan Carpenter
  2016-10-12  7:25 ` David Howells
                   ` (2 more replies)
  0 siblings, 3 replies; 4+ messages in thread
From: Dan Carpenter @ 2016-10-12  6:10 UTC (permalink / raw)
  To: kernel-janitors

Hello David Howells,

The patch a84a46d73050: "rxrpc: Add some additional call tracing"
from Sep 17, 2016, leads to the following static checker warning:

	net/rxrpc/call_object.c:279 rxrpc_new_client_call()
	warn: passing zero to 'ERR_PTR'

net/rxrpc/call_object.c
   270  
   271          /* Set up or get a connection record and set the protocol parameters,
   272           * including channel number and call ID.
   273           */
   274          ret = rxrpc_connect_call(call, cp, srx, gfp);
   275          if (ret < 0)
   276                  goto error;
   277  
   278          trace_rxrpc_call(call, rxrpc_call_connected, atomic_read(&call->usage),
   279                           here, ERR_PTR(ret));
                                       ^^^^^^^^^^^^
Pointless.

   280  

regards,
dan carpenter

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

* Re: [bug report] rxrpc: Add some additional call tracing
  2016-10-12  6:10 [bug report] rxrpc: Add some additional call tracing Dan Carpenter
@ 2016-10-12  7:25 ` David Howells
  2016-10-12  8:29 ` Dan Carpenter
  2016-10-12 14:59 ` David Howells
  2 siblings, 0 replies; 4+ messages in thread
From: David Howells @ 2016-10-12  7:25 UTC (permalink / raw)
  To: kernel-janitors

Dan Carpenter <dan.carpenter@oracle.com> wrote:

>    278          trace_rxrpc_call(call, rxrpc_call_connected, atomic_read(&call->usage),
>    279                           here, ERR_PTR(ret));
>                                        ^^^^^^^^^^^^
> Pointless.

I guess I should just cast it instead.

David

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

* Re: [bug report] rxrpc: Add some additional call tracing
  2016-10-12  6:10 [bug report] rxrpc: Add some additional call tracing Dan Carpenter
  2016-10-12  7:25 ` David Howells
@ 2016-10-12  8:29 ` Dan Carpenter
  2016-10-12 14:59 ` David Howells
  2 siblings, 0 replies; 4+ messages in thread
From: Dan Carpenter @ 2016-10-12  8:29 UTC (permalink / raw)
  To: kernel-janitors

On Wed, Oct 12, 2016 at 08:25:08AM +0100, David Howells wrote:
> Dan Carpenter <dan.carpenter@oracle.com> wrote:
> 
> >    278          trace_rxrpc_call(call, rxrpc_call_connected, atomic_read(&call->usage),
> >    279                           here, ERR_PTR(ret));
> >                                        ^^^^^^^^^^^^
> > Pointless.
> 
> I guess I should just cast it instead.

It's just zero or NULL always.  But if you want you can also ignore the
static checker warning since it's obviously harmless.

regards,
dan carpenter


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

* Re: [bug report] rxrpc: Add some additional call tracing
  2016-10-12  6:10 [bug report] rxrpc: Add some additional call tracing Dan Carpenter
  2016-10-12  7:25 ` David Howells
  2016-10-12  8:29 ` Dan Carpenter
@ 2016-10-12 14:59 ` David Howells
  2 siblings, 0 replies; 4+ messages in thread
From: David Howells @ 2016-10-12 14:59 UTC (permalink / raw)
  To: kernel-janitors

Dan Carpenter <dan.carpenter@oracle.com> wrote:

> It's just zero or NULL always.  But if you want you can also ignore the
> static checker warning since it's obviously harmless.

Ah, yes.  The trace line used to be before the error check, but now there's a
separate trace line for that.

David

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

end of thread, other threads:[~2016-10-12 14:59 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2016-10-12  6:10 [bug report] rxrpc: Add some additional call tracing Dan Carpenter
2016-10-12  7:25 ` David Howells
2016-10-12  8:29 ` Dan Carpenter
2016-10-12 14:59 ` David Howells

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox