From: Laszlo Valko <valko@linux.karinthy.hu>
To: Harald Welte <laforge@gnumonks.org>
Cc: Don Cohen <don-netf@isis.cs3-inc.com>,
netfilter-devel@lists.netfilter.org
Subject: Re: iptables u32 match patch-o-matic (attempt)
Date: Sat, 1 Feb 2003 01:23:05 +0100 [thread overview]
Message-ID: <20030201012305.B27624@linux.karinthy.hu> (raw)
In-Reply-To: <20030131101645.GC9073@naboo.cybercafe42>; from laforge@gnumonks.org on Fri, Jan 31, 2003 at 11:16:45AM +0100
On Fri, Jan 31, 2003 at 11:16:45AM +0100, Harald Welte wrote:
> On Wed, Jan 29, 2003 at 07:28:57AM -0800, Don Cohen wrote:
> I also disagree with Laszlo. We don't need cross-architecture
> compatibility of those structures anyway.
>
> > > > +struct ipt_u32_test
> > > > +{
> > > > + u_int8_t nnums;
> > > > + struct ipt_u32_location_element location[U32MAXSIZE+1];
> > > > + u_int8_t nvalues;
> > > > + struct ipt_u32_value_element value[U32MAXSIZE+1];
> > > > +};
> >
> > In this one case at least it might help to put the two 8's together,
> > right?
>
> yes, it should. depending on compiler and archtiecture, though.
Ok, but please understand that gcc will not do any packing on x86 or
any RISC platforms by default. And since this is part of the platform ABI,
the default behaviour is a fairly stable thing.
This boils down to saying that whatever you use (u_int8_t or u_int32_t),
it will not matter, the compiler will generate the same structure for
all major platforms of Linux (x86, alpha, sparc for sure).
Of course, this whole debate is akin to splitting a hair into two... :)
Regards,
Laszlo
> --
> Live long and prosper
> - Harald Welte / laforge@gnumonks.org http://www.gnumonks.org/
> ============================================================================
> GCS/E/IT d- s-: a-- C+++ UL++++$ P+++ L++++$ E--- W- N++ o? K- w--- O- M-
> V-- PS+ PE-- Y+ PGP++ t++ 5-- !X !R tv-- b+++ DI? !D G+ e* h+ r% y+(*)
next prev parent reply other threads:[~2003-02-01 0:23 UTC|newest]
Thread overview: 10+ messages / expand[flat|nested] mbox.gz Atom feed top
[not found] <20030128234654.29362.28104.Mailman@kashyyyk>
2003-01-29 4:18 ` iptables u32 match patch-o-matic (attempt) Don Cohen
2003-01-29 8:09 ` Laszlo Valko
2003-01-29 15:28 ` Don Cohen
2003-01-31 10:16 ` Harald Welte
2003-02-01 0:23 ` Laszlo Valko [this message]
2003-01-31 10:19 ` Harald Welte
2002-12-27 18:54 iptables u32 match code for review/testing/ Don Cohen
2003-01-06 12:57 ` Harald Welte
2003-01-06 17:04 ` Don Cohen
2003-01-07 18:57 ` Harald Welte
2003-01-08 6:41 ` Don Cohen
2003-01-08 10:56 ` Harald Welte
2003-01-08 22:10 ` iptables u32 match patch-o-matic (attempt) Don Cohen
2003-01-11 19:47 ` Harald Welte
2003-01-12 21:11 ` Don Cohen
2003-01-25 18:39 ` Harald Welte
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20030201012305.B27624@linux.karinthy.hu \
--to=valko@linux.karinthy.hu \
--cc=don-netf@isis.cs3-inc.com \
--cc=laforge@gnumonks.org \
--cc=netfilter-devel@lists.netfilter.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.