Date: Mon, 2 May 2005 19:56:49 -0500 (CDT) From: Mike Silbersack <silby@silby.com> To: Sten Spans <sten@blinkenlights.nl> Cc: jmg@FreeBSD.org Subject: Re: if_tap unaligned access problem Message-ID: <20050502194640.Q3199@odysseus.silby.com> In-Reply-To: <Pine.SOC.4.61.0505030116500.709@tea.blinkenlights.nl> References: <20050428135120.GB21428@cell.sick.ru> <427111BF.2050607@savvis.net><20050502180353.T787@odysseus.silby.com> <Pine.SOC.4.61.0505030116500.709@tea.blinkenlights.nl>
next in thread | previous in thread | raw e-mail | index | archive | help
On Tue, 3 May 2005, Sten Spans wrote: > For the if_tap case fixing the driver ( or rather changing m_uiotombuf ) > is definately the correct solution. No sensible person would say otherwise. > Once the if_tap change is properly tested and signed off it should > make it into the tree. Yes, that makes sense. > But on the proposed alignment changes: > > If you would look at the netbsd url ( > http://mail-index.netbsd.org/source-changes/2002/07/01/0001.html ) As I said above, just leave the IP stack alone and put the (conditional on non-i386) code around line 731 of if_ethersubr.c: /* If the CRC is still on the packet, trim it off. */ if (m->m_flags & M_HASFCS) { m_adj(m, -ETHER_CRC_LEN); m->m_flags &= ~M_HASFCS; } <-- here switch (ether_type) { #ifdef INET case ETHERTYPE_IP: Then you cover all the protocols at once. Mike "Silby" Silbersack
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?20050502194640.Q3199>