mirror of
https://git.rtems.org/rtems-libbsd/
synced 2025-10-18 05:13:03 +08:00
Update to FreeBSD head 2018-02-01
Git mirror commit d079ae0442af8fa3cfd6d7ede190d04e64a2c0d4. Update #3472.
This commit is contained in:
@@ -3209,9 +3209,9 @@ sctp_handle_ecn_cwr(struct sctp_cwr_chunk *cp, struct sctp_tcb *stcb, struct sct
|
||||
stcb->asoc.ecn_echo_cnt_onq--;
|
||||
TAILQ_REMOVE(&stcb->asoc.control_send_queue, chk,
|
||||
sctp_next);
|
||||
stcb->asoc.ctrl_queue_cnt--;
|
||||
sctp_m_freem(chk->data);
|
||||
chk->data = NULL;
|
||||
stcb->asoc.ctrl_queue_cnt--;
|
||||
sctp_free_a_chunk(stcb, chk, SCTP_SO_NOT_LOCKED);
|
||||
if (override == 0) {
|
||||
break;
|
||||
@@ -3643,26 +3643,23 @@ static void
|
||||
sctp_clean_up_stream_reset(struct sctp_tcb *stcb)
|
||||
{
|
||||
struct sctp_association *asoc;
|
||||
struct sctp_tmit_chunk *chk = stcb->asoc.str_reset;
|
||||
struct sctp_tmit_chunk *chk;
|
||||
|
||||
if (stcb->asoc.str_reset == NULL) {
|
||||
asoc = &stcb->asoc;
|
||||
chk = asoc->str_reset;
|
||||
if (chk == NULL) {
|
||||
return;
|
||||
}
|
||||
asoc = &stcb->asoc;
|
||||
|
||||
asoc->str_reset = NULL;
|
||||
sctp_timer_stop(SCTP_TIMER_TYPE_STRRESET, stcb->sctp_ep, stcb,
|
||||
chk->whoTo, SCTP_FROM_SCTP_INPUT + SCTP_LOC_28);
|
||||
TAILQ_REMOVE(&asoc->control_send_queue,
|
||||
chk,
|
||||
sctp_next);
|
||||
TAILQ_REMOVE(&asoc->control_send_queue, chk, sctp_next);
|
||||
asoc->ctrl_queue_cnt--;
|
||||
if (chk->data) {
|
||||
sctp_m_freem(chk->data);
|
||||
chk->data = NULL;
|
||||
}
|
||||
asoc->ctrl_queue_cnt--;
|
||||
sctp_free_a_chunk(stcb, chk, SCTP_SO_NOT_LOCKED);
|
||||
/* sa_ignore NO_NULL_CHK */
|
||||
stcb->asoc.str_reset = NULL;
|
||||
}
|
||||
|
||||
|
||||
@@ -5509,9 +5506,7 @@ void
|
||||
sctp_common_input_processing(struct mbuf **mm, int iphlen, int offset, int length,
|
||||
struct sockaddr *src, struct sockaddr *dst,
|
||||
struct sctphdr *sh, struct sctp_chunkhdr *ch,
|
||||
#if !defined(SCTP_WITH_NO_CSUM)
|
||||
uint8_t compute_crc,
|
||||
#endif
|
||||
uint8_t ecn_bits,
|
||||
uint8_t mflowtype, uint32_t mflowid, uint16_t fibnum,
|
||||
uint32_t vrf_id, uint16_t port)
|
||||
@@ -5531,7 +5526,6 @@ sctp_common_input_processing(struct mbuf **mm, int iphlen, int offset, int lengt
|
||||
sctp_audit_log(0xE0, 1);
|
||||
sctp_auditing(0, inp, stcb, net);
|
||||
#endif
|
||||
#if !defined(SCTP_WITH_NO_CSUM)
|
||||
if (compute_crc != 0) {
|
||||
uint32_t check, calc_check;
|
||||
|
||||
@@ -5576,7 +5570,6 @@ sctp_common_input_processing(struct mbuf **mm, int iphlen, int offset, int lengt
|
||||
goto out;
|
||||
}
|
||||
}
|
||||
#endif
|
||||
/* Destination port of 0 is illegal, based on RFC4960. */
|
||||
if (sh->dest_port == 0) {
|
||||
SCTP_STAT_INCR(sctps_hdrops);
|
||||
@@ -5894,9 +5887,7 @@ sctp_input_with_port(struct mbuf *i_pak, int off, uint16_t port)
|
||||
struct sctphdr *sh;
|
||||
struct sctp_chunkhdr *ch;
|
||||
int length, offset;
|
||||
#if !defined(SCTP_WITH_NO_CSUM)
|
||||
uint8_t compute_crc;
|
||||
#endif
|
||||
uint32_t mflowid;
|
||||
uint8_t mflowtype;
|
||||
uint16_t fibnum;
|
||||
@@ -5966,9 +5957,6 @@ sctp_input_with_port(struct mbuf *i_pak, int off, uint16_t port)
|
||||
goto out;
|
||||
}
|
||||
ecn_bits = ip->ip_tos;
|
||||
#if defined(SCTP_WITH_NO_CSUM)
|
||||
SCTP_STAT_INCR(sctps_recvnocrc);
|
||||
#else
|
||||
if (m->m_pkthdr.csum_flags & CSUM_SCTP_VALID) {
|
||||
SCTP_STAT_INCR(sctps_recvhwcrc);
|
||||
compute_crc = 0;
|
||||
@@ -5976,14 +5964,11 @@ sctp_input_with_port(struct mbuf *i_pak, int off, uint16_t port)
|
||||
SCTP_STAT_INCR(sctps_recvswcrc);
|
||||
compute_crc = 1;
|
||||
}
|
||||
#endif
|
||||
sctp_common_input_processing(&m, iphlen, offset, length,
|
||||
(struct sockaddr *)&src,
|
||||
(struct sockaddr *)&dst,
|
||||
sh, ch,
|
||||
#if !defined(SCTP_WITH_NO_CSUM)
|
||||
compute_crc,
|
||||
#endif
|
||||
ecn_bits,
|
||||
mflowtype, mflowid, fibnum,
|
||||
vrf_id, port);
|
||||
|
Reference in New Issue
Block a user