diff options
Diffstat (limited to 'include/net/act_api.h')
-rw-r--r-- | include/net/act_api.h | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/include/net/act_api.h b/include/net/act_api.h index 8389c007076f..a891978310e9 100644 --- a/include/net/act_api.h +++ b/include/net/act_api.h @@ -80,6 +80,14 @@ static inline void tcf_lastuse_update(struct tcf_t *tm) tm->firstuse = now; } +static inline void tcf_tm_dump(struct tcf_t *dtm, const struct tcf_t *stm) +{ + dtm->install = jiffies_to_clock_t(jiffies - stm->install); + dtm->lastuse = jiffies_to_clock_t(jiffies - stm->lastuse); + dtm->firstuse = jiffies_to_clock_t(jiffies - stm->firstuse); + dtm->expires = jiffies_to_clock_t(stm->expires); +} + struct tc_action { void *priv; const struct tc_action_ops *ops; |