]> git.ipfire.org Git - thirdparty/systemd.git/commit
network: dhcp6: manage assigned downstream prefixes by using Hashmap
authorYu Watanabe <watanabe.yu+github@gmail.com>
Wed, 13 Oct 2021 18:10:31 +0000 (03:10 +0900)
committerYu Watanabe <watanabe.yu+github@gmail.com>
Mon, 18 Oct 2021 15:57:23 +0000 (00:57 +0900)
commitcde09c34508947fbb4097facd9185dd385a1dbb5
treedc1f8f2e85ce9b3d5c81add6d5abb4d00f7c389e
parent3f3bc1f2e70b7af71b58a551ed0be4438b0d9a9e
network: dhcp6: manage assigned downstream prefixes by using Hashmap

When a system has thousands of downstream interfaces, previously the
total cost of finding free subnet ID was O(n^2), where n is the number
of downstream interfaces.

This makes assigned prefixes are managed by Manager with Hashmap. So,
the cost becomes O(n log n).
src/network/networkd-dhcp6.c
src/network/networkd-manager.c
src/network/networkd-manager.h