]> Gitweb @ Texas Instruments - Open Source Git Repositories - git.TI.com/gitweb - android-sdk/kernel-video.git/commitdiff
Merge tag 'dm-3.8-fixes' of git://git.kernel.org/pub/scm/linux/kernel/git/agk/linux-dm
authorLinus Torvalds <torvalds@linux-foundation.org>
Sat, 22 Dec 2012 01:08:06 +0000 (17:08 -0800)
committerLinus Torvalds <torvalds@linux-foundation.org>
Sat, 22 Dec 2012 01:08:06 +0000 (17:08 -0800)
Pull dm update from Alasdair G Kergon:
 "Miscellaneous device-mapper fixes, cleanups and performance
  improvements.

  Of particular note:
   - Disable broken WRITE SAME support in all targets except linear and
     striped.  Use it when kcopyd is zeroing blocks.
   - Remove several mempools from targets by moving the data into the
     bio's new front_pad area(which dm calls 'per_bio_data').
   - Fix a race in thin provisioning if discards are misused.
   - Prevent userspace from interfering with the ioctl parameters and
     use kmalloc for the data buffer if it's small instead of vmalloc.
   - Throttle some annoying error messages when I/O fails."

* tag 'dm-3.8-fixes' of git://git.kernel.org/pub/scm/linux/kernel/git/agk/linux-dm: (36 commits)
  dm stripe: add WRITE SAME support
  dm: remove map_info
  dm snapshot: do not use map_context
  dm thin: dont use map_context
  dm raid1: dont use map_context
  dm flakey: dont use map_context
  dm raid1: rename read_record to bio_record
  dm: move target request nr to dm_target_io
  dm snapshot: use per_bio_data
  dm verity: use per_bio_data
  dm raid1: use per_bio_data
  dm: introduce per_bio_data
  dm kcopyd: add WRITE SAME support to dm_kcopyd_zero
  dm linear: add WRITE SAME support
  dm: add WRITE SAME support
  dm: prepare to support WRITE SAME
  dm ioctl: use kmalloc if possible
  dm ioctl: remove PF_MEMALLOC
  dm persistent data: improve improve space map block alloc failure message
  dm thin: use DMERR_LIMIT for errors
  ...

1  2 
drivers/md/persistent-data/dm-block-manager.c

index a3ae09124a67f786c19f1e426c12ca77a06c3963,ec4cb3c58a0cfec8724d918c1c9bade69a9e1c61..28c3ed072a7943752e90446a1a110776c2928fec
@@@ -25,7 -25,7 +25,7 @@@
   * may be held at once.  This is just an implementation detail.
   *
   * ii) Recursive locking attempts are detected and return EINVAL.  A stack
 - * trace is also emitted for the previous lock aquisition.
 + * trace is also emitted for the previous lock acquisition.
   *
   * iii) Priority is given to write locks.
   */
@@@ -109,7 -109,7 +109,7 @@@ static int __check_holder(struct block_
                        DMERR("previously held here:");
                        print_stack_trace(lock->traces + i, 4);
  
 -                      DMERR("subsequent aquisition attempted here:");
 +                      DMERR("subsequent acquisition attempted here:");
                        t.nr_entries = 0;
                        t.max_entries = MAX_STACK;
                        t.entries = entries;
@@@ -428,15 -428,17 +428,17 @@@ static int dm_bm_validate_buffer(struc
                if (!v)
                        return 0;
                r = v->check(v, (struct dm_block *) buf, dm_bufio_get_block_size(bm->bufio));
-               if (unlikely(r))
+               if (unlikely(r)) {
+                       DMERR_LIMIT("%s validator check failed for block %llu", v->name,
+                                   (unsigned long long) dm_bufio_get_block_number(buf));
                        return r;
+               }
                aux->validator = v;
        } else {
                if (unlikely(aux->validator != v)) {
-                       DMERR("validator mismatch (old=%s vs new=%s) for block %llu",
-                               aux->validator->name, v ? v->name : "NULL",
-                               (unsigned long long)
-                                       dm_bufio_get_block_number(buf));
+                       DMERR_LIMIT("validator mismatch (old=%s vs new=%s) for block %llu",
+                                   aux->validator->name, v ? v->name : "NULL",
+                                   (unsigned long long) dm_bufio_get_block_number(buf));
                        return -EINVAL;
                }
        }