From owner-freebsd-arch Wed Oct 16 11:19: 6 2002 Delivered-To: freebsd-arch@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id BB0E137B401; Wed, 16 Oct 2002 11:19:04 -0700 (PDT) Received: from carp.icir.org (carp.icir.org [192.150.187.71]) by mx1.FreeBSD.org (Postfix) with ESMTP id CD80343E8A; Wed, 16 Oct 2002 11:19:03 -0700 (PDT) (envelope-from rizzo@carp.icir.org) Received: from carp.icir.org (localhost [127.0.0.1]) by carp.icir.org (8.12.3/8.12.3) with ESMTP id g9GIIvpJ038254; Wed, 16 Oct 2002 11:18:57 -0700 (PDT) (envelope-from rizzo@carp.icir.org) Received: (from rizzo@localhost) by carp.icir.org (8.12.3/8.12.3/Submit) id g9GIIvl8038253; Wed, 16 Oct 2002 11:18:57 -0700 (PDT) (envelope-from rizzo) Date: Wed, 16 Oct 2002 11:18:57 -0700 From: Luigi Rizzo To: "JINMEI Tatuya / ?$B?@L@C#:H?(B" Cc: Sam Leffler , Julian Elischer , freebsd-arch@FreeBSD.ORG, freebsd-net@FreeBSD.ORG Subject: Re: CFR: m_tag patch Message-ID: <20021016111857.A38181@carp.icir.org> References: <18d301c26e5e$8b5c7a30$52557f42@errno.com> <080101c27151$b2e92a30$52557f42@errno.com> <20021016074610.C34626@carp.icir.org> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline User-Agent: Mutt/1.2.5.1i In-Reply-To: ; from jinmei@isl.rdc.toshiba.co.jp on Thu, Oct 17, 2002 at 03:07:07AM +0900 Sender: owner-freebsd-arch@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG On Thu, Oct 17, 2002 at 03:07:07AM +0900, JINMEI Tatuya / ?$B?@L@C#:H?(B wrote: ... > (I re-read the thread) perhaps the example in my previous message > wasn't good (and it was at least incorrect). According to the > discussion on the thread, we'll probably keep m_tag_cookie being 0 and > use m_tag_id in (e.g.) ip6_output.c. So, we'll be happy if this > convention is kept (and will be kept) at least under netinet6. unfortunately this will not prevent code from having to check that the m_tag_cookie actually corresponds to the value you want, to make sure that your code does not misinterpret as own tags generated/destined to other clients. Am I correct, Sam ? > > Also note that in your example the code should be conditional > > on __FreeBSD_version and not on __FreeBSD__ > > We (KAME) actually need __FreeBSD__, because we want to keep a single > code base for all *BSDs (again, I know this is our local issue). But, i know it is a minor point, but we had this discussion before (and hit related bugs during cross builds). __FreeBSD__ refers to the build environment, whereas __FreeBSD_version matches the source tree you are building, and it is #defined on all versions of FreeBSD that you care about. So, should you have FreeBSD-specific code (hopefully as little as possible), you should *never* use __FreeBSD__ but instead use only __FreeBSD_version. cheers luigi To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-arch" in the body of the message