On 06/26/2012 12:40 AM, Christoph Hellwig wrote:
> On Mon, Jun 25, 2012 at 10:31:50PM +0800, Liu Yuan wrote:
>> From: Liu Yuan <[email protected]>
>>
>> - remove vnode_node_cmp(), node_cmp()
> 
> I would prefer to keem them as wrappers using container_of to get at
> struct node_id - thay way type safety for the case of struct node_id
> moving around in the structs is kept instead of assuming they are
> the first member.
> 
> The reminder of that patch probably should be folded into the previous
> one.
> 

I don't think so. Both for vnode_node_cmp and node_cmp, the only caller
are bsearch and lfind, which need a prototype of int (*compar)(const
void *, const void *). It is meaningless to add a wrapper at least for
now. I also think folding doesn't make sense, this patch need a separate
one for better review.

Thanks,
Yuan

-- 
sheepdog mailing list
[email protected]
http://lists.wpkg.org/mailman/listinfo/sheepdog

Reply via email to