mips: kprobes: Use generic kretprobe trampoline handler
[linux-2.6-microblaze.git] / lib / bitmap.c
index 0364452..c13d859 100644 (file)
@@ -212,13 +212,13 @@ void bitmap_cut(unsigned long *dst, const unsigned long *src,
        unsigned long keep = 0, carry;
        int i;
 
-       memmove(dst, src, len * sizeof(*dst));
-
        if (first % BITS_PER_LONG) {
                keep = src[first / BITS_PER_LONG] &
                       (~0UL >> (BITS_PER_LONG - first % BITS_PER_LONG));
        }
 
+       memmove(dst, src, len * sizeof(*dst));
+
        while (cut--) {
                for (i = first / BITS_PER_LONG; i < len; i++) {
                        if (i < len - 1)