]> git.baikalelectronics.ru Git - kernel.git/commit
dm cache policy smq: change the mutex to a spinlock
authorJoe Thornber <ejt@redhat.com>
Fri, 26 Jun 2015 12:25:12 +0000 (13:25 +0100)
committerMike Snitzer <snitzer@redhat.com>
Wed, 12 Aug 2015 15:32:19 +0000 (11:32 -0400)
commite8c1484e721d0108f09631925aa83b62dfdfcf94
treec4435cbfd451b46cb7cac41a5be8e763192d7c3b
parent152d25b8fe55109235f76e683f0baca8bec41eda
dm cache policy smq: change the mutex to a spinlock

We no longer sleep in any of the smq functions, so this can become a
spinlock.  Switching from mutex to spinlock improves performance when
the fast cache device is a very low latency device (e.g. NVMe SSD).

The switch to spinlock also allows for removal of the extra tick_lock;
which is no longer needed since the main lock being a spinlock now
fulfills the locking requirements needed by interrupt context.

Signed-off-by: Joe Thornber <ejt@redhat.com>
Signed-off-by: Mike Snitzer <snitzer@redhat.com>
drivers/md/dm-cache-policy-smq.c