Pablo Neira Ayuso <[email protected]> writes:

> On Thu, Oct 27, 2016 at 02:27:51PM -0400, Aaron Conole wrote:
>> This allows easier future refactoring.
>> 
>> Signed-off-by: Aaron Conole <[email protected]>
>> ---
>>  include/linux/netfilter.h       | 35 ++++++++++++++++++++++++++++++++++-
>>  net/bridge/br_netfilter_hooks.c |  2 +-
>>  net/netfilter/core.c            |  8 +++-----
>>  net/netfilter/nf_queue.c        |  8 ++++----
>>  4 files changed, 42 insertions(+), 11 deletions(-)

...

> I'd suggest something like:
>
> static inline int
> nf_entry_hookfn(const struct nf_hook_entry *entry,
>                 struct sk_buff *skb, struct nf_hook_state *state)
> {
>         return entry->ops.hook(entry, nf_hook_entry_priv(entry), skb, state);
> }
>
> So you can avoid this:
>
>               verdict = nf_hook_entry_hookfn(*entryp)
>                       (nf_hook_entry_priv(*entryp), skb, state);

Makes sense, I'll do that.  Thanks for the review!
--
To unsubscribe from this list: send the line "unsubscribe netfilter-devel" in
the body of a message to [email protected]
More majordomo info at  http://vger.kernel.org/majordomo-info.html

Reply via email to