staging: lustre: fix lock imbalance
authorJoshua Clayton <stillcompiling@gmail.com>
Sun, 27 Dec 2015 06:47:36 +0000 (22:47 -0800)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Wed, 3 Feb 2016 22:22:53 +0000 (14:22 -0800)
commita4113d61e53c6cd866f1e760648a41ff95c9b9ba
treebf5401dc5460cdce5596825f7ada2e10e0d4f5ee
parentad0d7799382b37e6afa910f27fa342af62d80ded
staging: lustre: fix lock imbalance

nrs_resource_put_safe() might hold a lock one one struct
while operating on the other.
There are 2 levels of structures.
Use nrs_policy_put(), which has locking baked in.

sparse gives the following warning:
drivers/staging/lustre//lustre/ptlrpc/nrs.c:498:39:
warning: context imbalance in 'nrs_resource_put_safe' -
  different lock contexts for basic block

Signed-off-by: Joshua Clayton <stillcompiling@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
drivers/staging/lustre/lustre/ptlrpc/nrs.c
This page took 0.026608 seconds and 5 git commands to generate.