Messages in this thread | | | Date | Mon, 25 May 2020 09:12:14 +0200 | From | Ingo Molnar <> | Subject | Re: [PATCH v2 1/7] locking: Introduce local_lock() |
| |
* Ingo Molnar <mingo@kernel.org> wrote:
> ( The other departure from spinlocks is that the 'spinlock_t' name, > without underscores, while making the API names such as spin_lock() > with an underscore, was a conscious didactic choice. Applying that > principle to local locks gives us the spinlock_t-equivalent name of > 'locallock_t' - but the double 'l' reads a bit weirdly in this > context. So I think using 'local_lock_t' as the data structure is > probably the better approach. )
BTW., along this argument, I believe we should rename the local-lock header file from <linux/locallock.h> to <linux/local_lock.h>.
The reason for the <linux/spinlock.h> naming is that the main data structure is spinlock_t.
Having <linux/locallock.h> for 'struct local_lock' or 'local_lock_t' would introduce an idiosyncratic namespace quirk for no good reason.
Thanks,
Ingo
| |