aboutsummaryrefslogtreecommitdiffstats
path: root/include/linux/if_team.h
diff options
context:
space:
mode:
authorJiri Pirko <jpirko@redhat.com>2012-06-19 01:54:08 -0400
committerDavid S. Miller <davem@davemloft.net>2012-06-19 18:00:23 -0400
commitb13033262d2496e271444d5a09226a2be5ceb989 (patch)
treec5a78a0023f3c28425e7425a91c6fd2ac71d29d9 /include/linux/if_team.h
parentf82b959d26557fe4ce283d3b27050d4b8268ef1e (diff)
team: introduce array options
Signed-off-by: Jiri Pirko <jpirko@redhat.com> Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'include/linux/if_team.h')
-rw-r--r--include/linux/if_team.h3
1 files changed, 3 insertions, 0 deletions
diff --git a/include/linux/if_team.h b/include/linux/if_team.h
index 54af95f5d58..b1719e239a0 100644
--- a/include/linux/if_team.h
+++ b/include/linux/if_team.h
@@ -93,6 +93,7 @@ struct team_gsetter_ctx {
93 } bin_val; 93 } bin_val;
94 bool bool_val; 94 bool bool_val;
95 } data; 95 } data;
96 u32 array_index;
96 struct team_port *port; 97 struct team_port *port;
97}; 98};
98 99
@@ -100,6 +101,7 @@ struct team_option {
100 struct list_head list; 101 struct list_head list;
101 const char *name; 102 const char *name;
102 bool per_port; 103 bool per_port;
104 unsigned int array_size; /* != 0 means the option is array */
103 enum team_option_type type; 105 enum team_option_type type;
104 int (*getter)(struct team *team, struct team_gsetter_ctx *ctx); 106 int (*getter)(struct team *team, struct team_gsetter_ctx *ctx);
105 int (*setter)(struct team *team, struct team_gsetter_ctx *ctx); 107 int (*setter)(struct team *team, struct team_gsetter_ctx *ctx);
@@ -242,6 +244,7 @@ enum {
242 TEAM_ATTR_OPTION_DATA, /* dynamic */ 244 TEAM_ATTR_OPTION_DATA, /* dynamic */
243 TEAM_ATTR_OPTION_REMOVED, /* flag */ 245 TEAM_ATTR_OPTION_REMOVED, /* flag */
244 TEAM_ATTR_OPTION_PORT_IFINDEX, /* u32 */ /* for per-port options */ 246 TEAM_ATTR_OPTION_PORT_IFINDEX, /* u32 */ /* for per-port options */
247 TEAM_ATTR_OPTION_ARRAY_INDEX, /* u32 */ /* for array options */
245 248
246 __TEAM_ATTR_OPTION_MAX, 249 __TEAM_ATTR_OPTION_MAX,
247 TEAM_ATTR_OPTION_MAX = __TEAM_ATTR_OPTION_MAX - 1, 250 TEAM_ATTR_OPTION_MAX = __TEAM_ATTR_OPTION_MAX - 1,