本文整理汇总了C++中driver_init函数的典型用法代码示例。如果您正苦于以下问题:C++ driver_init函数的具体用法?C++ driver_init怎么用?C++ driver_init使用的例子?那么恭喜您, 这里精选的函数代码示例或许可以为您提供帮助。
在下文中一共展示了driver_init函数的15个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C++代码示例。
示例1: checkboard
int checkboard(void)
{
struct ps2_bootinfo *info = (void *) CKSEG0ADDR(PS2_BOOTINFO_OLDADDR);
uint32_t size;
volatile uint32_t *sbios_magic;
int sbversion = 0;
struct ps2_bootinfo bootinfo;
puts("Board: Sony Playstation 2 MIPS r5900\n");
memset(&bootinfo, 0, sizeof(bootinfo));
size = info->size;
if (size > sizeof(bootinfo)) {
size = sizeof(bootinfo);
}
memcpy(&bootinfo, info, size);
sbios_magic = (uint32_t *) SBIOS_MAGIC;
if (*sbios_magic == SBIOS_MAGICVAL) {
gd->arch._sbios = *(int (**)(int, void *))(SBIOS_BASE);
}
else
gd->arch._sbios = NULL;
sbversion = sbios(SB_GETVER, NULL);
printf("SBIOS Version 0x%08x\n", sbversion);
driver_init();
return 0;
}
示例2: kernel_main
int kernel_main()
{
/*
* Tell the kernel memory allocator which memory it can't use.
* It already knows not to touch kernel image.
*/
lmm_remove_free( &malloc_lmm, (void*)USER_MEM_START, USER_MEM_SIZE );
lmm_remove_free( &malloc_lmm, (void*)0, 0x100000 );
/*
* Initialize drivers here.
*/
driver_init();
/*
* initialize the PIC so that IRQs and
* exception handlers don't overlap in the IDT.
*/
pic_init( BASE_IRQ_MASTER_BASE, BASE_IRQ_SLAVE_BASE );
/* This is all up to you... */
return -1;
}
示例3: sef_cb_init_fresh
/*===========================================================================*
* sef_cb_init_fresh *
*===========================================================================*/
PRIVATE int sef_cb_init_fresh(int type, sef_init_info_t *info)
{
/* Initialize the filter driver. */
int r;
r = parse_arguments(env_argc, env_argv);
if(r != OK) {
printf("Filter: wrong argument!\n");
return 1;
}
if ((buf_array = flt_malloc(BUF_SIZE, NULL, 0)) == NULL)
panic("no memory available");
sum_init();
driver_init();
/* Subscribe to driver events for VFS drivers. */
r = ds_subscribe("drv\\.vfs\\..*", DSF_INITIAL | DSF_OVERWRITE);
if(r != OK) {
panic("Filter: can't subscribe to driver events");
}
/* Announce we are up! */
driver_announce();
return(OK);
}
示例4: ConfigureLinuxHWDev
void
ConfigureLinuxHWDev(VPNum vp)
{
if (vp) return;
{
LinuxEnv le(SysCall);
vfs_caches_init(0x1<<8);
driver_init();
buffer_init();
}
ConfigureLinuxHWDevArch();
INITCALL(deadline_slab_setup);
INITCALL(device_init);
INITCALL(elevator_global_init);
INITCALL(init_bio);
INITCALL(vio_bus_init);
if (!KernelInfo::OnSim() || KernelInfo::OnHV()) {
INITCALL(pcibus_class_init);
INITCALL(pci_driver_init);
INITCALL(pci_init);
}
}
示例5: do_basic_setup
/*
* Ok, the machine is now initialized. None of the devices
* have been touched yet, but the CPU subsystem is up and
* running, and memory and process management works.
*
* Now we can finally start doing some real work..
*/
static void __init do_basic_setup(void)
{
rcu_init_sched(); /* needed by module_init stage. */
init_workqueues();
usermodehelper_init();
driver_init();
init_irq_proc();
do_initcalls();
}
示例6: do_basic_setup
/*
* Ok, the machine is now initialized. None of the devices
* have been touched yet, but the CPU subsystem is up and
* running, and memory and process management works.
*
* Now we can finally start doing some real work..
*/
static void __init do_basic_setup(void)
{
/* drivers will send hotplug events */
init_workqueues();
usermodehelper_init();
driver_init();
init_irq_proc();
do_initcalls();
}
示例7: system_init
/**
* @brief System initialization.
* @param None
* @retval None
*/
void system_init(void)
{
RCC_ClocksTypeDef tRCC;
RCC_GetClocksFreq(&tRCC);
delay_init(tRCC.HCLK_Frequency);
device_init();
driver_init();
}
示例8: dde_init
void dde_init()
{
/* invoked in vfs_cache_init in Linux */
chrdev_init();
driver_init();
dde_call_machine_init();
do_initcalls();
loadable_module_init();
}
示例9: do_basic_setup
/*
* Ok, the machine is now initialized. None of the devices
* have been touched yet, but the CPU subsystem is up and
* running, and memory and process management works.
*
* Now we can finally start doing some real work..
*/
static void __init do_basic_setup(void)
{
init_workqueues();
cpuset_init_smp();
usermodehelper_init();
init_tmpfs();
driver_init();
init_irq_proc();
do_ctors();
do_initcalls();
}
示例10: main
int main(int argc, char *argv[])
{
enum { SC = 3 };
int opt, n;
int sigs[] = { SIGINT, SIGHUP, SIGTERM };
void (*sighandlers[])() = { sigint_handler,
sighup_handler,
sigterm_handler };
struct sigaction s[SC];
for (n = 0; n < SC; ++n)
{
s[n].sa_handler = SIG_IGN;
sigfillset(&s[n].sa_mask);
s[n].sa_flags = 0;
sigaction(sigs[n], &s[n], NULL);
}
for (opt = 1; opt < argc; ++opt)
{
if (strcmp(argv[opt], "-h") == 0
|| strcmp(argv[opt], "--help") == 0)
{
show_usage();
return 0;
}
}
mod_src_create();
gtk_init(&argc, &argv);
settings_init();
driver_init();
lfo_tables_init();
mixer_init();
patch_control_init();
dish_file_state_init();
session_init(argc, argv);
gui_init();
for (n = 0; n < SC; ++n)
{
s[n].sa_handler = sighandlers[n];
sigfillset(&s[n].sa_mask);
s[n].sa_flags = 0;
sigaction(sigs[n], &s[n], NULL);
}
gtk_main();
cleanup();
return 0;
}
示例11: rmd_rec_start
int rmd_rec_start()
{
set_report_rec_stat();
if (driver_init() != 0)
return -1;
if (task_init() != 0)
return -1;
return 0;
}
示例12: egl_init_opengl
int egl_init_opengl(void *erlCallbacks)
{
#ifdef _WIN32
driver_init((TWinDynDriverCallbacks *) erlCallbacks);
#endif
if(egl_initiated == 0) {
if(load_gl_functions()) {
init_tess();
egl_initiated = 1;
}
}
return 1;
}
示例13: do_basic_setup
/*
* Ok, the machine is now initialized. None of the devices
* have been touched yet, but the CPU subsystem is up and
* running, and memory and process management works.
*
* Now we can finally start doing some real work..
*/
static void __init do_basic_setup(void)
{
driver_init();
#ifdef CONFIG_SYSCTL
sysctl_init();
#endif
/* Networking initialization needs a process context */
sock_init();
init_workqueues();
do_initcalls();
}
示例14: do_basic_setup
/*
* Ok, the machine is now initialized. None of the devices
* have been touched yet, but the CPU subsystem is up and
* running, and memory and process management works.
*
* Now we can finally start doing some real work..
*/
static void __init do_basic_setup(void)
{
/* drivers will send hotplug events */
init_workqueues();
usermodehelper_init();
driver_init();
#ifdef CONFIG_SYSCTL
sysctl_init();
#endif
/* Networking initialization needs a process context */
sock_init();
do_initcalls();
}
示例15: init
void init()
{
Serial.begin(115200);
debug("Starting...");
pinMode(FIRST_RUN_PIN, INPUT);
web_run();
if(digitalRead(FIRST_RUN_PIN) && AppSettings.load()){
debugf("SSID:%s PASS:%s", AppSettings.ssid.c_str(), AppSettings.password.c_str());
WifiStation.config(AppSettings.ssid.c_str(), AppSettings.password.c_str());
WifiStation.waitConnection(on_wifi_connected);
driver_init();
} else {
first_run();
}
}