2014-08-28 03:51, Wu, Jingjing:
> From: Thomas Monjalon [mailto:thomas.monjalon at 6wind.com]
> > 2014-08-27 10:13, Jingjing Wu:
> > > add structure definition to construct programming packet.
> > 
> > What is a "programming packet"?
> 
> For Fortville, we need to set a flow director filter by sending a
> packet which contains the input set values through the queue
> belonging to flow director.

OK. To be more clear, some detailed explanations are required in the
commit log. Please try to be very descriptive.
You can think comments like this:
- if comments are absolutely needed to understand the code, you should
put comments in the code (or write the code differently)
- if some feature context can help for the review, you should explain
context and design in the commit log

> > > +#ifdef RTE_LIBRTE_I40E_PMD
> > > +                 "i40e_flow_director_filter (port_id) (add|del)"
> > > +                 " flow (ip4|ip6) src (src_ip_address) dst 
> > > (dst_ip_address)"
> > > +                 " flexwords (flexwords_value) (drop|fwd)"
> > > +                 " queue (queue_id) fd_id (fd_id_value)\n"
> > > +                 "    Add/Del a IP type flow director filter for i40e 
> > > NIC.\n\n"
> > > +
> > > +                 "i40e_flow_director_filter (port_id) (add|del)"
> > > +                 " flow (udp4|tcp4|udp6|tcp6)"
> > > +                 " src (src_ip_address) (src_port)"
> > > +                 " dst (dst_ip_address) (dst_port)"
> > > +                 " flexwords (flexwords_value) (drop|fwd)"
> > > +                 " queue (queue_id) fd_id (fd_id_value)\n"
> > > +                 "    Add/Del a UDP/TCP type flow director filter for 
> > > i40e NIC.\n\n"
> > > +
> > > +                 "i40e_flush_flow_diretor (port_id)\n"
> > > +                 "    Flush all flow director entries of a device on 
> > > i40e NIC.\n\n"
> > > +#endif /* RTE_LIBRTE_I40E_PMD */
> > 
> > I'd really like to stop seeing this kind of thing.
> > We cannot add some ifdef for each PMD in generic code.
> > 
> > I stopped reading after that.
> > 
> > Sorry, I don't want to be rude but my feeling is that adding such feature
> > with global picture in mind is not easy. I know you want to offer all i40e
> > capabilities but you should think at future evolutions and how other drivers
> > will be integrated with yours.
> > 
> 
> Sorry to make you feel uncomfortable for such code. Just as you say,
> I want to offer more i40e capabilities. I will rework code in testpmd. 

Thanks
-- 
Thomas

Reply via email to