Subject: Re: [PATCH net-next v5 18/21] switchdev: convert fib_ipv4_add/del over to switchdev_port_obj_add/del

From: John Fastabend <[email-masked]>
Date: Fri, 08 May 2015 07:19:15 -0700

On 05/07/2015 09:10 AM, Jiri Pirko wrote:
> Tue, May 05, 2015 at 07:34:54PM CEST, [email-masked] wrote:
>> From: Scott Feldman <[email-masked]>
>>
>> The IPv4 FIB ops convert nicely to the switchdev objs and we're left with
>> only four switchdev ops: port get/set and port add/del.  Other objs will
>> follow, such as FDB.  So go ahead and convert IPv4 FIB over to switchdev
>> obj for consistency, anticipating more objs to come.
>>
>> Signed-off-by: Scott Feldman <[email-masked]>
> 
> Acked-by: Jiri Pirko <[email-masked]>

Hi Scott, Jiri,

Now that your converting IPv4 and FDB over to objs this starts to look like
table operations to me. You have add/del/dump operations on them but are
missing the resource piece and how objects are inter-related. I assume in
the end you will have an "obj" for each one of your hardware tables.

At this point I think it might be better to lay this onto the Flow API
I wrote but tighten up the Flow API logic a bit to constrain it. This
patch at least doesn't appear to leak into userspace at all which is good
so there is no problem doing the conversion after this is applied. This
will help I think when Roopa adds the improved failure schemes. Because
at least in some of my use cases I want to have some sense when rules
are going to start failing and how they are interconnected with other
tables before I start working on the switch.

Thanks,
.John

> --
> To unsubscribe from this list: send the line "unsubscribe netdev" in
> the body of a message to [email-masked]
> More majordomo info at  http://vger.kernel.org/majordomo-info.html
>