[systemd-devel] [PATCH 0/7] kdbus: improve user domain accounting
Djalal Harouni
tixxdz at opendz.org
Wed Jul 23 14:19:04 PDT 2014
Hi,
This series improves user domain accounting and fixes some bugs.
On top of the "kdbus: allow multiple policies" series:
http://lists.freedesktop.org/archives/systemd-devel/2014-July/021514.html
Patches 1, 2, 3 and 4 are preparation patches to improve the code.
Patch 5 fixes kdbus_domain_user_find_or_new(), callers assume that
kdbus_domain_user_find_or_new() will fail only with -ENOMEM, but it
may fail with -ESHUTDOWN, so adapt the code to return the appropriate
errors and fix all callers.
Patch 6 makes use of the new helpers in order to reduce the number
of domain locks taken in kdbus_bus_new(). The domain is the upper layer,
reducing the locks should reduce some overheads.
In order to reduce the number of locks in this patch 6, we make the
domain->user_idr start from 1, so if a user->idr == 0 we assume that
it was not accounted. This logic was used in patch 5 which contains
the detailed explanation.
Patch 7 fixes a user quota accounting corruption.
Thanks!
More information about the systemd-devel
mailing list