Revision 29:
  Add an endio method to targets.

Revision 30:
  import dm-iostats.c

Revision 31:
  Update Config.in and Makefile to get dm-iostats building.

Revision 32:
  Typedef a suitable jiffies_t rather than using typeof everywhere.

Revision 33:
  Rename variables that have the word 'jiffies' in them.  No hungarian
  please.

Revision 34:
  Get rid of global _io_lock spinlock.

Revision 35:
  Fluff

Revision 36:
  Fluff

Revision 37:
  Fluff

Revision 38:
  We can't have 2 target types in the same module without breaking the
  automatic loading of target modules.  eg, if 'iostat_avg' is requested
  and not registered the kernel will try and load a module called
  'dm-iostat_avg'.
  
  So this changes the code back to a single target, with an extra
  parameter which states whether we want latency info or not.

Revision 39:
  Changes ic->reads and ic->writes to be atomic_t.

Revision 40:
  Change the target->end_io function to take the rw param.
  
  Use target->end_io rather than hooking in dm-iostats.c
  
  Instead of taking the average of the individual io latencies calculate
  the 'average end_io time' - 'average start time'.  This removes the need
  for passing context (ie. start time) between the map function and the
  end_io function.

Revision 41:
  No longer any need for jiffies_t
  
  target->end_io was only being called when there were zero pending ios.
  
  ti->private wasn't being set.