Messages in this thread | | | Date | Thu, 14 Oct 2021 23:30:03 -0700 | From | Christoph Hellwig <> | Subject | Re: [PATCH v7 1/8] dax: Use rwsem for dax_{read,write}_lock() |
| |
On Fri, Sep 24, 2021 at 09:09:52PM +0800, Shiyang Ruan wrote: > In order to introduce dax holder registration, we need a write lock for > dax. Because of the rarity of notification failures and the infrequency > of registration events, it would be better to be a global lock rather > than per-device. So, change the current lock to rwsem and introduce a > write lock for registration.
I don't think taking the rw_semaphore everywhere will scale, as basically any DAX based I/O will take it (in read mode).
So at a minimum we'd need a per-device percpu_rw_semaphore if we want to go there.
| |