From owner-freebsd-net Mon Feb 5 13:53:39 2001 Delivered-To: freebsd-net@freebsd.org Received: from iguana.aciri.org (iguana.aciri.org [192.150.187.36]) by hub.freebsd.org (Postfix) with ESMTP id 32F8A37B401; Mon, 5 Feb 2001 13:53:21 -0800 (PST) Received: (from rizzo@localhost) by iguana.aciri.org (8.11.1/8.11.1) id f15LrCH25651; Mon, 5 Feb 2001 13:53:12 -0800 (PST) (envelope-from rizzo) From: Luigi Rizzo Message-Id: <200102052153.f15LrCH25651@iguana.aciri.org> Subject: Re: BRIDGE breaks ARP? (more info) In-Reply-To: <3A7F0806.9B81D98@elischer.org> from Julian Elischer at "Feb 5, 2001 12: 7:34 pm" To: julian@elischer.org (Julian Elischer) Date: Mon, 5 Feb 2001 13:53:12 -0800 (PST) Cc: rizzo@aciri.org, patrick@netzuno.com, freebsd-net@FreeBSD.ORG, richw@webcom.com, julian@FreeBSD.ORG X-Mailer: ELM [version 2.4ME+ PL43 (25)] MIME-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7bit Sender: owner-freebsd-net@FreeBSD.ORG Precedence: bulk X-Loop: FreeBSD.org > [Charset iso-8859-15 unsupported, skipping...] > Luigi.. does this fix it? it looks like it essentially reverts to the old (1.75) behaviour, which means it does not fix bugs, it is only a workaround to let people run kernels with bridging compiled-in as if it was not compiled-in. I think the problem people were (and still will be) having is the following: when bridging is compiled in (and now, when bridging is enabled), arp requests do not consider the interface from which the request cam from. This is ok as long as you have bridging enabled on all of your interfaces, but there are some cases where you are doing bridging separately on clusters of interfaces, and/or no bridging at all on others, and then you need to look only at those interfaces which belong to the same "logical ethernet" as the IF from which you got the packet. This could be a single interface on which bridging is disabled, or interfaces with the same cluster-id in net.link.ether.bridge_cfg. If people wonders what is this "cluster-id" -- that code comes from some unreleased code that i wrote in 2.2.x times which makes FreeBSD work as a VLAN bridge. So the cluster-id is essentially the VLAN-ID, and the special ID 0 corresponds to a "trunk" (where essentially all traffic goes prefixed with the VLAN header). cheers luigi > > > > (void)memcpy(&itaddr, ea->arp_tpa, sizeof (itaddr)); > TAILQ_FOREACH(ia, &in_ifaddrhead, ia_link) { > #ifdef BRIDGE > /* > * For a bridge, we want to check the address irrespective > * of the receive interface. (This will change slightly > * when we have clusters of interfaces). > */ > #define BRIDGE_TEST (do_bridge) > #else > #define BRIDGE_TEST 0 /* cc will optiise the test away */ > #endif > if ((BRIDGE_TEST) || (ia->ia_ifp == &ac->ac_if)) { > maybe_ia = ia; > if ((itaddr.s_addr == ia->ia_addr.sin_addr.s_addr) || > (isaddr.s_addr == ia->ia_addr.sin_addr.s_addr)) { > > To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-net" in the body of the message