[openib-general] Re: [PATCH] extend ib_device node_type to include iWarp

Roland Dreier rdreier at cisco.com
Mon Jan 30 13:27:00 PST 2006


Seems OK.

The changes like this in ipoib, srp, sa_query, etc:

 > -	if (device->node_type == IB_NODE_SWITCH) {
 > +	if ((device->node_type & IB_NODE_SWITCH) == IB_NODE_SWITCH) {

seem rather silly.  We've already checked that the device is an IB
device, so the change is pure obfuscation.

Also, why do

 > -	enum ib_node_type dev_type;
 > +	u8 dev_type;

it seems better to leave the field as an enum for better
documentation.

 - R.



More information about the general mailing list