Date: Tue, 3 May 2005 09:07:30 +0200 (CEST) From: Sten Spans <sten@blinkenlights.nl> To: Mike Silbersack <silby@silby.com> Cc: jmg@FreeBSD.org Subject: Re: if_tap unaligned access problem Message-ID: <Pine.SOC.4.61.0505030906080.6452@tea.blinkenlights.nl> In-Reply-To: <20050502194640.Q3199@odysseus.silby.com> References: <20050428135120.GB21428@cell.sick.ru> <427111BF.2050607@savvis.net><20050502180353.T787@odysseus.silby.com> <Pine.SOC.4.61.0505030116500.709@tea.blinkenlights.nl> <20050502194640.Q3199@odysseus.silby.com>
next in thread | previous in thread | raw e-mail | index | archive | help
On Mon, 2 May 2005, Mike Silbersack wrote: > > 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. Well it's pretty hard to only align the l3 protocol header in the ethernet code ... -- Sten Spans "There is a crack in everything, that's how the light gets in." Leonard Cohen - Anthem
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?Pine.SOC.4.61.0505030906080.6452>