All of lore.kernel.org
 help / color / mirror / Atom feed
From: Pablo Neira Ayuso <pablo@netfilter.org>
To: Kristian Evensen <kristian.evensen@gmail.com>
Cc: netfilter-devel@vger.kernel.org
Subject: Re: [PATCH netfilter: nft] add connmark module
Date: Mon, 6 Jan 2014 13:49:44 +0100	[thread overview]
Message-ID: <20140106124944.GA7830@localhost> (raw)
In-Reply-To: <CAKfDRXisUL5yBbU3bZfo52GxU96BamC75vPWsFvOYg7u8Jhs1w@mail.gmail.com>

On Mon, Jan 06, 2014 at 01:46:08PM +0100, Kristian Evensen wrote:
> Hi,
> 
> Thanks. I noticed the addition of the get/set operation while working
> on the patch and was unsure about how to deal with setting the
> connmark, but I decided to add it for completeness sake. Perhaps a
> better idea would be to remove set from the module and only keep
> save/restore? It would simplify the code as well.

I think one single NFT_META_CONNMARK with the get/set variants should
be enough to implement the save, restore and set operations that
xt_connmark provides.

* restore:
        reg1 = get(NFT_META_CONNMARK)
        set(NFT_META_MARK, reg1)

* save:
        reg1 = get(NFT_META_MARK)
        set(NFT_META_CONNMARK, reg1)

* set:
        reg1 = immediate(value)
        set(NFT_META_CONNMARK, reg1)

  reply	other threads:[~2014-01-06 12:49 UTC|newest]

Thread overview: 9+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2014-01-06 12:29 [PATCH netfilter: nft] add connmark module Kristian Evensen
2014-01-06 12:42 ` Pablo Neira Ayuso
2014-01-06 12:46   ` Kristian Evensen
2014-01-06 12:49     ` Pablo Neira Ayuso [this message]
2014-01-06 13:02       ` Kristian Evensen
2014-01-06 13:09         ` Pablo Neira Ayuso
2014-01-06 13:11           ` Kristian Evensen
2014-01-06 15:19       ` Kristian Evensen
2014-01-06 16:05         ` Kristian Evensen

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=20140106124944.GA7830@localhost \
    --to=pablo@netfilter.org \
    --cc=kristian.evensen@gmail.com \
    --cc=netfilter-devel@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 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.