Re: dm-snapshot: use mutex instead of rw-semaphore

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 




On Fri, 5 Jan 2018, Mike Snitzer wrote:

> On Thu, Nov 23 2017 at  4:15pm -0500,
> Mikulas Patocka <mpatocka@xxxxxxxxxx> wrote:
> 
> > The rw-semaphore is acquired for read only on two places, none of them is
> > performance-critical. So, we can replace it with a mutex.
> 
> Can you expand on why you'd like to avoid using a rw_semaphore?  mutex
> being faster in the fast path?
> 
> Thanks,
> Mike

Mutex code is simpler. Mutex is used more often in the kernel than 
rw-semaphore, so using mutex causes less i-cache pollution.

Mikulas

--
dm-devel mailing list
dm-devel@xxxxxxxxxx
https://www.redhat.com/mailman/listinfo/dm-devel



[Index of Archives]     [DM Crypt]     [Fedora Desktop]     [ATA RAID]     [Fedora Marketing]     [Fedora Packaging]     [Fedora SELinux]     [Yosemite Discussion]     [KDE Users]     [Fedora Docs]

  Powered by Linux