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