]> git.ozlabs.org Git - petitboot/blob - devices/udev-helper.h
Merge branch 'master' of ssh://ozlabs.org/home/jk/git/petitboot
[petitboot] / devices / udev-helper.h
1
2 #include "message.h"
3
4 int add_device(const struct device *dev);
5
6 int add_boot_option(const struct boot_option *opt);
7 void free_boot_option(struct boot_option *opt);
8
9 int mount_device(const char *dev_path, char *mount_path);
10
11 struct parser {
12         char *name;
13         int priority;
14         int (*parse)(const char *devicepath, const char *mountpoint);
15         struct parser *next;
16 };
17
18 enum generic_icon_type {
19         ICON_TYPE_DISK,
20         ICON_TYPE_USB,
21         ICON_TYPE_OPTICAL,
22         ICON_TYPE_NETWORK,
23         ICON_TYPE_UNKNOWN
24 };
25
26 enum generic_icon_type guess_device_type(void);
27 const char *generic_icon_file(enum generic_icon_type type);
28
29 #define streq(a,b) (!strcasecmp((a),(b)))