aboutsummaryrefslogtreecommitdiff
path: root/sys/netinet/sctputil.c
diff options
context:
space:
mode:
authorMichael Tuexen <tuexen@FreeBSD.org>2017-10-14 10:02:59 +0000
committerMichael Tuexen <tuexen@FreeBSD.org>2017-10-14 10:02:59 +0000
commit8c8e10b763684442d614bc0eb978fd90789cd2a6 (patch)
tree5095a3a78d1c43c80cb956c03e2b981d0bfc3635 /sys/netinet/sctputil.c
parentbf3341233e14616b4f7d3c9ecca0d80a1c131724 (diff)
downloadsrc-8c8e10b763684442d614bc0eb978fd90789cd2a6.tar.gz
src-8c8e10b763684442d614bc0eb978fd90789cd2a6.zip
Code cleanup, not functional change.
This avoids taking a pointer of a packed structure which allows simpler compilation of the userland stack. MFC after: 1 week
Notes
Notes: svn path=/head/; revision=324615
Diffstat (limited to 'sys/netinet/sctputil.c')
-rw-r--r--sys/netinet/sctputil.c19
1 files changed, 4 insertions, 15 deletions
diff --git a/sys/netinet/sctputil.c b/sys/netinet/sctputil.c
index c7bb60eb1be4..ccc0b69e7e3b 100644
--- a/sys/netinet/sctputil.c
+++ b/sys/netinet/sctputil.c
@@ -2422,8 +2422,8 @@ uint32_t
sctp_calculate_rto(struct sctp_tcb *stcb,
struct sctp_association *asoc,
struct sctp_nets *net,
- struct timeval *told,
- int safe, int rtt_from_sack)
+ struct timeval *old,
+ int rtt_from_sack)
{
/*-
* given an association and the starting time of the current RTT
@@ -2432,19 +2432,8 @@ sctp_calculate_rto(struct sctp_tcb *stcb,
int32_t rtt; /* RTT in ms */
uint32_t new_rto;
int first_measure = 0;
- struct timeval now, then, *old;
-
- /* Copy it out for sparc64 */
- if (safe == sctp_align_unsafe_makecopy) {
- old = &then;
- memcpy(&then, told, sizeof(struct timeval));
- } else if (safe == sctp_align_safe_nocopy) {
- old = told;
- } else {
- /* error */
- SCTP_PRINTF("Huh, bad rto calc call\n");
- return (0);
- }
+ struct timeval now;
+
/************************/
/* 1. calculate new RTT */
/************************/