All of lore.kernel.org
 help / color / mirror / Atom feed
From: Guenter Roeck <linux@roeck-us.net>
To: Florian Fainelli <f.fainelli@gmail.com>
Cc: roopa <roopa@cumulusnetworks.com>,
	sfeldma@gmail.com, netdev@vger.kernel.org, jiri@resnulli.us,
	andrew@lunn.ch, gospo@cumulusnetworks.com, vbandaru@broadcom.com,
	siva.mannem.lnx@gmail.com
Subject: Re: [PATCH net-next RFC 0/5] Add NTF_EXT_AGED to control FDB ageing in SW or HW
Date: Fri, 20 Feb 2015 11:45:51 -0800	[thread overview]
Message-ID: <20150220194551.GA29730@roeck-us.net> (raw)
In-Reply-To: <54E7876A.3060303@gmail.com>

On Fri, Feb 20, 2015 at 11:13:46AM -0800, Florian Fainelli wrote:
> On 20/02/15 09:29, roopa wrote:
> > On 2/19/15, 11:09 PM, sfeldma@gmail.com wrote:
> >> From: Scott Feldman <sfeldma@gmail.com>
> >>
> >> Add a new NTF_EXT_FLAG to mark an FDB as externally aged, for example by
> >> offload hardware.   Switchdev driver/devices can set this flag when
> >> learning a
> >> new FDB entry and SW (the bridge driver) will skip this entry when
> >> running its
> >> ageing task.  If flag is set, the driver/device is responsible for
> >> calling
> >> call_netdev_switch_notifiers(NETDEV_SWITCH_FDB_DEL, ...) when entry
> >> expires.
> >>
> >> This give the flexibility for driver/device to decide ageing policy
> >> based on
> >> its capabilities.  For devices managing many FDB entries, it is
> >> desireable for
> >> the device to aged out its own entries.  Devices not capable of aged
> >> entries
> >> can rely of SW to age out the entries.
> >>
> > scott, patches look good. However, I am not sure yet if there is a need
> > to make it a per fdb entry flag.
> 
> I agree, in fact, most of the HW I have access to only has a global age
> timer configuration knob. Is this configurable on a per-port basis for

Same here (for all the Marvell switches I am aware of). There is only a single
timer with a granularity of 15 seconds (or maybe 16 seconds on some chips).

> higher end switches, or even maybe per-FDB entry?
> 
For the Marvell switches, the only per-fdb entry is a flag to indicate
static vs. dynamic.

> > 
> > At some point we will also need the hw ageing parameter to be configurable.
> > So other approach could be,
> > - ageing parameter on bridge gets offloaded the hw
> > - so, by default hw and kernel age their own entries using the same
> > bridge device default timer
> > - User can explicitly disable HW ageing by using self (this needs some
> > more thought because now the call is on the bridge device)
> 
> I think we want to be careful with both SW and HW aging entries since a
> host CPU's clock might be suspended/drifting etc.. at least, we probably
> want one or the other to take precedence other the other one?

I may be missing something, but I don't immediately see how this patch set
helps me solve any of the problems I am seeing when integrating the Marvell
switch code. Even if the switch internally does hardware aging, it still
seems to me that we'll need software aging on top of that, even if the
bridge code in the kernel has the same addresses in its fdb as the switch.
I see no feasible means to keep the fdb in the switch synchronized
with the fdb in the kernel.

How would this work with Broadcom switch chips ?

Thanks,
Guenter

  reply	other threads:[~2015-02-20 19:45 UTC|newest]

Thread overview: 30+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2015-02-20  7:09 [PATCH net-next RFC 0/5] Add NTF_EXT_AGED to control FDB ageing in SW or HW sfeldma
2015-02-20  7:09 ` [PATCH net-next RFC 1/5] neighbour: add external aged flag sfeldma
2015-02-20  7:09 ` [PATCH net-next RFC 2/5] switchdev: add ntf_flags to FDB notifier sfeldma
2015-02-20  7:09 ` [PATCH net-next RFC 3/5] bridge: call external learn add if adding FDB entry with NTF_EXT_LEARNED set sfeldma
2015-02-20  7:09 ` [PATCH net-next RFC 4/5] bridge: let HW control FDB ageing by setting NTF_EXT_AGED sfeldma
2015-02-20 17:31   ` David Miller
2015-02-20  7:09 ` [PATCH net-next RFC 5/5] rocker: explicitly set SW ageing for rocker sfeldma
2015-02-20  9:46   ` Jiri Pirko
2015-02-20 14:56     ` Scott Feldman
2015-02-20 17:29 ` [PATCH net-next RFC 0/5] Add NTF_EXT_AGED to control FDB ageing in SW or HW roopa
2015-02-20 19:13   ` Florian Fainelli
2015-02-20 19:45     ` Guenter Roeck [this message]
2015-02-21  0:20     ` Viswanath Bandaru
2015-02-21  0:39       ` Guenter Roeck
2015-02-21 18:29       ` roopa
     [not found]         ` <CAE4R7bAPS1GZKaC4M6x9cqfTOkVju1+Po4KzanfSniEFX9oi1w@mail.gmail.com>
2015-02-25 14:31           ` Andrew Lunn
2015-02-25 16:43             ` Guenter Roeck
2015-02-25 17:31               ` B Viswanath
2015-02-25 18:39                 ` Guenter Roeck
2015-02-25 18:51                   ` B Viswanath
2015-02-25 19:15                     ` Guenter Roeck
2015-02-25 19:33                       ` B Viswanath
2015-02-25 20:03                         ` Guenter Roeck
2015-02-25 17:29             ` David Miller
2015-02-21 11:03     ` Jiri Pirko
2015-02-21 11:29       ` Viswanath Bandaru
2015-02-21 15:50         ` Jiri Pirko
2015-02-21 17:20           ` Viswanath Bandaru
2015-02-21 18:31           ` roopa
2015-02-21  1:23 ` Siva Mannem

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=20150220194551.GA29730@roeck-us.net \
    --to=linux@roeck-us.net \
    --cc=andrew@lunn.ch \
    --cc=f.fainelli@gmail.com \
    --cc=gospo@cumulusnetworks.com \
    --cc=jiri@resnulli.us \
    --cc=netdev@vger.kernel.org \
    --cc=roopa@cumulusnetworks.com \
    --cc=sfeldma@gmail.com \
    --cc=siva.mannem.lnx@gmail.com \
    --cc=vbandaru@broadcom.com \
    /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.