Hi John,
Sorry If I'm painting bike-sheds here, just one tiny tweak might be in
order to standardise your mutex_unlock exit path:
[snip]
[snip]
Can this be better expressed like this:
my_func() {
mutex_lock()
..
if(some error) {
rc=-ETIMEDOUT;
goto out_unlock;
}
...
/* success path */
rc=0;
..
out_unlock:
mutex_unlock()
return rc;
}
Is this style still favoured in driver exit paths?
Thanks,
John
--
John Williams, PhD, B.Eng, B.IT
PetaLogix - Linux Solutions for a Reconfigurable World
w: www.petalogix.com p: +61-7-30090663 f: +61-7-30090663
--
To unsubscribe from this list: send the line "unsubscribe netdev" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html