netdev.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Stephen Hemminger <shemminger@linux-foundation.org>
To: Cyrill Gorcunov <gorcunov@openvz.org>
Cc: kaber@trash.net, bridge@lists.linux-foundation.org,
	netdev@vger.kernel.org, Cyrill Gorcunov <gorcunov@openvz.org>
Subject: Re: [patch 2/2] net, netns_xt: shrink netns_xt members
Date: Thu, 9 Jul 2009 12:55:21 -0700	[thread overview]
Message-ID: <20090709125521.4bacfd47@nehalam> (raw)
In-Reply-To: <20090704062321.034802084@openvz.org>

On Sat, 04 Jul 2009 10:11:58 +0400
Cyrill Gorcunov <gorcunov@openvz.org> wrote:

> In case if kernel was compiled without ebtables support
> there is no need to keep ebt_table pointers in netns_xt
> structure.
> 
> Make it config dependent.
> 
> Signed-off-by: Cyrill Gorcunov <gorcunov@openvz.org>
> ---
> 
> Probably GCC will authomatically shrink the structure
> if the members are not in use. Please review.
> 
>  include/net/netns/x_tables.h |    3 +++
>  1 file changed, 3 insertions(+)
> 
> Index: linux-2.6.git/include/net/netns/x_tables.h
> =====================================================================
> --- linux-2.6.git.orig/include/net/netns/x_tables.h
> +++ linux-2.6.git/include/net/netns/x_tables.h
> @@ -8,8 +8,11 @@ struct ebt_table;
>  
>  struct netns_xt {
>  	struct list_head tables[NFPROTO_NUMPROTO];
> +#if defined(CONFIG_BRIDGE_NF_EBTABLES) || \
> +    defined(CONFIG_BRIDGE_NF_EBTABLES_MODULE)
>  	struct ebt_table *broute_table;
>  	struct ebt_table *frame_filter;
>  	struct ebt_table *frame_nat;
> +#endif
>  };
>  #endif
> 
> --
> To unsubscribe from this list: send the line "unsubscribe netdev" in
> the body of a message to majordomo@vger.kernel.org
> More majordomo info at  http://vger.kernel.org/majordomo-info.html

Acked-by: Stephen Hemminger <shemminger@vyatta.com>

-- 

      reply	other threads:[~2009-07-09 20:41 UTC|newest]

Thread overview: 6+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2009-07-04  6:11 [patch 0/2] a few bridge code cleanups Cyrill Gorcunov
2009-07-04  6:11 ` [patch 1/2] net, bridge: align br_nf_ops assignment Cyrill Gorcunov
2009-07-09 19:55   ` Stephen Hemminger
2009-07-11 14:30     ` Cyrill Gorcunov
2009-07-04  6:11 ` [patch 2/2] net, netns_xt: shrink netns_xt members Cyrill Gorcunov
2009-07-09 19:55   ` Stephen Hemminger [this message]

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=20090709125521.4bacfd47@nehalam \
    --to=shemminger@linux-foundation.org \
    --cc=bridge@lists.linux-foundation.org \
    --cc=gorcunov@openvz.org \
    --cc=kaber@trash.net \
    --cc=netdev@vger.kernel.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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).