From owner-cvs-src@FreeBSD.ORG Sun Jul 29 22:00:07 2007 Return-Path: Delivered-To: cvs-src@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 53CDC16A41A; Sun, 29 Jul 2007 22:00:07 +0000 (UTC) (envelope-from bz@FreeBSD.org) Received: from mail.cksoft.de (mail.cksoft.de [62.111.66.27]) by mx1.freebsd.org (Postfix) with ESMTP id 085E013C442; Sun, 29 Jul 2007 22:00:06 +0000 (UTC) (envelope-from bz@FreeBSD.org) Received: from localhost (amavis.str.cksoft.de [192.168.74.71]) by mail.cksoft.de (Postfix) with ESMTP id EDD3241C732; Mon, 30 Jul 2007 00:00:05 +0200 (CEST) X-Virus-Scanned: amavisd-new at cksoft.de Received: from mail.cksoft.de ([62.111.66.27]) by localhost (amavis.str.cksoft.de [192.168.74.71]) (amavisd-new, port 10024) with ESMTP id gdGchfXBhYJb; Mon, 30 Jul 2007 00:00:05 +0200 (CEST) Received: by mail.cksoft.de (Postfix, from userid 66) id 828A741C730; Mon, 30 Jul 2007 00:00:05 +0200 (CEST) Received: from maildrop.int.zabbadoz.net (maildrop.int.zabbadoz.net [10.111.66.10]) (using TLSv1 with cipher DHE-RSA-AES256-SHA (256/256 bits)) (No client certificate requested) by mail.int.zabbadoz.net (Postfix) with ESMTP id 340EA444885; Sun, 29 Jul 2007 21:58:10 +0000 (UTC) Date: Sun, 29 Jul 2007 21:58:10 +0000 (UTC) From: "Bjoern A. Zeeb" X-X-Sender: bz@maildrop.int.zabbadoz.net To: mjacob@freebsd.org In-Reply-To: <20070729143653.E86313@ns1.feral.com> Message-ID: <20070729214715.I31116@maildrop.int.zabbadoz.net> References: <200707290131.l6T1VY8g026872@repoman.freebsd.org> <46AC987A.9040501@freebsd.org> <20070729184123.S44136@mp2.macomnet.net> <20070729095743.N84864@ns1.feral.com> <20070729101357.A84864@ns1.feral.com> <20070729101935.D84864@ns1.feral.com> <20070729211359.C31116@maildrop.int.zabbadoz.net> <20070729143653.E86313@ns1.feral.com> MIME-Version: 1.0 Content-Type: TEXT/PLAIN; charset=US-ASCII; format=flowed Cc: cvs-src@freebsd.org, src-committers@freebsd.org, cvs-all@freebsd.org Subject: Re: cvs commit: src/sys/netinet tcp_input.c tcp_usrreq.c X-BeenThere: cvs-src@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: CVS commit messages for the src tree List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 29 Jul 2007 22:00:07 -0000 On Sun, 29 Jul 2007, mjacob@freebsd.org wrote: Hi, > On Sun, 29 Jul 2007, Bjoern A. Zeeb wrote: > >> On Sun, 29 Jul 2007, mjacob@freebsd.org wrote: >> >>> Here's what probably works. I'll do the test compiles. >> >> If I am not wrong it will not. >> >> The follwoing two files have comments at the beginning to explain the >> changes. >> I don't like the extern char *tcpstates[] but it seems to be the best >> solution for now. > > No, that's what's actually wrong. tcpstates has to be static to honor the > intent of the original author. If you want to do something extern then the > actual tcpstates should go into tcp_debug.c. However, this is slightly less > flexible in that the way it is now each source file can include this array > simply by defining TCPSTATES (independent of TCPDEBUG as an option). It should go int tcp_input.c if any because that's the only file that always needs it now. If you do not have TCP there will be no tcp_input and TCPDEBUG will make no sense but there can be a tcp_input without TCPDEBUG/tcp_debug. It has been used with the extern in netipx since 1995. It is exposed to user space so moving it out of the header will break things. If you have any other better short term solution to not break anything I am happy but I could not see one. As said, I am not happy with the extern either. -- Bjoern A. Zeeb bzeeb at Zabbadoz dot NeT Software is harder than hardware so better get it right the first time.