[PATCH 1/4] Modularize the handling of netdev address c/r

Dan Smith danms at us.ibm.com
Mon Apr 26 08:11:14 PDT 2010

OL> Does this test-and-set need locking ?

No, I was just planning on getting lucky each time.  Er, okay, yes :)

>> +	if (try_module_get(h->owner))
>> +		return h;
>> +	else
>> +		return ERR_PTR(-EBUSY);

OL> Maybe some ckpt_err() here ?  I can feel the frustration of trying
OL> to figure out where _this_ came from !

I'd prefer not to do that this deep.  I think the varying depth at
which we call ckpt_err() starts to get confusing.  Regardless, the
call of this function is checked and reported, which I think will make
tracking down an error result rather easy:

  h = get_addr_handler(i);
  if (!h)
  else if (IS_ERR(h)) {
  	addrs = PTR_ERR(h);
  	ckpt_err(ctx, addrs,
  		 "Unable to handle netdev addr type %s\n",


Dan Smith
IBM Linux Technology Center
email: danms at us.ibm.com

More information about the Containers mailing list