Revert "net: sctp: convert sctp_checksum_disable module param into sctp sysctl"

This reverts commit cda5f98e36576596b9230483ec52bff3cc97eb21.

As per Vlad's request.

Signed-off-by: David S. Miller <davem@davemloft.net>
diff --git a/net/sctp/input.c b/net/sctp/input.c
index 2873e22..5f20686 100644
--- a/net/sctp/input.c
+++ b/net/sctp/input.c
@@ -134,8 +134,8 @@
 	__skb_pull(skb, skb_transport_offset(skb));
 	if (skb->len < sizeof(struct sctphdr))
 		goto discard_it;
-	if (!net->sctp.checksum_disable && !skb_csum_unnecessary(skb) &&
-	    sctp_rcv_checksum(net, skb) < 0)
+	if (!sctp_checksum_disable && !skb_csum_unnecessary(skb) &&
+		  sctp_rcv_checksum(net, skb) < 0)
 		goto discard_it;
 
 	skb_pull(skb, sizeof(struct sctphdr));
diff --git a/net/sctp/output.c b/net/sctp/output.c
index e35b84c..0ac3a65 100644
--- a/net/sctp/output.c
+++ b/net/sctp/output.c
@@ -389,7 +389,6 @@
 	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);
 
@@ -536,9 +535,7 @@
 	 * Note: Adler-32 is no longer applicable, as has been replaced
 	 * by CRC32-C as described in <draft-ietf-tsvwg-sctpcsum-02.txt>.
 	 */
-	net = dev_net(dst->dev);
-
-	if (!net->sctp.checksum_disable) {
+	if (!sctp_checksum_disable) {
 		if (!(dst->dev->features & NETIF_F_SCTP_CSUM)) {
 			__u32 crc32 = sctp_start_cksum((__u8 *)sh, cksum_buf_len);
 
diff --git a/net/sctp/protocol.c b/net/sctp/protocol.c
index 5448297..5e17092 100644
--- a/net/sctp/protocol.c
+++ b/net/sctp/protocol.c
@@ -1187,9 +1187,6 @@
 	/* Whether Cookie Preservative is enabled(1) or not(0) */
 	net->sctp.cookie_preserve_enable 	= 1;
 
-	/* Whether SCTP checksumming is disabled(1) or not(0) */
-	net->sctp.checksum_disable		= 0;
-
 	/* Default sctp sockets to use md5 as their hmac alg */
 #if defined (CONFIG_SCTP_DEFAULT_COOKIE_HMAC_MD5)
 	net->sctp.sctp_hmac_alg			= "md5";
@@ -1546,4 +1543,6 @@
 MODULE_ALIAS("net-pf-" __stringify(PF_INET6) "-proto-132");
 MODULE_AUTHOR("Linux Kernel SCTP developers <linux-sctp@vger.kernel.org>");
 MODULE_DESCRIPTION("Support for the SCTP protocol (RFC2960)");
+module_param_named(no_checksums, sctp_checksum_disable, bool, 0644);
+MODULE_PARM_DESC(no_checksums, "Disable checksums computing and verification");
 MODULE_LICENSE("GPL");
diff --git a/net/sctp/sysctl.c b/net/sctp/sysctl.c
index 1b1ee76..6b36561 100644
--- a/net/sctp/sysctl.c
+++ b/net/sctp/sysctl.c
@@ -290,15 +290,7 @@
 		.extra1		= &max_autoclose_min,
 		.extra2		= &max_autoclose_max,
 	},
-	{
-		.procname	= "checksum_disable",
-		.data		= &init_net.sctp.checksum_disable,
-		.maxlen		= sizeof(int),
-		.mode		= 0644,
-		.proc_handler	= proc_dointvec_minmax,
-		.extra1		= &zero,
-		.extra2		= &one,
-	},
+
 	{ /* sentinel */ }
 };