Re: [bug report] iw_cxgb4: dump detailed driver-specific QP information

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Tue, May 08, 2018 at 10:56:23AM -0500, Steve Wise wrote:
> >    228          if (fill_swsqes(msg, &wq.sq, first_sq_idx, fsp,
> last_sq_idx, lsp))
> >                                              ^^^^^^^^^^^^
> > On the one hand, it's not a bug to pass uninitialized data when "fsb" is
> > NULL...
> 
> Right.  If fsp and lsp are NULL then fill_swsqes() doesn't use the idx
> values.  So it is not a bug.  But it is an annoying warning.  Is it
> recommended I just initialize these even though they are not needed?
> 

I don't care too much because I've already marked these warnings as old
and moved on...

Normally, I don't advocate that people change the code for static
checker warnings, but I feel like it's the right thing to do here.
I've seen a few of these now where we pass unintialized data to
functions where it's not used.  And so far I've always thought it was
better to just initialize the pointers to NULL or whatever.

I don't have any plans to try fix this in Smatch...

regards,
dan carpenter

--
To unsubscribe from this list: send the line "unsubscribe linux-rdma" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html



[Index of Archives]     [Linux USB Devel]     [Video for Linux]     [Linux Audio Users]     [Photo]     [Yosemite News]     [Yosemite Photos]     [Linux Kernel]     [Linux SCSI]     [XFree86]

  Powered by Linux