path: root/discover/discover-server.h
Commit message (Collapse)AuthorAgeFilesLines
* discover: Handle and track plugin_optionsSamuel Mendoza-Jonas2017-08-151-0/+5
| | | | | | | | | | Track plugin_options in the device_handler. Plugins can be added with device_handler_add_plugin_option() and accessed via device_handler_get_plugin(). Extend discover_server to support the new 'add' and 'remove' pb-protocol actions and advertise new plugins to connecting clients. Signed-off-by: Samuel Mendoza-Jonas <>
* types: shorten boot_status definitionsJeremy Kerr2016-12-201-2/+2
| | | | | | | | | | | struct boot_status is a bit misnamed; we report status on things that aren't just the boot status (eg, discovery). This change refactors struct boot_status into just struct status. We give the type enum a name, and shorten the enum values to suit. Signed-off-by: Jeremy Kerr <> Signed-off-by: Samuel Mendoza-Jonas <>
* config: Implement config messagesJeremy Kerr2013-11-131-0/+3
| | | | | | On client connect, send a PB_PROTOCOL_ACTION_CONFIG message. Signed-off-by: Jeremy Kerr <>
* Add system info messagesJeremy Kerr2013-10-091-0/+3
| | | | | | | | Add a little infrastructure for communicating information about the system to the petitboot UIs. We just send some identifying info (type and identifier), as well as the interfaces. Signed-off-by: Jeremy Kerr <>
* discover: Add discover_server_notify_boot_statusJeremy Kerr2013-05-061-0/+3
| | | | | | Add a function to the server to notify clients of boot status updates. Signed-off-by: Jeremy Kerr <>
* protocol: Separate device add from boot-option add messagesJeremy Kerr2013-04-161-2/+5
| | | | | | | | | | | | | | | | | | | | We want to cater for situations where boot options may be discovered some time after we get notificiation about devices. For instance, discovering boot options from DHCP configuration parameters. In this case, we'll need to notify UIs of boot options appear some time after the device (and/or other boot options on the same device) has appeared. This change adds a new protocol message type, PB_PROTOCOL_ACTION_BOOT_OPTION_ADD. We also rename PB_PROTOCOL_ACTION_ADD to make it clear that it is just for devices. The discover server is updated to send boot option add events at device discover time, but we are now able to decouple this later. We also update the clients to handle the boot option add events separately. Signed-off-by: Jeremy Kerr <>
* waiter: Don't rely on global variables to keep waiter stateJeremy Kerr2013-04-101-1/+3
| | | | | | | | | Rather than defining the set of waiters (and pollfds) in waiter.c, add a struct waitset to contain these. A waitset is created with waitset_create, which is passed to the waiter_* functions. Signed-off-by: Jeremy Kerr <> Signed-off-by: Geoff Levand <>
* Hook up parsers to device discoveryJeremy Kerr2009-01-021-0/+5
| | | | | | | | Iterate the parsers from the device handler on an add event. Initial change to just the kboot parser. Signed-off-by: Jeremy Kerr <>
* Create device-handler for managing registered devicesJeremy Kerr2008-12-151-0/+4
| | | | Signed-off-by: Jeremy Kerr <>
* Initial support for multiple UIsJeremy Kerr2008-12-151-0/+10
Move the device discovery code from separate udev helpers to a single process to listen on two sockets: one SOCK_DGRAM for incoming udev events, and one SOCK_STREAM for UIs to connect. Initial support for client/server infrastructure, still need to wire-up the udev messages. Signed-off-by: Jeremy Kerr <>
OpenPOWER on IntegriCloud