[POWERPC] PPC: Use ARRAY_SIZE macro when appropriate
[sfrench/cifs-2.6.git] / mm / filemap.h
index 536979fb4ba717443be39b9e0e8a95dfd012200c..c2bff04c84ed42cfd7b1c85e9819785ae90f6c87 100644 (file)
@@ -12,7 +12,6 @@
 #include <linux/mm.h>
 #include <linux/highmem.h>
 #include <linux/uio.h>
-#include <linux/config.h>
 #include <linux/uaccess.h>
 
 size_t
@@ -88,7 +87,7 @@ filemap_set_next_iovec(const struct iovec **iovp, size_t *basep, size_t bytes)
        const struct iovec *iov = *iovp;
        size_t base = *basep;
 
-       while (bytes) {
+       do {
                int copy = min(bytes, iov->iov_len - base);
 
                bytes -= copy;
@@ -97,7 +96,7 @@ filemap_set_next_iovec(const struct iovec **iovp, size_t *basep, size_t bytes)
                        iov++;
                        base = 0;
                }
-       }
+       } while (bytes);
        *iovp = iov;
        *basep = base;
 }