| 1505 | } |
| 1506 | |
| 1507 | int |
| 1508 | bstp_set_maxage(struct bstp_state *bs, int t) |
| 1509 | { |
| 1510 | /* convert seconds to ticks */ |
| 1511 | t *= BSTP_TICK_VAL; |
| 1512 | |
| 1513 | if (t < BSTP_MIN_MAX_AGE || t > BSTP_MAX_MAX_AGE) |
| 1514 | return (EINVAL); |
| 1515 | |
| 1516 | BSTP_LOCK(bs); |
| 1517 | bs->bs_bridge_max_age = t; |
| 1518 | bstp_reinit(bs); |
| 1519 | BSTP_UNLOCK(bs); |
| 1520 | return (0); |
| 1521 | } |
| 1522 | |
| 1523 | int |
| 1524 | bstp_set_holdcount(struct bstp_state *bs, int count) |
no test coverage detected