本文整理汇总了C++中pr_dbg函数的典型用法代码示例。如果您正苦于以下问题:C++ pr_dbg函数的具体用法?C++ pr_dbg怎么用?C++ pr_dbg使用的例子?那么恭喜您, 这里精选的函数代码示例或许可以为您提供帮助。
在下文中一共展示了pr_dbg函数的20个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于我们的系统推荐出更棒的C++代码示例。
示例1: gx1001_set_frontend
static int gx1001_set_frontend(struct dvb_frontend *fe, struct dvb_frontend_parameters *p)
{
struct gx1001_state *state = fe->demodulator_priv;
demod_connect(state, p->frequency,p->u.qam.modulation,p->u.qam.symbol_rate);
state->freq=p->frequency;
state->mode=p->u.qam.modulation ;
state->symbol_rate=p->u.qam.symbol_rate; //these data will be writed to eeprom
pr_dbg("gx1001=>frequency=%d,symbol_rate=%d\r\n",p->frequency,p->u.qam.symbol_rate);
return 0;
}
开发者ID:32743069,项目名称:amlogic_common_3050,代码行数:12,代码来源:gxfrontend.c
示例2: dib7090_fe_release
static void dib7090_fe_release(struct aml_dvb *advb, struct aml_fe *fe)
{
if(fe && fe->fe) {
pr_dbg("release fe Dib7090 %d\n", fe->id);
dvb_unregister_frontend(fe->fe);
dvb_frontend_detach(fe->fe);
dib7090_fe_cfg_put(fe->cfg);
fe->fe = NULL;
fe->cfg = NULL;
fe->id = -1;
}
}
开发者ID:32743069,项目名称:amlogic_common_3050,代码行数:12,代码来源:dib7090p.c
示例3: demod_check_locked
int demod_check_locked(unsigned char* lock)
{
if(CXD2837_GetTPLock(cxd2837)==SONY_RESULT_OK)
{
pr_dbg("demod_check_locked !!\n");
*lock =1;
return 1;
}
*lock =0;
return 0;
}
开发者ID:EPDCenter,项目名称:android_kernel_amlogic_s805_3go_aplay2,代码行数:12,代码来源:cxd2861_cxd2837_api.c
示例4: rdma_rm_modify_qp
int rdma_rm_modify_qp(RdmaDeviceResources *dev_res, RdmaBackendDev *backend_dev,
uint32_t qp_handle, uint32_t attr_mask,
union ibv_gid *dgid, uint32_t dqpn,
enum ibv_qp_state qp_state, uint32_t qkey,
uint32_t rq_psn, uint32_t sq_psn)
{
RdmaRmQP *qp;
int ret;
pr_dbg("qpn=%d\n", qp_handle);
qp = rdma_rm_get_qp(dev_res, qp_handle);
if (!qp) {
return -EINVAL;
}
pr_dbg("qp_type=%d\n", qp->qp_type);
pr_dbg("attr_mask=0x%x\n", attr_mask);
if (qp->qp_type == IBV_QPT_SMI) {
pr_dbg("QP0 unsupported\n");
return -EPERM;
} else if (qp->qp_type == IBV_QPT_GSI) {
pr_dbg("QP1\n");
return 0;
}
if (attr_mask & IBV_QP_STATE) {
qp->qp_state = qp_state;
pr_dbg("qp_state=%d\n", qp->qp_state);
if (qp->qp_state == IBV_QPS_INIT) {
ret = rdma_backend_qp_state_init(backend_dev, &qp->backend_qp,
qp->qp_type, qkey);
if (ret) {
return -EIO;
}
}
if (qp->qp_state == IBV_QPS_RTR) {
ret = rdma_backend_qp_state_rtr(backend_dev, &qp->backend_qp,
qp->qp_type, dgid, dqpn, rq_psn,
qkey, attr_mask & IBV_QP_QKEY);
if (ret) {
return -EIO;
}
}
if (qp->qp_state == IBV_QPS_RTS) {
ret = rdma_backend_qp_state_rts(&qp->backend_qp, qp->qp_type,
sq_psn, qkey,
attr_mask & IBV_QP_QKEY);
if (ret) {
return -EIO;
}
}
}
return 0;
}
开发者ID:CRYP706URU,项目名称:pyrebox,代码行数:60,代码来源:rdma_rm.c
示例5: killer
/*
* killer()
* this continually stops and continues the runner process
*/
static void killer(
const char *name,
const pid_t pid,
uint64_t *counter,
const uint64_t max_ops)
{
double start = time_now();
uint64_t last_counter = *counter;
pr_dbg(stderr, "%s: wait: killer started [%d]\n", name, getpid());
do {
(void)kill(pid, SIGSTOP);
(void)kill(pid, SIGCONT);
/*
* The waits may be blocked and
* so the counter is not being updated.
* If it is blocked for too long bail out
* so we don't get stuck in the parent
* waiter indefintely.
*/
if (last_counter == *counter) {
if (time_now() - start > ABORT_TIMEOUT) {
pr_dbg(stderr, "%s: waits were blocked, "
"aborting\n", name);
break;
}
} else {
start = time_now();
last_counter = *counter;
}
} while (opt_do_run && (!max_ops || *counter < max_ops));
/* forcefully kill runner, wait is in parent */
(void)kill(pid, SIGKILL);
/* tell parent to wake up! */
(void)kill(getppid(), SIGALRM);
exit(EXIT_SUCCESS);
}
开发者ID:crossbuild,项目名称:stress-ng,代码行数:44,代码来源:stress-wait.c
示例6: cdx2834_fe_release
static void cdx2834_fe_release(struct aml_dvb *advb, struct aml_fe *fe)
{
if(fe && fe->fe) {
pr_dbg("release GX1001 frontend %d\n", fe->id);
dvb_unregister_frontend(fe->fe);
dvb_frontend_detach(fe->fe);
if(fe->cfg){
kfree(fe->cfg);
fe->cfg = NULL;
}
fe->id = -1;
}
}
开发者ID:j1nx,项目名称:tlbb-linux-kernel-m3,代码行数:13,代码来源:cxd2834frontend.c
示例7: file_exists
/**
* file_exists()
* @path: file to check.
* Determine if specified file exists.
*
* Returns: file type if @path exists, else 0.
**/
static int file_exists(const char *path)
{
struct stat st;
if (!path) {
pr_dbg("%s: empty path specified\n", __func__);
return 0;
}
if (stat(path, &st) < 0)
return 0;
return (st.st_mode & S_IFMT);
}
开发者ID:ColinIanKing,项目名称:stress-ng,代码行数:20,代码来源:core-cache.c
示例8: mxl101_fe_enter_mode
static int mxl101_fe_enter_mode(struct aml_fe *fe, int mode)
{
struct aml_fe_dev *dev = fe->dtv_demod;
pr_dbg("=========================demod init\r\n");
gpio_direction_output(dev->reset_gpio, dev->reset_value);
msleep(300);
gpio_direction_output(dev->reset_gpio, !dev->reset_value); //enable tuner power
msleep(200);
MxL101SF_Init(dev);
return 0;
}
开发者ID:32743069,项目名称:amlogic_common_3050,代码行数:13,代码来源:mxlfrontend.c
示例9: res_tbl_get
void *rdma_rm_get_cqe_ctx(RdmaDeviceResources *dev_res, uint32_t cqe_ctx_id)
{
void **cqe_ctx;
cqe_ctx = res_tbl_get(&dev_res->cqe_ctx_tbl, cqe_ctx_id);
if (!cqe_ctx) {
return NULL;
}
pr_dbg("ctx=%p\n", *cqe_ctx);
return *cqe_ctx;
}
开发者ID:CRYP706URU,项目名称:pyrebox,代码行数:13,代码来源:rdma_rm.c
示例10: modify_qp
static int modify_qp(PVRDMADev *dev, union pvrdma_cmd_req *req,
union pvrdma_cmd_resp *rsp)
{
struct pvrdma_cmd_modify_qp *cmd = &req->modify_qp;
pr_dbg("qp_handle=%d\n", cmd->qp_handle);
memset(rsp, 0, sizeof(*rsp));
rsp->hdr.response = cmd->hdr.response;
rsp->hdr.ack = PVRDMA_CMD_MODIFY_QP_RESP;
rsp->hdr.err = rdma_rm_modify_qp(&dev->rdma_dev_res, &dev->backend_dev,
cmd->qp_handle, cmd->attr_mask,
(union ibv_gid *)&cmd->attrs.ah_attr.grh.dgid,
cmd->attrs.dest_qp_num,
(enum ibv_qp_state)cmd->attrs.qp_state,
cmd->attrs.qkey, cmd->attrs.rq_psn,
cmd->attrs.sq_psn);
pr_dbg("ret=%d\n", rsp->hdr.err);
return rsp->hdr.err;
}
开发者ID:JayFoxRox,项目名称:xqemu,代码行数:22,代码来源:pvrdma_cmd.c
示例11: AVL6211_Blindscan_Cancel
static int AVL6211_Blindscan_Cancel(struct dvb_frontend* fe)
{
blindstart=0;
printk(KERN_INFO "AVL6211_Blindscan_Cancel\n");
while(2!=blindstart){
pr_dbg("wait for scan exit\n");
msleep(100);
}
/*call do_exit() directly*/
dvbs2_task = NULL;
fe_use = NULL;
return 0;
}
开发者ID:TinyHTPC,项目名称:buildroot-linux-kernel-m6,代码行数:13,代码来源:avlfrontend.c
示例12: cdx2834_fe_init
static int cdx2834_fe_init(struct aml_dvb *advb, struct platform_device *pdev, struct aml_fe *fe, int id)
{
struct dvb_frontend_ops *ops;
int ret;
struct resource *res;
struct cdx2834_fe_config *cfg;
char buf[32];
pr_dbg("init CDX2834 frontend %d\n", id);
cfg = kzalloc(sizeof(struct cdx2834_fe_config), GFP_KERNEL);
if (!cfg)
return -ENOMEM;
cfg->reset_pin = frontend_reset;
if(cfg->reset_pin==-1) {
snprintf(buf, sizeof(buf), "frontend%d_reset", id);
res = platform_get_resource_byname(pdev, IORESOURCE_MEM, buf);
if (!res) {
pr_error("cannot get resource \"%s\"\n", buf);
ret = -EINVAL;
goto err_resource;
}
cfg->reset_pin = res->start;
}
cfg->i2c_id = frontend_i2c;
if(cfg->i2c_id==-1) {
snprintf(buf, sizeof(buf), "frontend%d_i2c", id);
res = platform_get_resource_byname(pdev, IORESOURCE_MEM, buf);
if (!res) {
pr_error("cannot get resource \"%s\"\n", buf);
ret = -EINVAL;
goto err_resource;
}
cfg->i2c_id = res->start;
}
cfg->tuner_addr = frontend_tuner_addr;
if(cfg->tuner_addr==-1) {
snprintf(buf, sizeof(buf), "frontend%d_tuner_addr", id);
res = platform_get_resource_byname(pdev, IORESOURCE_MEM, buf);
if (!res) {
pr_error("cannot get resource \"%s\"\n", buf);
ret = -EINVAL;
goto err_resource;
}
cfg->tuner_addr = res->start>>1;
}
开发者ID:j1nx,项目名称:tlbb-linux-kernel-m3,代码行数:51,代码来源:cxd2834frontend.c
示例13: cr_access_vmexit_handler
int32_t cr_access_vmexit_handler(struct acrn_vcpu *vcpu)
{
uint64_t reg;
uint32_t idx;
uint64_t exit_qual;
int32_t ret = 0;
exit_qual = vcpu->arch.exit_qualification;
idx = (uint32_t)vm_exit_cr_access_reg_idx(exit_qual);
ASSERT((idx <= 15U), "index out of range");
reg = vcpu_get_gpreg(vcpu, idx);
switch ((vm_exit_cr_access_type(exit_qual) << 4U) | vm_exit_cr_access_cr_num(exit_qual)) {
case 0x00UL:
/* mov to cr0 */
vcpu_set_cr0(vcpu, reg);
break;
case 0x04UL:
/* mov to cr4 */
vcpu_set_cr4(vcpu, reg);
break;
case 0x08UL:
/* mov to cr8 */
/* According to SDM 6.15 "Exception and interrupt Reference":
*
* set reserved bit in CR8 causes GP to guest
*/
if ((reg & ~0xFUL) != 0UL) {
pr_dbg("Invalid cr8 write operation from guest");
vcpu_inject_gp(vcpu, 0U);
break;
}
vlapic_set_cr8(vcpu_vlapic(vcpu), reg);
break;
case 0x18UL:
/* mov from cr8 */
reg = vlapic_get_cr8(vcpu_vlapic(vcpu));
vcpu_set_gpreg(vcpu, idx, reg);
break;
default:
ASSERT(false, "Unhandled CR access");
ret = -EINVAL;
break;
}
TRACE_2L(TRACE_VMEXIT_CR_ACCESS, vm_exit_cr_access_type(exit_qual),
vm_exit_cr_access_cr_num(exit_qual));
return ret;
}
开发者ID:rossburton,项目名称:acrn-hypervisor,代码行数:51,代码来源:virtual_cr.c
示例14: adkeys_poll
static void adkeys_poll(struct adgpio_key_data *adkey)
{
int advol, i;
static struct adgpio_key *prev_keys = NULL;
static T_ad_check state = PLUGIN_INVALID;
static int is_change_flag = 0;
advol = adc1_read_ad5();
pr_dbg("poll: volatge: %d\n", advol);
for (i = 0; i < adkey->naddet; i++) {
if ((advol > adkey->addet[i].unpress_min)
&&(advol < adkey->addet[i].unpress_max)) {
adkey->keys = adkey->addet[i].fixkeys;
if ((prev_keys != adkey->keys) || (state != adkey->addet[i].plugdev)) {
prev_keys = adkey->keys;
state = adkey->addet[i].plugdev;
is_change_flag = 1;
} else {
is_change_flag = 0;
}
break;
}
}
if (is_change_flag) {
addetect_plugin_notify(state);
}
i = 0;
do {
if ((adkey->keys != NULL)
&& (advol > adkey->keys[i].min) && (advol < adkey->keys[i].max)) {
adkey->press = 1;
adkey->sync_me = 1;
adkey->keycode = adkey->keys[i].code;
adkey->loop = i;
break;
} else
adkey->press = 0;
i++;
} while(i < adkey->nkey);
if (adkey->sync_me) {
mod_timer(&adkey->timer,
jiffies + msecs_to_jiffies(adkey->debounce_interval));
}
}
开发者ID:gurkamalsingh88,项目名称:Lamobo-D1,代码行数:51,代码来源:akad-keys.c
示例15: smc_hw_read_atr
static int smc_hw_read_atr(smc_dev_t *smc)
{
char *ptr = smc->atr.atr;
int his_len, t, tnext = 0, only_t0 = 1, loop_cnt=0;
pr_dbg("read atr\n");
smc->atr.atr_len = 0;
if(smc_hw_get(smc, 2, 2000)<0)
goto end;
ptr++;
his_len = ptr[0]&0x0F;
do {
tnext = 0;
loop_cnt++;
if(ptr[0]&0x10) {
if(smc_hw_get(smc, 1, 1000)<0)
goto end;
}
if(ptr[0]&0x20) {
if(smc_hw_get(smc, 1, 1000)<0)
goto end;
}
if(ptr[0]&0x40) {
if(smc_hw_get(smc, 1, 1000)<0)
goto end;
}
if(ptr[0]&0x80) {
if(smc_hw_get(smc, 1, 1000)<0)
goto end;
ptr = &smc->atr.atr[smc->atr.atr_len-1];
t = ptr[0]&0x0F;
if(t) {
only_t0 = 0;
}
if(ptr[0]&0xF0) {
tnext = 1;
}
}
} while(tnext && loop_cnt<4);
if(!only_t0) his_len++;
smc_hw_get(smc, his_len, 1000);
return 0;
end:
return -EIO;
}
开发者ID:nspierbundel,项目名称:amlogic-common-3.0.8,代码行数:51,代码来源:smartcard.c
示例16: create_mr
static int create_mr(PVRDMADev *dev, union pvrdma_cmd_req *req,
union pvrdma_cmd_resp *rsp)
{
struct pvrdma_cmd_create_mr *cmd = &req->create_mr;
struct pvrdma_cmd_create_mr_resp *resp = &rsp->create_mr_resp;
PCIDevice *pci_dev = PCI_DEVICE(dev);
void *host_virt = NULL;
memset(resp, 0, sizeof(*resp));
resp->hdr.response = cmd->hdr.response;
resp->hdr.ack = PVRDMA_CMD_CREATE_MR_RESP;
pr_dbg("pd_handle=%d\n", cmd->pd_handle);
pr_dbg("access_flags=0x%x\n", cmd->access_flags);
pr_dbg("flags=0x%x\n", cmd->flags);
if (!(cmd->flags & PVRDMA_MR_FLAG_DMA)) {
host_virt = pvrdma_map_to_pdir(pci_dev, cmd->pdir_dma, cmd->nchunks,
cmd->length);
if (!host_virt) {
pr_dbg("Failed to map to pdir\n");
resp->hdr.err = -EINVAL;
goto out;
}
}
resp->hdr.err = rdma_rm_alloc_mr(&dev->rdma_dev_res, cmd->pd_handle,
cmd->start, cmd->length, host_virt,
cmd->access_flags, &resp->mr_handle,
&resp->lkey, &resp->rkey);
if (host_virt && !resp->hdr.err) {
munmap(host_virt, cmd->length);
}
out:
pr_dbg("ret=%d\n", resp->hdr.err);
return resp->hdr.err;
}
开发者ID:JayFoxRox,项目名称:xqemu,代码行数:38,代码来源:pvrdma_cmd.c
示例17: ite9133_read_status
static int ite9133_read_status(struct dvb_frontend *fe, fe_status_t * status)
{
struct ite9133_state *state = fe->demodulator_priv;
Dword ret;
Bool locked = 0;
pr_dbg("ite9133_read_status\n");
mutex_lock(&ite_lock);
ret = Demodulator_isLocked(pdemod,&locked);
printk("DVB: lock status is %d\n",locked);
mutex_unlock(&ite_lock);
if(locked==1) {
*status = FE_HAS_LOCK|FE_HAS_SIGNAL|FE_HAS_CARRIER|FE_HAS_VITERBI|FE_HAS_SYNC;
} else {
*status = FE_TIMEDOUT;
}
pr_dbg("ite9133_read_status--\n");
return 0;
}
开发者ID:j1nx,项目名称:tlbb-linux-kernel-m3,代码行数:23,代码来源:itefrontend.c
示例18: his_boot_init
static int __init his_boot_init(void)
{
ssize_t ret = 0;
pr_dbg(KERN_DEBUG "his_boot_init.\r\n");
ret = platform_device_register(&his_boot_dev);
if(ret)
{
pr_dbg("register his_boot device failed. \r\n");
return ret;
}
ret = platform_driver_register(&his_boot_drv);
if(ret)
{
pr_dbg("register his_boot driver failed. \r\n");
platform_device_unregister(&his_boot_dev);
}
return ret;
}
开发者ID:samm-git,项目名称:e3372h-vendor-src,代码行数:23,代码来源:power_on.c
示例19: bsp_power_icc_send_state
/*****************************************************************************
函 数 名 : bsp_power_icc_send_state
功能描述 : C核核间通信函数
输入参数 :
输出参数 : 无
返 回 值 :
调用函数 :
被调函数 :
*****************************************************************************/
static void bsp_power_icc_send_state(void)
{
int ret = 0;
int mode = 0;
u32 icc_channel_id = ICC_CHN_IFC << 16 | IFC_RECV_FUNC_ONOFF;
mode = bsp_start_mode_get();
ret = bsp_icc_send(ICC_CPU_MODEM, icc_channel_id, (u8*)&mode, sizeof(mode));
if (ret != (int)sizeof(mode))
{
pr_dbg("send len(%x) != expected len(%x)\n", ret, sizeof(mode));
}
}
开发者ID:samm-git,项目名称:e3372h-vendor-src,代码行数:23,代码来源:power_on.c
示例20: power_on_time_get
/*****************************************************************************
函 数 名 : power_on_time_get
功能描述 : 记录开机时间.
输入参数 :
输出参数 : 无
返 回 值 :
调用函数 :
被调函数 :
*****************************************************************************/
static void power_on_time_get( void )
{
struct rtc_time tm;
struct timespec ts;
getnstimeofday(&ts);
rtc_time_to_tm((unsigned long)ts.tv_sec, &tm);
power_item_info.time = tm;
pr_dbg("system power on time:%4d-%02d-%02d %02d:%02d:%02d\n",tm.tm_year, tm.tm_mon, \
tm.tm_mday, tm.tm_hour, tm.tm_min, tm.tm_sec);
}
开发者ID:samm-git,项目名称:e3372h-vendor-src,代码行数:23,代码来源:power_on.c
注:本文中的pr_dbg函数示例由纯净天空整理自Github/MSDocs等源码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。 |
请发表评论