[PATCH RT] staging/pohmelfs: convert struct fs->lock usage to seq_spin_{,un}lock

From: Uwe Kleine-KÃnig
Date: Sun Mar 11 2012 - 12:23:22 EST


This fixes:

drivers/staging/pohmelfs/path_entry.c:47:2: warning: passing argument 1 of ârt_spin_lockâ from incompatible pointer type [enabled by default]
include/linux/spinlock_rt.h:19:56: note: expected âstruct spinlock_t *â but argument is of type âstruct seqlock_t *â
drivers/staging/pohmelfs/path_entry.c:49:2: warning: passing argument 1 of ârt_spin_unlockâ from incompatible pointer type [enabled by default]
include/linux/spinlock_rt.h:22:56: note: expected âstruct spinlock_t *â but argument is of type âstruct seqlock_t *â
drivers/staging/pohmelfs/path_entry.c:95:2: warning: passing argument 1 of ârt_spin_lockâ from incompatible pointer type [enabled by default]
include/linux/spinlock_rt.h:19:56: note: expected âstruct spinlock_t *â but argument is of type âstruct seqlock_t *â
drivers/staging/pohmelfs/path_entry.c:97:2: warning: passing argument 1 of ârt_spin_unlockâ from incompatible pointer type [enabled by default]
include/linux/spinlock_rt.h:22:56: note: expected âstruct spinlock_t *â but argument is of type âstruct seqlock_t *â

Signed-off-by: Uwe Kleine-KÃnig <u.kleine-koenig@xxxxxxxxxxxxxx>
---
Hello Thomas,

you probably want to squash that into fs-struct-use-seqlock.patch
It's only compile tested.

Best regards
Uwe

drivers/staging/pohmelfs/path_entry.c | 8 ++++----
1 files changed, 4 insertions(+), 4 deletions(-)

diff --git a/drivers/staging/pohmelfs/path_entry.c b/drivers/staging/pohmelfs/path_entry.c
index 400a9fc..fc0c3fe 100644
--- a/drivers/staging/pohmelfs/path_entry.c
+++ b/drivers/staging/pohmelfs/path_entry.c
@@ -44,9 +44,9 @@ int pohmelfs_construct_path_string(struct pohmelfs_inode *pi, void *data, int le
return -ENOENT;
}

- spin_lock(&current->fs->lock);
+ seq_spin_lock(&current->fs->lock);
path.mnt = mntget(current->fs->root.mnt);
- spin_unlock(&current->fs->lock);
+ seq_spin_unlock(&current->fs->lock);

path.dentry = d;

@@ -92,9 +92,9 @@ int pohmelfs_path_length(struct pohmelfs_inode *pi)
return -ENOENT;
}

- spin_lock(&current->fs->lock);
+ seq_spin_lock(&current->fs->lock);
root = dget(current->fs->root.dentry);
- spin_unlock(&current->fs->lock);
+ seq_spin_unlock(&current->fs->lock);

rename_retry:
len = 1; /* Root slash */
--
1.7.9.1

--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/