On Tue, Mar 18, 2014 at 01:53:52PM -0700, Pravin wrote:
> new netdev type like DPDK can support multi-queue IO. Following
> patch Adds support for same.
> 
> Signed-off-by: Pravin B Shelar <[email protected]>

Needs comment and documentation updates.

In particular, from reading the code I infer (but I'm not confident)
that now a device that doesn't support receiving packets would now
return an nr_rx of 0, and that the netdev layer doesn't really yet
support devices with more than one queue, since I don't see a way to
get a netdev->nr_rx greater than 1.  Maybe the intent is that the
netdev's class->construct() sets nr_rx if it has more than one queue?
If so then please document that in netdev-provider.h's comment for
construct().

Maybe netdev_rxq_open() should reject calls for which id >=
netdev->nr_rx, so that implementations don't have to (I think that all
the implementations are technically broken as of this commit).

We commonly use an n_ prefix for number in userspace.  I don't think
we have many examples of nr_.

I think that the two iterations through the hmap of ports in
pmd_load_queues() could be just one if we just used a function like
x2nrealloc() to allocate the port_list as we go.  In the end, it's
probably easier to understand to do it that way, and I doubt this code
is time critical.  (I guess that should have been a comment on an
earlier patch, sorry.)

Thanks,

Ben.
_______________________________________________
dev mailing list
[email protected]
http://openvswitch.org/mailman/listinfo/dev

Reply via email to