On Wed, 2014-03-05 at 15:24 +0300, Dan Carpenter wrote: > On Tue, Mar 04, 2014 at 02:27:49AM +0300, Dan Carpenter wrote: > > On Mon, Mar 03, 2014 at 06:10:38PM +0100, Johannes Berg wrote: > > > Hi Dan, > > > > > > I keep getting this warning > > > > > > net/wireless/nl80211.c:2771 nl80211_get_key() warn: can 'mac_addr' even > > > be NULL? > > > > > > in some way or another all the time with smatch, and I'm wondering why > > > it pops up here? > > > > > > The variable in question ("mac_addr") starts out as being NULL, and the > > > bool variable "pairwise" in the if that smatch looks at is set to !! > > > mac_addr, but there's another code path that can set pairwise to true > > > even when mac_addr remains NULL, so I don't really understand the > > > warning. > > > > > > Am I missing something, or is that some sort of limitation in the smatch > > > logic? > > > > It should be fixed now: > http://repo.or.cz/w/smatch.git/commitdiff/9d6962bad2b6f2a142edf03690bd31d3caf01f25 > > It's a pretty central bug. Thanks for reporting. Yeah, it's gone, very nice. Thanks! FWIW, with the update, I'm seeing a lot more memory consumption (and time spent processing as well) so the default parameters seem to be no longer sufficient and I get things like net/wireless/nl80211.c:2223 nl80211_set_wiphy() Function too hairy. Giving up. Increasing allowed memory consumption ten-fold seems to help ;-) I also see a lot of "ignoring unreachable code", e.g. for every BUG_ON() and through a lot of inlines, but I guess that's just some new detection code. johannes -- To unsubscribe from this list: send the line "unsubscribe smatch" in the body of a message to majordomo@xxxxxxxxxxxxxxx More majordomo info at http://vger.kernel.org/majordomo-info.html