]> asedeno.scripts.mit.edu Git - linux.git/blobdiff - fs/coda/dir.c
ext4: fix race between writepages and enabling EXT4_EXTENTS_FL
[linux.git] / fs / coda / dir.c
index 00876ddadb43021396c9c2f010fa2c4fa2e90cd1..ca40c2556ba6e94ea9a5104afbd8abbbfc814c78 100644 (file)
@@ -23,7 +23,7 @@
 #include <linux/uaccess.h>
 
 #include <linux/coda.h>
-#include <linux/coda_psdev.h>
+#include "coda_psdev.h"
 #include "coda_linux.h"
 #include "coda_cache.h"
 
@@ -47,8 +47,8 @@ static struct dentry *coda_lookup(struct inode *dir, struct dentry *entry, unsig
        int type = 0;
 
        if (length > CODA_MAXNAMLEN) {
-               pr_err("name too long: lookup, %s (%*s)\n",
-                      coda_i2s(dir), (int)length, name);
+               pr_err("name too long: lookup, %s %zu\n",
+                      coda_i2s(dir), length);
                return ERR_PTR(-ENAMETOOLONG);
        }
 
@@ -356,8 +356,7 @@ static int coda_venus_readdir(struct file *coda_file, struct dir_context *ctx)
        ino_t ino;
        int ret;
 
-       cfi = CODA_FTOC(coda_file);
-       BUG_ON(!cfi || cfi->cfi_magic != CODA_MAGIC);
+       cfi = coda_ftoc(coda_file);
        host_file = cfi->cfi_container;
 
        cii = ITOC(file_inode(coda_file));
@@ -426,8 +425,7 @@ static int coda_readdir(struct file *coda_file, struct dir_context *ctx)
        struct file *host_file;
        int ret;
 
-       cfi = CODA_FTOC(coda_file);
-       BUG_ON(!cfi || cfi->cfi_magic != CODA_MAGIC);
+       cfi = coda_ftoc(coda_file);
        host_file = cfi->cfi_container;
 
        if (host_file->f_op->iterate || host_file->f_op->iterate_shared) {