diff options
author | Daniel Borkmann <dborkman@redhat.com> | 2013-08-06 21:18:12 +0200 |
---|---|---|
committer | David S. Miller <davem@davemloft.net> | 2013-08-09 11:33:02 -0700 |
commit | cda5f98e36576596b9230483ec52bff3cc97eb21 (patch) | |
tree | b828a60d8b6000704d91e35d10247f322a8d3ef8 /net/sctp/output.c | |
parent | 2690048c01f32bf45d1c1e1ab3079bc10ad2aea7 (diff) | |
download | op-kernel-dev-cda5f98e36576596b9230483ec52bff3cc97eb21.zip op-kernel-dev-cda5f98e36576596b9230483ec52bff3cc97eb21.tar.gz |
net: sctp: convert sctp_checksum_disable module param into sctp sysctl
Get rid of the last module parameter for SCTP and make this
configurable via sysctl for SCTP like all the rest of SCTP's
configuration knobs.
Signed-off-by: Daniel Borkmann <dborkman@redhat.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'net/sctp/output.c')
-rw-r--r-- | net/sctp/output.c | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/net/sctp/output.c b/net/sctp/output.c index 5a55c55d..cdb5f49 100644 --- a/net/sctp/output.c +++ b/net/sctp/output.c @@ -395,6 +395,7 @@ int sctp_packet_transmit(struct sctp_packet *packet) int padding; /* How much padding do we need? */ __u8 has_data = 0; struct dst_entry *dst = tp->dst; + struct net *net; unsigned char *auth = NULL; /* pointer to auth in skb data */ __u32 cksum_buf_len = sizeof(struct sctphdr); @@ -541,7 +542,9 @@ int sctp_packet_transmit(struct sctp_packet *packet) * Note: Adler-32 is no longer applicable, as has been replaced * by CRC32-C as described in <draft-ietf-tsvwg-sctpcsum-02.txt>. */ - if (!sctp_checksum_disable) { + net = dev_net(dst->dev); + + if (!net->sctp.checksum_disable) { if (!(dst->dev->features & NETIF_F_SCTP_CSUM)) { __u32 crc32 = sctp_start_cksum((__u8 *)sh, cksum_buf_len); |