diff options
author | Amir Vadai <amirv@mellanox.com> | 2012-04-04 21:33:30 (GMT) |
---|---|---|
committer | David S. Miller <davem@davemloft.net> | 2012-04-05 09:08:04 (GMT) |
commit | 08f10affe45051e18e0d8291c0a53aecef1b8a14 (patch) | |
tree | 0f18aa6f7d3885f695dfe5ad876363afe03ce6a6 /include/linux | |
parent | 366cddb4028858079a9a8145bd713c13a9edb3dc (diff) | |
download | linux-fsl-qoriq-08f10affe45051e18e0d8291c0a53aecef1b8a14.tar.xz |
net/dcb: Add an optional max rate attribute
Although not specified in 8021Qaz spec, it could be useful to enable drivers
whose HW supports setting a rate limit for an ETS TC. This patch adds this
optional attribute to DCB netlink. To use it, drivers should implement and
register the callbacks ieee_setmaxrate and ieee_getmaxrate. The units are 64
bits long and specified in Kbps to enable usage over both slow and very fast
networks.
Signed-off-by: Amir Vadai <amirv@mellanox.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'include/linux')
-rw-r--r-- | include/linux/dcbnl.h | 12 |
1 files changed, 12 insertions, 0 deletions
diff --git a/include/linux/dcbnl.h b/include/linux/dcbnl.h index 65a2562..6bb4338 100644 --- a/include/linux/dcbnl.h +++ b/include/linux/dcbnl.h @@ -67,6 +67,17 @@ struct ieee_ets { __u8 reco_prio_tc[IEEE_8021QAZ_MAX_TCS]; }; +/* This structure contains rate limit extension to the IEEE 802.1Qaz ETS + * managed object. + * Values are 64 bits long and specified in Kbps to enable usage over both + * slow and very fast networks. + * + * @tc_maxrate: maximal tc tx bandwidth indexed by traffic class + */ +struct ieee_maxrate { + __u64 tc_maxrate[IEEE_8021QAZ_MAX_TCS]; +}; + /* This structure contains the IEEE 802.1Qaz PFC managed object * * @pfc_cap: Indicates the number of traffic classes on the local device @@ -321,6 +332,7 @@ enum ieee_attrs { DCB_ATTR_IEEE_PEER_ETS, DCB_ATTR_IEEE_PEER_PFC, DCB_ATTR_IEEE_PEER_APP, + DCB_ATTR_IEEE_MAXRATE, __DCB_ATTR_IEEE_MAX }; #define DCB_ATTR_IEEE_MAX (__DCB_ATTR_IEEE_MAX - 1) |