1. 07 Dec, 2006 1 commit
  2. 22 Nov, 2006 1 commit
  3. 03 Oct, 2006 8 commits
  4. 30 Jun, 2006 1 commit
  5. 26 Jun, 2006 2 commits
  6. 27 Mar, 2006 5 commits
    • Alasdair G Kergon's avatar
      [PATCH] dm snapshot: fix kcopyd destructor · 138728dc
      Alasdair G Kergon authored
      
      
      Before removing a snapshot, wait for the completion of any kcopyd jobs using
      it.
      
      Do this by maintaining a count (nr_jobs) of how many outstanding jobs each
      kcopyd_client has.
      
      The snapshot destructor first unregisters the snapshot so that no new kcopyd
      jobs (created by writes to the origin) will reference that particular
      snapshot.  kcopyd_client_destroy() is now run next to wait for the completion
      of any outstanding jobs before the snapshot exception structures (that those
      jobs reference) are freed.
      Signed-off-by: default avatarAlasdair G Kergon <agk@redhat.com>
      Signed-off-by: default avatarAndrew Morton <akpm@osdl.org>
      Signed-off-by: default avatarLinus Torvalds <torvalds@osdl.org>
      138728dc
    • Andrew Morton's avatar
      [PATCH] dm: remove SECTOR_FORMAT · 4ee218cd
      Andrew Morton authored
      
      
      We don't know what type sector_t has.  Sometimes it's unsigned long, sometimes
      it's unsigned long long.  For example on ppc64 it's unsigned long with
      CONFIG_LBD=n and on x86_64 it's unsigned long long with CONFIG_LBD=n.
      
      The way to handle all of this is to always use unsigned long long and to
      always typecast the sector_t when printing it.
      Acked-by: default avatarAlasdair G Kergon <agk@redhat.com>
      Signed-off-by: default avatarAndrew Morton <akpm@osdl.org>
      Signed-off-by: default avatarLinus Torvalds <torvalds@osdl.org>
      4ee218cd
    • Alasdair G Kergon's avatar
      [PATCH] device-mapper snapshot: fix invalidation · 76df1c65
      Alasdair G Kergon authored
      
      
      When a snapshot becomes invalid, s->valid is set to 0.  In this state, a
      snapshot can no longer be accessed.
      
      When s->lock is acquired, before doing anything else, s->valid must be checked
      to ensure the snapshot remains valid.
      
      This patch eliminates some races (that may cause panics) by adding some
      missing checks.  At the same time, some unnecessary levels of indentation are
      removed and snapshot invalidation is moved into a single function that always
      generates a device-mapper event.
      Signed-off-by: default avatarAlasdair G Kergon <agk@redhat.com>
      Signed-off-by: default avatarAndrew Morton <akpm@osdl.org>
      Signed-off-by: default avatarLinus Torvalds <torvalds@osdl.org>
      76df1c65
    • Alasdair G Kergon's avatar
      [PATCH] device-mapper snapshot: replace sibling list · b4b610f6
      Alasdair G Kergon authored
      
      
      The siblings "list" is used unsafely at the moment.
      
      Firstly, only the element on the list being changed gets locked (via the
      snapshot lock), not the next and previous elements which have pointers that
      are also being changed.
      
      Secondly, if you have two or more snapshots and write to the same chunk a
      second time before every snapshot has finished making its private copy of the
      data, if you're unlucky, _origin_write() could attempt its list_merge() and
      dereference a 'last' pointer to a pending_exception structure that has just
      been freed.
      
      Analysis reveals that the list is actually only there for reference counting.
      If 5 pending_exceptions are needed in origin_write, then the 5 are joined
      together into a 5-element list - without a separate list head because there's
      nowhere suitable to store it.  As the pending_exceptions complete, they are
      removed from the list one-by-one and any contents of origin_bios get moved
      across to one of the remaining pending_exceptions on the list.  Whichever one
      is last is detected because list_empty() is then true and the origin_bios get
      submitted.
      
      The fix proposed here uses an alternative reference counting mechanism by
      choosing one of the pending_exceptions as primary and maintaining an atomic
      counter there.
      Signed-off-by: default avatarAlasdair G Kergon <agk@redhat.com>
      Signed-off-by: default avatarAndrew Morton <akpm@osdl.org>
      Signed-off-by: default avatarLinus Torvalds <torvalds@osdl.org>
      b4b610f6
    • Alasdair G Kergon's avatar
      [PATCH] device-mapper snapshot: fix origin_write pending_exception submission · eccf0817
      Alasdair G Kergon authored
      
      
      Say you have several snapshots of the same origin and then you issue a write
      to some place in the origin for the first time.
      
      Before the device-mapper snapshot target lets the write go through to the
      underlying device, it needs to make a copy of the data that is about to be
      overwritten.  Each snapshot is independent, so it makes one copy for each
      snapshot.
      
      __origin_write() loops through each snapshot and checks to see whether a copy
      is needed for that snapshot.  (A copy is only needed the first time that data
      changes.)
      
      If a copy is needed, the code allocates a 'pending_exception' structure
      holding the details.  It links these together for all the snapshots, then
      works its way through this list and submits the copying requests to the kcopyd
      thread by calling start_copy().  When each request is completed, the original
      pending_exception structure gets freed in pending_complete().
      
      If you're very unlucky, this structure can get freed *before* the submission
      process has finished walking the list.
      
      This patch:
      
        1) Creates a new temporary list pe_queue to hold the pending exception
           structures;
      
        2) Does all the bookkeeping up-front, then walks through the new list
           safely and calls start_copy() for each pending_exception that needed it;
      
        3) Avoids attempting to add pe->siblings to the list if it's already
           connected.
      
      [NB This does not fix all the races in this code.  More patches will follow.]
      Signed-off-by: default avatarAlasdair G Kergon <agk@redhat.com>
      Signed-off-by: default avatarAndrew Morton <akpm@osdl.org>
      Signed-off-by: default avatarLinus Torvalds <torvalds@osdl.org>
      eccf0817
  7. 26 Mar, 2006 1 commit
  8. 01 Feb, 2006 2 commits
  9. 15 Jan, 2006 1 commit
  10. 06 Jan, 2006 1 commit
  11. 12 Jul, 2005 2 commits
  12. 16 Apr, 2005 1 commit
    • Linus Torvalds's avatar
      Linux-2.6.12-rc2 · 1da177e4
      Linus Torvalds authored
      Initial git repository build. I'm not bothering with the full history,
      even though we have it. We can create a separate "historical" git
      archive of that later if we want to, and in the meantime it's about
      3.2GB when imported into git - space that would just make the early
      git days unnecessarily complicated, when we don't have a lot of good
      infrastructure for it.
      
      Let it rip!
      1da177e4