diff options
author | Marc Kleine-Budde <mkl@pengutronix.de> | 2013-04-03 10:12:13 +0200 |
---|---|---|
committer | Sascha Hauer <s.hauer@pengutronix.de> | 2013-04-04 10:54:27 +0200 |
commit | 5d8240619c62dee029eb3976d597175fe8dcefc3 (patch) | |
tree | 9638620d432db7377ed9ba616cc4f1c369dba9c4 /include/bootsource.h | |
parent | 54c3870f5426bab88f2f4ae456a9c88b996969ac (diff) | |
download | barebox-5d8240619c62dee029eb3976d597175fe8dcefc3.tar.gz barebox-5d8240619c62dee029eb3976d597175fe8dcefc3.tar.xz |
bootsource: add support for bootsource instance information
Add a C interface to set and get the bootsource instance:
int bootsource_get_instance(void);
void bootsource_set_instance(int instance);
Also export the shell variable "bootsource_instance".
Signed-off-by: Marc Kleine-Budde <mkl@pengutronix.de>
Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
Diffstat (limited to 'include/bootsource.h')
-rw-r--r-- | include/bootsource.h | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/include/bootsource.h b/include/bootsource.h index ecd5938226..44b69b196a 100644 --- a/include/bootsource.h +++ b/include/bootsource.h @@ -13,7 +13,11 @@ enum bootsource { BOOTSOURCE_HD, }; +#define BOOTSOURCE_INSTANCE_UNKNOWN -1 + enum bootsource bootsource_get(void); +int bootsource_get_instance(void); void bootsource_set(enum bootsource src); +void bootsource_set_instance(int instance); #endif /* __BOOTSOURCE_H__ */ |