9
0
Fork 0
barebox/lib_generic/global.c

36 lines
645 B
C
Raw Normal View History

#include <common.h>
#include <command.h>
#include <init.h>
#include <driver.h>
#include <malloc.h>
2007-07-05 16:01:34 +00:00
#include <errno.h>
2007-07-05 16:01:29 +00:00
static struct device_d global_dev;
2007-07-05 16:01:57 +00:00
int global_add_param(struct param_d *param)
{
2007-07-05 16:01:57 +00:00
return dev_add_param(&global_dev, param);
}
2007-07-05 16:01:29 +00:00
static struct device_d global_dev = {
.name = "global",
.id = "env",
.map_base = 0,
.size = 0,
};
2007-07-05 16:01:29 +00:00
static struct driver_d global_driver = {
.name = "global",
2007-07-05 16:01:32 +00:00
.probe = dummy_probe,
};
static int global_init(void)
{
2007-07-05 16:01:29 +00:00
register_device(&global_dev);
register_driver(&global_driver);
return 0;
}
coredevice_initcall(global_init);