Removed lkml from the CC.

On Thu, 2006-06-04 at 10:50 +0200, Patrick McHardy wrote:
> Denis Vlasenko wrote:
> > While hunting down oversized inlines
> > I stumbled on tcf_generic_walker().
> > 
> > It is defined in two separate files:
> > once as an inline in include/net/pkt_act.h
> > (really big one, ~750 bytes of code)
> > and once as a static function in net/sched/act_police.c
> > 
> > These two instances are not identical.
> > Second one has one extra parameter (int type)
> > and it uses it like this:


Good observation on the fact that the two dont differ very much by
functionality. They used to be much different. So it wont harm to
find common base and reduce the code size.
In regards to the naming being the same, iirc this was needed in the
past but is no longer the case. Just send a patch for police.c which
does s/tcf_generic_walker/tcf_act_police_walker/g
While you are at it, send one for
s/tcf_hash_search/tcf_act_police_hash_search/g
On second thought, this is trivial - I am sure i can get it done and do
minimalist testing before i go to work; let me send the patch in a few
minutes with some minimalistic testing. If you want to send an
additional patch on top of the sed job later to merge the two pieces,
please do.

[..]

> > and I fail to understand how it is supposed to work,
> > considering the fact that these two tcf_generic_walker's
> > have different prototypes.
> 

they are the same prototype;->

> What needs to be done is to put a pointer to the hash, its size
> and its lock in struct tc_action_ops and move the "generic"
> functions to a seperate .c file and make them work on a struct
> tcf_act_common.
> 

This is much better than your old proposal Patrick and i have no
problem with it. Why you would need tcf_act_common
if you are going to have those elements in tc_action_ops?
So go ahead and submit the patches or you could pass the token to me and
i will (so we avoid redundancy).

cheers,
jamal

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

Reply via email to