net: sched: remove redundant helpers tcf_exts_is_predicative and tcf_exts_is_available

These two helpers are doing the same as tcf_exts_has_actions, so remove
them and use tcf_exts_has_actions instead.

Signed-off-by: Jiri Pirko <jiri@mellanox.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
This commit is contained in:
Jiri Pirko
2017-08-04 14:29:00 +02:00
committed by David S. Miller
parent af69afc551
commit 6fc6d06e53
4 changed files with 3 additions and 33 deletions

View File

@@ -113,36 +113,6 @@ static inline int tcf_exts_init(struct tcf_exts *exts, int action, int police)
return 0;
}
/**
* tcf_exts_is_predicative - check if a predicative extension is present
* @exts: tc filter extensions handle
*
* Returns 1 if a predicative extension is present, i.e. an extension which
* might cause further actions and thus overrule the regular tcf_result.
*/
static inline int
tcf_exts_is_predicative(struct tcf_exts *exts)
{
#ifdef CONFIG_NET_CLS_ACT
return exts->nr_actions;
#else
return 0;
#endif
}
/**
* tcf_exts_is_available - check if at least one extension is present
* @exts: tc filter extensions handle
*
* Returns 1 if at least one extension is present.
*/
static inline int
tcf_exts_is_available(struct tcf_exts *exts)
{
/* All non-predicative extensions must be added here. */
return tcf_exts_is_predicative(exts);
}
static inline void tcf_exts_to_list(const struct tcf_exts *exts,
struct list_head *actions)
{