[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <4BB9A113.30601@iki.fi>
Date: Mon, 05 Apr 2010 11:36:35 +0300
From: Timo Teräs <timo.teras@....fi>
To: Herbert Xu <herbert@...dor.apana.org.au>
CC: netdev@...r.kernel.org
Subject: Re: [PATCH 1/4] flow: virtualize flow cache entry methods
Herbert Xu wrote:
> On Mon, Apr 05, 2010 at 10:00:21AM +0300, Timo Teras wrote:
>> @@ -219,33 +222,32 @@ void *flow_cache_lookup(struct net *net, struct flowi *key, u16 family, u8 dir,
>> + flo = resolver(net, key, family, dir, fle ? fle->object : NULL, ctx);
>> + if (fle) {
>> + fle->genid = atomic_read(&flow_cache_genid);
>> + if (IS_ERR(flo)) {
>> + fle->genid--;
>> + fle->object = NULL;
>
> Shouldn't we call fle->object->ops->delete here?
The resolver function releases the old object.
It might actually make more sense to pass struct flow_cache_object**
so the resolver can twiddle the flow_cache_entry's object. Then it'd
be more explicit that the resolver is replacing entries.
--
To unsubscribe from this list: send the line "unsubscribe netdev" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Powered by blists - more mailing lists