From owner-freebsd-alpha  Thu Aug  2 17: 6:44 2001
Delivered-To: freebsd-alpha@freebsd.org
Received: from InterJet.elischer.org (c421509-a.pinol1.sfba.home.com [24.7.86.9])
	by hub.freebsd.org (Postfix) with ESMTP
	id 21D5337B401; Thu,  2 Aug 2001 17:06:39 -0700 (PDT)
	(envelope-from julian@elischer.org)
Received: from localhost (localhost.elischer.org [127.0.0.1])
	by InterJet.elischer.org (8.9.1a/8.9.1) with ESMTP id TAA48308;
	Thu, 2 Aug 2001 19:11:59 -0700 (PDT)
Date: Thu, 2 Aug 2001 19:11:58 -0700 (PDT)
From: Julian Elischer <julian@elischer.org>
To: Brian Somers <brian@Awfulhak.org>
Cc: Bruce Evans <bde@zeta.org.au>,
	Thomas Pornin <Thomas.Pornin@ens.fr>, freebsd-net@FreeBSD.ORG,
	freebsd-alpha@FreeBSD.ORG, Brian Somers <brian@freebsd-services.com>,
	FreeBSD-gnats-submit@FreeBSD.ORG,
	Brian Somers <brian@freebsd-services.com>
Subject: Re: kern/27767: (was: PPPoE + Alpha + 32/64 bits) 
In-Reply-To: <200108022338.f72Nc6u09427@hak.lan.Awfulhak.org>
Message-ID: <Pine.BSF.4.21.0108021907190.41008-100000@InterJet.elischer.org>
MIME-Version: 1.0
Content-Type: TEXT/PLAIN; charset=US-ASCII
Sender: owner-freebsd-alpha@FreeBSD.ORG
Precedence: bulk
List-ID: <freebsd-alpha.FreeBSD.ORG>
List-Archive: <http://docs.freebsd.org/mail/> (Web Archive)
List-Help: <mailto:majordomo@FreeBSD.ORG?subject=help> (List Instructions)
List-Subscribe: <mailto:majordomo@FreeBSD.ORG?subject=subscribe%20freebsd-alpha>
List-Unsubscribe: <mailto:majordomo@FreeBSD.ORG?subject=unsubscribe%20freebsd-alpha>
X-Loop: FreeBSD.org


On Fri, 3 Aug 2001, Brian Somers wrote:

> 
> That's probably better.  I went with the __attribute((packed)) stuff 
> because it was already done that way in the rest of the code.
> 
> In this specific case however, it may be best to just send the variable 
> plus the alignment padding as the tag:
> 
>         struct {
>                 struct pppoe_tag hdr;
>                 union   uniq    data;
>         } uniqtag;
> 
>         ......
>         uniqtag.hdr.tag_type = PTT_HOST_UNIQ;
>         uniqtag.hdr.tag_len = htons((u_int16_t)(sizeof(uniqtag) - sizeof(uniqtag.hdr));
>         uniqtag.data.pointer = sp;


urk

I prefer bruce's method :-) but if the rest use
packed.. we can probably use it here to be consistant..




To Unsubscribe: send mail to majordomo@FreeBSD.org
with "unsubscribe freebsd-alpha" in the body of the message