[Cocci] [Review needed] Ensure that calls to d_find_alias() are followed by dput().

Cyril Roelandt
2012-11-08T20:09:49Z

On 11/08/2012 08:21 AM, Julia Lawall wrote:
> How many cases do you find?
>

Well, only 2 cases (in drivers/iommu/tegra-smmu.c and fs/ceph/export.c).
It's worth noticing that the d_find_alias() function is only called 20
times though, so this seems to be quite a common mistake.

I attached an updated semantic patch, to deal with cases where the
dentry is assigned a new value and dput() has not been called.

WBR,
Cyril Roelandt.
-------------- next part --------------
An embedded and charset-unspecified text was scrubbed...
Name: d_find_alias.cocci
URL: <https://systeme.lip6.fr/pipermail/cocci/attachments/20121108/750882da/attachment.ksh>