All of lore.kernel.org
 help / color / mirror / Atom feed
From: Shrijeet Mukherjee <shm@cumulusnetworks.com>
To: Hannes Frederic Sowa <hannes@stressinduktion.org>,
	Scott Feldman <sfeldma@gmail.com>
Cc: Netdev <netdev@vger.kernel.org>, "Jiří Pírko" <jiri@resnulli.us>,
	"john fastabend" <john.fastabend@gmail.com>,
	"Thomas Graf" <tgraf@suug.ch>,
	"Jamal Hadi Salim" <jhs@mojatatu.com>,
	"Andy Gospodarek" <andy@greyhouse.net>,
	"Roopa Prabhu" <roopa@cumulusnetworks.com>
Subject: RE: [PATCH net-next 1/3] net: add IPv4 routing FIB support for swdev
Date: Tue, 6 Jan 2015 18:08:10 -0800	[thread overview]
Message-ID: <98433f41e1876041471cdb513ca53fe5@mail.gmail.com> (raw)
In-Reply-To: <1420574353.15181.19.camel@stressinduktion.org>

>For the first idea, I'll try to make an example:
>
>Initial setup:
># ip rule ls
>0:	from all lookup local
>32766:	from all lookup main
>32767:	from all lookup default
>
># ip rule add pref 100 iif swdev0 table 5 # ip rule ls
>0:	from all lookup local
>100:	from all iif swdev0 [detached] lookup 5
>> maybe we can show which rules are being able to get offloaded here
>32766:	from all lookup main
>32767:	from all lookup default
>
>table 5 should be the table we can insert routes into which are offloaded
>to
>hardware.
>
>During table modifications we linearly scan the rules if we find selectors
>which
>cannot be represented by hardware.
>
>In case we have a iif selector, we simply can use this table and just
>synthesize it
>into the particular interface.
>
>A ip-rule-from would need all the hardware being capable of matching source
>addresses, otherwise we cannot offload all routing tables with higher
>preference,
>same for a to/tos rule. If we encounter a fwmark rule, we certainly cannot
>represent it in hardware, so skip it (here we can think about entangling
>those with
>ACLs, but it feels hard to do).
>
>If rules are inserted or changed we must again validate the complete list
>of rules
>and decide if we need to flush all the routes and install a slow path via
>kernel.
>
>What do you think? Does that make sense? I could try to come up with an API
>for
>that. ;)
>

This sounds really good, but I suspect the real problem is the case where
the rule evaluation is in the hardware path right. If it is purely IF based
there is no issue .. but any other policy like missed in table 1, then use
table 2 will not work with this model .. or did I miss something ?

  parent reply	other threads:[~2015-01-07  2:08 UTC|newest]

Thread overview: 17+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2015-01-02  3:29 [PATCH net-next 1/3] net: add IPv4 routing FIB support for swdev sfeldma
2015-01-02  5:49 ` roopa
2015-01-02  8:00   ` Scott Feldman
2015-01-02 11:39     ` Arad, Ronen
2015-01-02 17:20       ` Scott Feldman
2015-01-02 22:57       ` roopa
2015-01-02 20:55     ` roopa
2015-01-02 11:21   ` Arad, Ronen
2015-01-02 21:53     ` roopa
2015-01-06 13:58 ` Hannes Frederic Sowa
2015-01-06 17:51   ` Scott Feldman
2015-01-06 19:59     ` Hannes Frederic Sowa
2015-01-06 20:26       ` Hannes Frederic Sowa
2015-01-07  2:08       ` Shrijeet Mukherjee [this message]
2015-01-07 11:23         ` Hannes Frederic Sowa
2015-01-07 17:54           ` Shrijeet Mukherjee
2015-01-08 13:03             ` Hannes Frederic Sowa

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=98433f41e1876041471cdb513ca53fe5@mail.gmail.com \
    --to=shm@cumulusnetworks.com \
    --cc=andy@greyhouse.net \
    --cc=hannes@stressinduktion.org \
    --cc=jhs@mojatatu.com \
    --cc=jiri@resnulli.us \
    --cc=john.fastabend@gmail.com \
    --cc=netdev@vger.kernel.org \
    --cc=roopa@cumulusnetworks.com \
    --cc=sfeldma@gmail.com \
    --cc=tgraf@suug.ch \
    /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.