summaryrefslogtreecommitdiffstats
path: root/src/network/networkd-dhcp-server.c
diff options
context:
space:
mode:
authorYu Watanabe <watanabe.yu+github@gmail.com>2022-02-25 02:40:09 +0100
committerYu Watanabe <watanabe.yu+github@gmail.com>2022-02-25 03:01:50 +0100
commit8bed7c55bf94115ce471a0331d3436bfcb72c057 (patch)
tree6a1e41947be910853bf1e49758129092330d7fb6 /src/network/networkd-dhcp-server.c
parentnetwork: address: drop unnecessary call of address_get() (diff)
downloadsystemd-8bed7c55bf94115ce471a0331d3436bfcb72c057.tar.xz
systemd-8bed7c55bf94115ce471a0331d3436bfcb72c057.zip
network: move functions
No functional change. Preparation for later commits.
Diffstat (limited to 'src/network/networkd-dhcp-server.c')
-rw-r--r--src/network/networkd-dhcp-server.c26
1 files changed, 13 insertions, 13 deletions
diff --git a/src/network/networkd-dhcp-server.c b/src/network/networkd-dhcp-server.c
index c4eaac3dee..2876210730 100644
--- a/src/network/networkd-dhcp-server.c
+++ b/src/network/networkd-dhcp-server.c
@@ -532,19 +532,6 @@ static int dhcp4_server_configure(Link *link) {
return 1;
}
-int link_request_dhcp_server(Link *link) {
- assert(link);
-
- if (!link_dhcp4_server_enabled(link))
- return 0;
-
- if (link->dhcp_server)
- return 0;
-
- log_link_debug(link, "Requesting DHCP server.");
- return link_queue_request(link, REQUEST_TYPE_DHCP_SERVER, NULL, false, NULL, NULL, NULL);
-}
-
static bool dhcp_server_is_ready_to_configure(Link *link) {
Link *uplink = NULL;
Address *a;
@@ -592,6 +579,19 @@ int request_process_dhcp_server(Request *req) {
return dhcp4_server_configure(req->link);
}
+int link_request_dhcp_server(Link *link) {
+ assert(link);
+
+ if (!link_dhcp4_server_enabled(link))
+ return 0;
+
+ if (link->dhcp_server)
+ return 0;
+
+ log_link_debug(link, "Requesting DHCP server.");
+ return link_queue_request(link, REQUEST_TYPE_DHCP_SERVER, NULL, false, NULL, NULL, NULL);
+}
+
int config_parse_dhcp_server_relay_agent_suboption(
const char *unit,
const char *filename,