Deleted Added
full compact
sctp_timer.c (235360) sctp_timer.c (235414)
1/*-
2 * Copyright (c) 2001-2007, by Cisco Systems, Inc. All rights reserved.
3 * Copyright (c) 2008-2011, by Randall Stewart. All rights reserved.
4 * Copyright (c) 2008-2011, by Michael Tuexen. All rights reserved.
5 *
6 * Redistribution and use in source and binary forms, with or without
7 * modification, are permitted provided that the following conditions are met:
8 *

--- 19 unchanged lines hidden (view full) ---

28 * CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE)
29 * ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF
30 * THE POSSIBILITY OF SUCH DAMAGE.
31 */
32
33/* $KAME: sctp_timer.c,v 1.29 2005/03/06 16:04:18 itojun Exp $ */
34
35#include <sys/cdefs.h>
1/*-
2 * Copyright (c) 2001-2007, by Cisco Systems, Inc. All rights reserved.
3 * Copyright (c) 2008-2011, by Randall Stewart. All rights reserved.
4 * Copyright (c) 2008-2011, by Michael Tuexen. All rights reserved.
5 *
6 * Redistribution and use in source and binary forms, with or without
7 * modification, are permitted provided that the following conditions are met:
8 *

--- 19 unchanged lines hidden (view full) ---

28 * CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE)
29 * ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF
30 * THE POSSIBILITY OF SUCH DAMAGE.
31 */
32
33/* $KAME: sctp_timer.c,v 1.29 2005/03/06 16:04:18 itojun Exp $ */
34
35#include <sys/cdefs.h>
36__FBSDID("$FreeBSD: head/sys/netinet/sctp_timer.c 235360 2012-05-12 20:11:35Z tuexen $");
36__FBSDID("$FreeBSD: head/sys/netinet/sctp_timer.c 235414 2012-05-13 17:36:04Z tuexen $");
37
38#define _IP_VHL
39#include <netinet/sctp_os.h>
40#include <netinet/sctp_pcb.h>
41#ifdef INET6
42#endif
43#include <netinet/sctp_var.h>
44#include <netinet/sctp_sysctl.h>

--- 51 unchanged lines hidden (view full) ---

96 net->failure_threshold);
97 if (net->error_count > net->failure_threshold) {
98 /* We had a threshold failure */
99 if (net->dest_state & SCTP_ADDR_REACHABLE) {
100 net->dest_state &= ~SCTP_ADDR_REACHABLE;
101 net->dest_state &= ~SCTP_ADDR_REQ_PRIMARY;
102 net->dest_state &= ~SCTP_ADDR_PF;
103 sctp_ulp_notify(SCTP_NOTIFY_INTERFACE_DOWN,
37
38#define _IP_VHL
39#include <netinet/sctp_os.h>
40#include <netinet/sctp_pcb.h>
41#ifdef INET6
42#endif
43#include <netinet/sctp_var.h>
44#include <netinet/sctp_sysctl.h>

--- 51 unchanged lines hidden (view full) ---

96 net->failure_threshold);
97 if (net->error_count > net->failure_threshold) {
98 /* We had a threshold failure */
99 if (net->dest_state & SCTP_ADDR_REACHABLE) {
100 net->dest_state &= ~SCTP_ADDR_REACHABLE;
101 net->dest_state &= ~SCTP_ADDR_REQ_PRIMARY;
102 net->dest_state &= ~SCTP_ADDR_PF;
103 sctp_ulp_notify(SCTP_NOTIFY_INTERFACE_DOWN,
104 stcb,
105 SCTP_FAILED_THRESHOLD,
104 stcb, 0,
106 (void *)net, SCTP_SO_NOT_LOCKED);
107 }
108 } else if ((net->pf_threshold < net->failure_threshold) &&
109 (net->error_count > net->pf_threshold)) {
110 if (!(net->dest_state & SCTP_ADDR_PF)) {
111 net->dest_state |= SCTP_ADDR_PF;
112 net->last_active = sctp_get_tick_count();
113 sctp_send_hb(stcb, net, SCTP_SO_NOT_LOCKED);

--- 1484 unchanged lines hidden ---
105 (void *)net, SCTP_SO_NOT_LOCKED);
106 }
107 } else if ((net->pf_threshold < net->failure_threshold) &&
108 (net->error_count > net->pf_threshold)) {
109 if (!(net->dest_state & SCTP_ADDR_PF)) {
110 net->dest_state |= SCTP_ADDR_PF;
111 net->last_active = sctp_get_tick_count();
112 sctp_send_hb(stcb, net, SCTP_SO_NOT_LOCKED);

--- 1484 unchanged lines hidden ---