X-Git-Url: http://git.ozlabs.org/?p=petitboot;a=blobdiff_plain;f=discover%2Fdiscover-server.c;h=6c803728511cb5ea523ee52f33668a7f6982c166;hp=7633134c2ea639b1ac410564465f8c2a9ca2dfee;hb=b8122dc9340e2f208220f0c88b4d71f91b78774f;hpb=a2f7b111a2073a4afaf75499ac4c2732b71ea801 diff --git a/discover/discover-server.c b/discover/discover-server.c index 7633134..6c80372 100644 --- a/discover/discover-server.c +++ b/discover/discover-server.c @@ -130,6 +130,7 @@ static int write_remove_message(struct discover_server *server, static int discover_server_process_message(void *arg) { struct pb_protocol_message *message; + struct boot_command *boot_command; struct client *client = arg; message = pb_protocol_read_message(client, client->fd); @@ -142,7 +143,14 @@ static int discover_server_process_message(void *arg) return 0; } - /* todo: process boot message */ + boot_command = pb_protocol_deserialise_boot_command(client, message); + if (!boot_command) { + pb_log("%s: no boot command?", __func__); + return 0; + } + + device_handler_boot(client->server->device_handler, boot_command); + return 0; }