X-Git-Url: http://git.ozlabs.org/?p=petitboot;a=blobdiff_plain;f=discover%2Fparser-utils.c;h=f4a35a752c8a46f28f3da39f809ddf2c7b4ffc0e;hp=4982112f403abcd142dd7ffe0d4e2cc6870811e0;hb=9f0f86150e9bf14760e155768dcb7df682257327;hpb=ce5eab024583af5a4725503bad6ed2aee452b1aa diff --git a/discover/parser-utils.c b/discover/parser-utils.c index 4982112..f4a35a7 100644 --- a/discover/parser-utils.c +++ b/discover/parser-utils.c @@ -1,20 +1,15 @@ #include +#include #include -#include "pb-protocol/pb-protocol.h" +#include "types/types.h" +#include "event.h" #include "udev.h" #include "device-handler.h" #include "parser-utils.h" -void device_add_boot_option(struct device *device, - struct boot_option *boot_option) -{ - list_add(&device->boot_options, &boot_option->list); - talloc_steal(device, boot_option); -} - const char *generic_icon_file(enum generic_icon_type type) { switch (type) { @@ -33,13 +28,13 @@ const char *generic_icon_file(enum generic_icon_type type) enum generic_icon_type guess_device_type(struct discover_context *ctx) { - struct udev_event *event; + struct event *event; const char *type, *bus; event = ctx->event; - type = udev_event_param(event, "ID_TYPE"); - bus = udev_event_param(event, "ID_BUS"); + type = event_get_param(event, "ID_TYPE"); + bus = event_get_param(event, "ID_BUS"); if (type && streq(type, "cd")) return ICON_TYPE_OPTICAL;