Merge branch 'stable-3.2' into pandora-3.2
[pandora-kernel.git] / fs / file.c
index 30bfc99..8df13b0 100644 (file)
--- a/fs/file.c
+++ b/fs/file.c
@@ -268,6 +268,7 @@ int expand_files(struct files_struct *files, int nr)
        /* All good, so we try */
        return expand_fdtable(files, nr);
 }
+EXPORT_SYMBOL_GPL(expand_files);
 
 static int count_open_files(struct fdtable *fdt)
 {
@@ -366,7 +367,7 @@ struct files_struct *dup_fd(struct files_struct *oldf, int *errorp)
                         * is partway through open().  So make sure that this
                         * fd is available to the new process.
                         */
-                       FD_CLR(open_files - i, new_fdt->open_fds);
+                       __clear_open_fd(open_files - i, new_fdt);
                }
                rcu_assign_pointer(*new_fds++, f);
        }
@@ -460,11 +461,11 @@ repeat:
        if (start <= files->next_fd)
                files->next_fd = fd + 1;
 
-       FD_SET(fd, fdt->open_fds);
+       __set_open_fd(fd, fdt);
        if (flags & O_CLOEXEC)
-               FD_SET(fd, fdt->close_on_exec);
+               __set_close_on_exec(fd, fdt);
        else
-               FD_CLR(fd, fdt->close_on_exec);
+               __clear_close_on_exec(fd, fdt);
        error = fd;
 #if 1
        /* Sanity check */