summaryrefslogtreecommitdiffstats
path: root/sys/net/bridgestp.c
diff options
context:
space:
mode:
authorthompsa <thompsa@FreeBSD.org>2012-02-23 20:58:52 +0000
committerthompsa <thompsa@FreeBSD.org>2012-02-23 20:58:52 +0000
commitdc536a5db9b7b0b09ddaf1d12a42331848272300 (patch)
treefeada0390dc2fbe7d6ee994421962769b1205842 /sys/net/bridgestp.c
parent7abb8d8e396611d0644e5c39b559fc67d0800aec (diff)
downloadFreeBSD-src-dc536a5db9b7b0b09ddaf1d12a42331848272300.zip
FreeBSD-src-dc536a5db9b7b0b09ddaf1d12a42331848272300.tar.gz
Indicate this function decrements the timer as well as testing for expiry.
Diffstat (limited to 'sys/net/bridgestp.c')
-rw-r--r--sys/net/bridgestp.c22
1 files changed, 11 insertions, 11 deletions
diff --git a/sys/net/bridgestp.c b/sys/net/bridgestp.c
index 445d643..394a50a 100644
--- a/sys/net/bridgestp.c
+++ b/sys/net/bridgestp.c
@@ -134,7 +134,7 @@ static void bstp_tick(void *);
static void bstp_timer_start(struct bstp_timer *, uint16_t);
static void bstp_timer_stop(struct bstp_timer *);
static void bstp_timer_latch(struct bstp_timer *);
-static int bstp_timer_expired(struct bstp_timer *);
+static int bstp_timer_dectest(struct bstp_timer *);
static void bstp_hello_timer_expiry(struct bstp_state *,
struct bstp_port *);
static void bstp_message_age_expiry(struct bstp_state *,
@@ -1862,7 +1862,7 @@ bstp_tick(void *arg)
CURVNET_SET(bs->bs_vnet);
/* poll link events on interfaces that do not support linkstate */
- if (bstp_timer_expired(&bs->bs_link_timer)) {
+ if (bstp_timer_dectest(&bs->bs_link_timer)) {
LIST_FOREACH(bp, &bs->bs_bplist, bp_next) {
if (!(bp->bp_ifp->if_capabilities & IFCAP_LINKSTATE))
bstp_ifupdstatus(bs, bp);
@@ -1872,21 +1872,21 @@ bstp_tick(void *arg)
LIST_FOREACH(bp, &bs->bs_bplist, bp_next) {
/* no events need to happen for these */
- bstp_timer_expired(&bp->bp_tc_timer);
- bstp_timer_expired(&bp->bp_recent_root_timer);
- bstp_timer_expired(&bp->bp_forward_delay_timer);
- bstp_timer_expired(&bp->bp_recent_backup_timer);
+ bstp_timer_dectest(&bp->bp_tc_timer);
+ bstp_timer_dectest(&bp->bp_recent_root_timer);
+ bstp_timer_dectest(&bp->bp_forward_delay_timer);
+ bstp_timer_dectest(&bp->bp_recent_backup_timer);
- if (bstp_timer_expired(&bp->bp_hello_timer))
+ if (bstp_timer_dectest(&bp->bp_hello_timer))
bstp_hello_timer_expiry(bs, bp);
- if (bstp_timer_expired(&bp->bp_message_age_timer))
+ if (bstp_timer_dectest(&bp->bp_message_age_timer))
bstp_message_age_expiry(bs, bp);
- if (bstp_timer_expired(&bp->bp_migrate_delay_timer))
+ if (bstp_timer_dectest(&bp->bp_migrate_delay_timer))
bstp_migrate_delay_expiry(bs, bp);
- if (bstp_timer_expired(&bp->bp_edge_delay_timer))
+ if (bstp_timer_dectest(&bp->bp_edge_delay_timer))
bstp_edge_delay_expiry(bs, bp);
/* update the various state machines for the port */
@@ -1925,7 +1925,7 @@ bstp_timer_latch(struct bstp_timer *t)
}
static int
-bstp_timer_expired(struct bstp_timer *t)
+bstp_timer_dectest(struct bstp_timer *t)
{
if (t->active == 0 || t->latched)
return (0);
OpenPOWER on IntegriCloud