⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 kprintf.c

📁 内核linux2.4.20,可跟rtlinux3.2打补丁 组成实时linux系统,编译内核
💻 C
字号:
/* * Source file for kernel interface to kernel log facility * * Copyright (C) Eicon Technology Corporation, 2000. * * Eicon File Revision :    1.3   * * This software may be used and distributed according to the terms * of the GNU General Public License, incorporated herein by reference. * */#include "eicon.h"#include "sys.h"#include <stdarg.h>#include "divas.h"#include "divalog.h"#include "uxio.h"void    DivasPrintf(char  *fmt, ...){    klog_t      log;            /* log entry buffer */    va_list     argptr;         /* pointer to additional args */    va_start(argptr, fmt);    /* clear log entry */    memset((void *) &log, 0, sizeof(klog_t));    log.card = -1;    log.type = KLOG_TEXT_MSG;    /* time stamp the entry */    log.time_stamp = UxTimeGet();    /* call vsprintf to format the user's information */    vsnprintf(log.buffer, DIM(log.buffer), fmt, argptr);    va_end(argptr);    /* send to the log streams driver and return */    DivasLogAdd(&log, sizeof(klog_t));    return;}

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -