diff options
Diffstat (limited to 'drivers/infiniband')
| -rw-r--r-- | drivers/infiniband/hw/ipath/ipath_fs.c | 8 | ||||
| -rw-r--r-- | drivers/infiniband/hw/qib/qib_fs.c | 5 |
2 files changed, 3 insertions, 10 deletions
diff --git a/drivers/infiniband/hw/ipath/ipath_fs.c b/drivers/infiniband/hw/ipath/ipath_fs.c index 8c8afc716b98..31ae1b108aea 100644 --- a/drivers/infiniband/hw/ipath/ipath_fs.c +++ b/drivers/infiniband/hw/ipath/ipath_fs.c | |||
| @@ -277,18 +277,14 @@ static int remove_file(struct dentry *parent, char *name) | |||
| 277 | goto bail; | 277 | goto bail; |
| 278 | } | 278 | } |
| 279 | 279 | ||
| 280 | spin_lock(&dcache_lock); | ||
| 281 | spin_lock(&tmp->d_lock); | 280 | spin_lock(&tmp->d_lock); |
| 282 | if (!(d_unhashed(tmp) && tmp->d_inode)) { | 281 | if (!(d_unhashed(tmp) && tmp->d_inode)) { |
| 283 | dget_locked(tmp); | 282 | dget_dlock(tmp); |
| 284 | __d_drop(tmp); | 283 | __d_drop(tmp); |
| 285 | spin_unlock(&tmp->d_lock); | 284 | spin_unlock(&tmp->d_lock); |
| 286 | spin_unlock(&dcache_lock); | ||
| 287 | simple_unlink(parent->d_inode, tmp); | 285 | simple_unlink(parent->d_inode, tmp); |
| 288 | } else { | 286 | } else |
| 289 | spin_unlock(&tmp->d_lock); | 287 | spin_unlock(&tmp->d_lock); |
| 290 | spin_unlock(&dcache_lock); | ||
| 291 | } | ||
| 292 | 288 | ||
| 293 | ret = 0; | 289 | ret = 0; |
| 294 | bail: | 290 | bail: |
diff --git a/drivers/infiniband/hw/qib/qib_fs.c b/drivers/infiniband/hw/qib/qib_fs.c index f99bddc01716..df7fa251dcdc 100644 --- a/drivers/infiniband/hw/qib/qib_fs.c +++ b/drivers/infiniband/hw/qib/qib_fs.c | |||
| @@ -453,17 +453,14 @@ static int remove_file(struct dentry *parent, char *name) | |||
| 453 | goto bail; | 453 | goto bail; |
| 454 | } | 454 | } |
| 455 | 455 | ||
| 456 | spin_lock(&dcache_lock); | ||
| 457 | spin_lock(&tmp->d_lock); | 456 | spin_lock(&tmp->d_lock); |
| 458 | if (!(d_unhashed(tmp) && tmp->d_inode)) { | 457 | if (!(d_unhashed(tmp) && tmp->d_inode)) { |
| 459 | dget_locked(tmp); | 458 | dget_dlock(tmp); |
| 460 | __d_drop(tmp); | 459 | __d_drop(tmp); |
| 461 | spin_unlock(&tmp->d_lock); | 460 | spin_unlock(&tmp->d_lock); |
| 462 | spin_unlock(&dcache_lock); | ||
| 463 | simple_unlink(parent->d_inode, tmp); | 461 | simple_unlink(parent->d_inode, tmp); |
| 464 | } else { | 462 | } else { |
| 465 | spin_unlock(&tmp->d_lock); | 463 | spin_unlock(&tmp->d_lock); |
| 466 | spin_unlock(&dcache_lock); | ||
| 467 | } | 464 | } |
| 468 | 465 | ||
| 469 | ret = 0; | 466 | ret = 0; |
