qstr: constify instances in autofs4
authorAl Viro <viro@zeniv.linux.org.uk>
Wed, 20 Jul 2016 20:25:07 +0000 (16:25 -0400)
committerAl Viro <viro@zeniv.linux.org.uk>
Thu, 21 Jul 2016 03:30:06 +0000 (23:30 -0400)
Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
fs/autofs4/root.c
fs/autofs4/waitq.c

index 3767f66..fa84bb8 100644 (file)
@@ -159,7 +159,7 @@ static struct dentry *autofs4_lookup_active(struct dentry *dentry)
 {
        struct autofs_sb_info *sbi = autofs4_sbi(dentry->d_sb);
        struct dentry *parent = dentry->d_parent;
-       struct qstr *name = &dentry->d_name;
+       const struct qstr *name = &dentry->d_name;
        unsigned int len = name->len;
        unsigned int hash = name->hash;
        const unsigned char *str = name->name;
@@ -172,7 +172,7 @@ static struct dentry *autofs4_lookup_active(struct dentry *dentry)
        list_for_each(p, head) {
                struct autofs_info *ino;
                struct dentry *active;
-               struct qstr *qstr;
+               const struct qstr *qstr;
 
                ino = list_entry(p, struct autofs_info, active);
                active = ino->dentry;
@@ -214,7 +214,7 @@ static struct dentry *autofs4_lookup_expiring(struct dentry *dentry,
 {
        struct autofs_sb_info *sbi = autofs4_sbi(dentry->d_sb);
        struct dentry *parent = dentry->d_parent;
-       struct qstr *name = &dentry->d_name;
+       const struct qstr *name = &dentry->d_name;
        unsigned int len = name->len;
        unsigned int hash = name->hash;
        const unsigned char *str = name->name;
@@ -227,7 +227,7 @@ static struct dentry *autofs4_lookup_expiring(struct dentry *dentry,
        list_for_each(p, head) {
                struct autofs_info *ino;
                struct dentry *expiring;
-               struct qstr *qstr;
+               const struct qstr *qstr;
 
                if (rcu_walk) {
                        spin_unlock(&sbi->lookup_lock);
index 631f155..432b0d5 100644 (file)
@@ -225,7 +225,7 @@ rename_retry:
 }
 
 static struct autofs_wait_queue *
-autofs4_find_wait(struct autofs_sb_info *sbi, struct qstr *qstr)
+autofs4_find_wait(struct autofs_sb_info *sbi, const struct qstr *qstr)
 {
        struct autofs_wait_queue *wq;
 
@@ -249,7 +249,7 @@ autofs4_find_wait(struct autofs_sb_info *sbi, struct qstr *qstr)
  */
 static int validate_request(struct autofs_wait_queue **wait,
                            struct autofs_sb_info *sbi,
-                           struct qstr *qstr,
+                           const struct qstr *qstr,
                            struct dentry *dentry, enum autofs_notify notify)
 {
        struct autofs_wait_queue *wq;