From owner-freebsd-bugs@FreeBSD.ORG Fri Apr 27 11:00:22 2012 Return-Path: Delivered-To: freebsd-bugs@hub.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 62D361065678 for ; Fri, 27 Apr 2012 11:00:22 +0000 (UTC) (envelope-from gnats@FreeBSD.org) Received: from freefall.freebsd.org (freefall.freebsd.org [IPv6:2001:4f8:fff6::28]) by mx1.freebsd.org (Postfix) with ESMTP id 2F0688FC1C for ; Fri, 27 Apr 2012 11:00:22 +0000 (UTC) Received: from freefall.freebsd.org (localhost [127.0.0.1]) by freefall.freebsd.org (8.14.5/8.14.5) with ESMTP id q3RB0MOC027855 for ; Fri, 27 Apr 2012 11:00:22 GMT (envelope-from gnats@freefall.freebsd.org) Received: (from gnats@localhost) by freefall.freebsd.org (8.14.5/8.14.5/Submit) id q3RB0MHB027854; Fri, 27 Apr 2012 11:00:22 GMT (envelope-from gnats) Resent-Date: Fri, 27 Apr 2012 11:00:22 GMT Resent-Message-Id: <201204271100.q3RB0MHB027854@freefall.freebsd.org> Resent-From: FreeBSD-gnats-submit@FreeBSD.org (GNATS Filer) Resent-To: freebsd-bugs@FreeBSD.org Resent-Reply-To: FreeBSD-gnats-submit@FreeBSD.org, Adri Koppes Received: from mx1.freebsd.org (mx1.freebsd.org [69.147.83.52]) by hub.freebsd.org (Postfix) with ESMTP id AEA691065670 for ; Fri, 27 Apr 2012 10:51:28 +0000 (UTC) (envelope-from nobody@FreeBSD.org) Received: from red.freebsd.org (red.freebsd.org [IPv6:2001:4f8:fff6::22]) by mx1.freebsd.org (Postfix) with ESMTP id 9775C8FC19 for ; Fri, 27 Apr 2012 10:51:28 +0000 (UTC) Received: from red.freebsd.org (localhost [127.0.0.1]) by red.freebsd.org (8.14.4/8.14.4) with ESMTP id q3RApSJr075837 for ; Fri, 27 Apr 2012 10:51:28 GMT (envelope-from nobody@red.freebsd.org) Received: (from nobody@localhost) by red.freebsd.org (8.14.4/8.14.4/Submit) id q3RApRWE075826; Fri, 27 Apr 2012 10:51:27 GMT (envelope-from nobody) Message-Id: <201204271051.q3RApRWE075826@red.freebsd.org> Date: Fri, 27 Apr 2012 10:51:27 GMT From: Adri Koppes To: freebsd-gnats-submit@FreeBSD.org X-Send-Pr-Version: www-3.1 Cc: Subject: kern/167357: cc_htcp(4) module sysctl variables overwritten X-BeenThere: freebsd-bugs@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Bug reports List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 27 Apr 2012 11:00:22 -0000 >Number: 167357 >Category: kern >Synopsis: cc_htcp(4) module sysctl variables overwritten >Confidential: no >Severity: non-critical >Priority: medium >Responsible: freebsd-bugs >State: open >Quarter: >Keywords: >Date-Required: >Class: sw-bug >Submitter-Id: current-users >Arrival-Date: Fri Apr 27 11:00:21 UTC 2012 >Closed-Date: >Last-Modified: >Originator: Adri Koppes >Release: 8.3-RELEASE >Organization: SalesManager Software B.V. >Environment: FreeBSD mail.salesmanager.nl 8.3-RELEASE FreeBSD 8.3-RELEASE #11: Mon Apr 23 17:07:46 CEST 2012 root@mail.salesmanager.nl:/usr/obj/usr/src/sys/MAIL amd64 >Description: When using sysctl to change variables of the cc_htcp(4) module, changing 1 variable will also change the values of other variables. >How-To-Repeat: # kldload cc_htcp.ko # sysctl net.inet.tcp.cc.htcp net.inet.tcp.cc.htcp.rtt_scaling: 0 net.inet.tcp.cc.htcp.adaptive_backoff: 0 # sysctl net.inet.tcp.cc.htcp.rtt_scaling=1 net.inet.tcp.cc.htcp.rtt_scaling: 0 -> 1 # sysctl net.inet.tcp.cc.htcp net.inet.tcp.cc.htcp.rtt_scaling: 1 net.inet.tcp.cc.htcp.adaptive_backoff: 0 # sysctl net.inet.tcp.cc.htcp.adaptive_backoff=1 net.inet.tcp.cc.htcp.adaptive_backoff: 0 -> 1 # sysctl net.inet.tcp.cc.htcp net.inet.tcp.cc.htcp.rtt_scaling: 257 net.inet.tcp.cc.htcp.adaptive_backoff: 1 >Fix: The problem is probably caused by a mismatch in variable declaration and sysctl definition in /usr/src/sys/netinet/cc/cc_htcp.c. Line 171: static VNET_DEFINE(uint8_t, htcp_adaptive_backoff) = 0; static VNET_DEFINE(uint8_t, htcp_rtt_scaling) = 0; Line 515: SYSCTL_VNET_UINT(_net_inet_tcp_cc_htcp, OID_AUTO, adaptive_backoff, CTLFLAG_RW, &VNET_NAME(htcp_adaptive_backoff), 0, "enable H-TCP adaptive backoff"); SYSCTL_VNET_UINT(_net_inet_tcp_cc_htcp, OID_AUTO, rtt_scaling, CTLFLAG_RW, &VNET_NAME(htcp_rtt_scaling), 0, "enable H-TCP RTT scaling"); >Release-Note: >Audit-Trail: >Unformatted: