History

net: ethool: Document struct ethtool_flow_ext

Add documentation for struct ethtool_flow_ext especially in regard to what flags are needed for which fields.

Yan Burman committed 13 years ago

Commit dc2e5731 parent 7bdc1b41 file · +14 −2Browse files

Showing the changes to include/uapi/linux (1 of 1 file). Show all

Unified · Split

include/uapi/linux/ethtool.h+14−2
@@ -503,9 +503,20 @@ union ethtool_flow_union { · 502 unmodified lines
503503 __u8 hdata[52];
504504 };
505505
506+/**
507+ * struct ethtool_flow_ext - additional RX flow fields
508+ * @h_dest: destination MAC address
509+ * @vlan_etype: VLAN EtherType
510+ * @vlan_tci: VLAN tag control information
511+ * @data: user defined data
512+ *
513+ * Note, @vlan_etype, @vlan_tci, and @data are only valid if %FLOW_EXT
514+ * is set in &struct ethtool_rx_flow_spec @flow_type.
515+ * @h_dest is valid if %FLOW_MAC_EXT is set.
516+ */
506517 struct ethtool_flow_ext {
507518 __u8 padding[2];
508− unsigned char h_dest[ETH_ALEN]; /* destination eth addr */
519+ unsigned char h_dest[ETH_ALEN];
509520 __be16 vlan_etype;
510521 __be16 vlan_tci;
511522 __be32 data[2];
@@ -519,7 +530,8 @@ struct ethtool_flow_ext { · 7 unmodified lines
519530 * @m_u: Masks for flow field bits to be matched
520531 * @m_ext: Masks for additional field bits to be matched
521532 * Note, all additional fields must be ignored unless @flow_type
522− * includes the %FLOW_EXT flag.
533+ * includes the %FLOW_EXT or %FLOW_MAC_EXT flag
534+ * (see &struct ethtool_flow_ext description).
523535 * @ring_cookie: RX ring/queue index to deliver to, or %RX_CLS_FLOW_DISC
524536 * if packets should be discarded
525537 * @location: Location of rule in the table. Locations must be