本文整理汇总了C++中driver_init函数的典型用法代码示例。如果您正苦于以下问题:C++ driver_init函数的具体用法?C++ driver_init怎么用?C++ driver_init使用的例子?那么恭喜您, 这里精选的函数代码示例或许可以为您提供帮助。
在下文中一共展示了driver_init函数的20个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于我们的系统推荐出更棒的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;
}
开发者ID:jur,项目名称:ps2-u-boot,代码行数:29,代码来源:ps2.c
示例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;
}
开发者ID:shalinipriya,项目名称:Device-Drivers,代码行数:25,代码来源:kernel.c
示例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);
}
开发者ID:Spenser309,项目名称:CS551,代码行数:32,代码来源:main.c
示例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);
}
}
开发者ID:BillTheBest,项目名称:k42,代码行数:27,代码来源:Configure.C
示例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();
}
开发者ID:souljaboy11792,项目名称:ZCF-kernel,代码行数:16,代码来源:main.c
示例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();
}
开发者ID:JiakangJ,项目名称:cs370,代码行数:16,代码来源:main.c
示例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();
}
开发者ID:Seok-Jung,项目名称:STM32F207,代码行数:15,代码来源:Config.c
示例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();
}
开发者ID:chyyuu,项目名称:ucore-arch-arm,代码行数:11,代码来源:dde_main.c
示例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();
}
开发者ID:badcompany1982,项目名称:android_kernel_zte_V768,代码行数:18,代码来源:main.c
示例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;
}
开发者ID:jphaenlin,项目名称:Petri-Foo,代码行数:53,代码来源:petri-foo.c
示例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;
}
开发者ID:WayWingsDev,项目名称:openrmd,代码行数:12,代码来源:rmd_rec.c
示例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;
}
开发者ID:Bwooce,项目名称:otp,代码行数:13,代码来源:egl_impl.cpp
示例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();
}
开发者ID:OS2World,项目名称:DRV-LXAPI32,代码行数:21,代码来源:oi_main.c
示例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();
}
开发者ID:kzlin129,项目名称:tt-gpl,代码行数:23,代码来源:main.c
示例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();
}
}
开发者ID:Bravo13,项目名称:esp_hello_world,代码行数:17,代码来源:application.cpp
示例16: dde_linux26_init
void dde_linux26_init()
{
/* initialize DDE kit */
dde_kit_init();
/* initialize DDE Linux 2.6 subsystems */
dde_linux26_printk_init();
dde_linux26_kmalloc_init();
dde_linux26_process_init();
dde_linux26_timer_init();
dde_linux26_softirq_init();
/* add main thread as potential worker */
dde_linux26_process_add_worker("DDE main");
/* init Linux driver framework before trying to add PCI devs to the bus */
driver_init();
}
开发者ID:ssumpf,项目名称:linux_drivers,代码行数:18,代码来源:init.c
示例17: main
int main(void)
{
bsp_init();
debug_init(DBG_LEVEL_TRACE | DBG_LEVEL_INFO | DBG_LEVEL_WARNING |
DBG_LEVEL_ERROR);
esn_detect_init();
esn_active_init();
esn_gain_init();
driver_init();
stack_init();
vTaskStartScheduler();
return 0;
}
开发者ID:utopiaprince,项目名称:esn,代码行数:18,代码来源:main.c
示例18: 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();
#ifdef CONFIG_OPENRG
/* Instruct mmap and do_mmap not to verify there are free pages before
* doing the mapping. This is useful when trying to load an executable
* that is larger than the current free memory. We let the swap
* mechanism to handle such cases because very little of the executable
* pages are really needed in ram at the same time. */
sysctl_overcommit_memory = OVERCOMMIT_ALWAYS;
#endif
}
开发者ID:DentonGentry,项目名称:gfiber-gfrg100,代码行数:25,代码来源:main.c
示例19: main
void main(void)
#endif
{
int ret, ret_code;
driver_init();
ret = bt_enable(NULL);
if (ret == EXPECTED_ERROR) {
ret_code = TC_PASS;
} else {
ret_code = TC_FAIL;
}
TC_END(ret_code, "%s - %s.\n", ret_code == TC_PASS ? PASS : FAIL,
__func__);
TC_END_REPORT(ret_code);
}
开发者ID:PchZhang,项目名称:testgit,代码行数:19,代码来源:bluetooth.c
示例20: ConfigureLinuxEnv
/* static */ SysStatus
LinuxPTYServer::ClassInit(VPNum vp)
{
if (vp==0) {
CharDevOpener::charDevs = new CharDevOpener::DeviceHash;
MetaStreamServer::init();
MetaDevOpener::init();
}
ConfigureLinuxEnv(vp, GOBJ(ThePageAllocatorRef));
ConfigureLinuxGeneric(vp);
if (vp==0) {
LinuxEnv le(SysCall);
vfs_caches_init(0x1<<8);
driver_init();
console_init();
ptyDir = k42devfs_mk_dir("pty");
ptsDir = k42devfs_mk_dir("pts");
RegisterInitCall(new InitCall(&__initcall_tty_init));
RegisterInitCall(new InitCall(&__initcall_pty_init));
RegisterInitCall(new InitCall(&__initcall_tty_class_init));
LinuxEnvSuspend();
VPNum vpCnt = _SGETUVAL(DREFGOBJ(TheProcessRef)->vpCount());
for (VPNum i = 1; i < vpCnt; i++) {
LinuxStartVP(i, LinuxPTYServer::ClassInit);
}
LinuxEnvResume();
ConfigureLinuxFinal(0);
}
return 0;
}
开发者ID:BillTheBest,项目名称:k42,代码行数:39,代码来源:LinuxPTY.C
注:本文中的driver_init函数示例由纯净天空整理自Github/MSDocs等源码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。 |
请发表评论