diff options
author | Xin Long <lucien.xin@gmail.com> | 2017-05-31 11:36:31 +0300 |
---|---|---|
committer | David S. Miller <davem@davemloft.net> | 2017-06-02 20:56:26 +0300 |
commit | cee360ab4dd66fc1de33a5fa1cb418fa21c27ce3 (patch) | |
tree | db9b8575e7392b314e94a946590b71bb5c856e64 /net/sctp/sm_make_chunk.c | |
parent | 6e7da286e3513ac1e107ef8dffa5f254029d68e7 (diff) | |
download | linux-cee360ab4dd66fc1de33a5fa1cb418fa21c27ce3.tar.xz |
sctp: define the member stream as an object instead of pointer in asoc
As Marcelo's suggestion, stream is a fixed size member of asoc and would
not grow with more streams. To avoid an allocation for it, this patch is
to define it as an object instead of pointer and update the places using
it, also create sctp_stream_update() called in sctp_assoc_update() to
migrate the stream info from one stream to another.
Signed-off-by: Xin Long <lucien.xin@gmail.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'net/sctp/sm_make_chunk.c')
-rw-r--r-- | net/sctp/sm_make_chunk.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/net/sctp/sm_make_chunk.c b/net/sctp/sm_make_chunk.c index 92e332e17391..244181413bca 100644 --- a/net/sctp/sm_make_chunk.c +++ b/net/sctp/sm_make_chunk.c @@ -1544,7 +1544,7 @@ void sctp_chunk_assign_ssn(struct sctp_chunk *chunk) /* All fragments will be on the same stream */ sid = ntohs(chunk->subh.data_hdr->stream); - stream = chunk->asoc->stream; + stream = &chunk->asoc->stream; /* Now assign the sequence number to the entire message. * All fragments must have the same stream sequence number. |