[ofa-general] [PATCH 2 of 2 for 2.6.28] mlx4: Add Raw Ethertype QP support

Roland Dreier rdreier at cisco.com
Fri Feb 6 14:05:44 PST 2009


 > -	    type != IB_QPT_SMI && type != IB_QPT_GSI)
 > +	    type != IB_QPT_SMI && type != IB_QPT_GSI && type != IB_QPT_RAW_ETY)

Seems we're at the point where mlx4 could use a "is_special_qpt()"
helper maybe?

 >  		err = create_qp_common(dev, pd, init_attr, udata,
 >  				       dev->dev->caps.sqp_start +
 > -				       (init_attr->qp_type == IB_QPT_SMI ? 0 : 2) +
 > +				       (init_attr->qp_type == IB_QPT_RAW_ETY ? 4 :
 > +				       (init_attr->qp_type == IB_QPT_SMI ? 0 : 2)) +
 >  				       init_attr->port_num - 1,

I think this is now way past the point where we should use a helper
function to compute this?

 > @@ -60,6 +60,7 @@ enum {
 >  	MLX4_DEV_CAP_FLAG_IPOIB_CSUM	= 1 <<  7,
 >  	MLX4_DEV_CAP_FLAG_BAD_PKEY_CNTR	= 1 <<  8,
 >  	MLX4_DEV_CAP_FLAG_BAD_QKEY_CNTR	= 1 <<  9,
 > +	MLX4_DEV_CAP_FLAG_RAW_ETY	= 1 << 13,
 >  	MLX4_DEV_CAP_FLAG_MEM_WINDOW	= 1 << 16,
 >  	MLX4_DEV_CAP_FLAG_APM		= 1 << 17,
 >  	MLX4_DEV_CAP_FLAG_ATOMIC	= 1 << 18,

probably nice to add this is dump_dev_cap_flags() so someone can check
dmesg output to see if raw ethertype is supported.

I don't see any changes to the poll cq side of things.  Is there
anything required to handle receiving raw ethertype datagrams?

 - R.



More information about the general mailing list