本文整理汇总了C++中TRACE_MSG0函数的典型用法代码示例。如果您正苦于以下问题:C++ TRACE_MSG0函数的具体用法?C++ TRACE_MSG0怎么用?C++ TRACE_MSG0使用的例子?那么, 这里精选的函数代码示例或许可以为您提供帮助。
在下文中一共展示了TRACE_MSG0函数的15个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C++代码示例。
示例1: mouse_cf_modinit
/*!
* mouse_cf_modinit() - module init
*
* This is called by the Linux kernel; either when the module is loaded
* if compiled as a module, or during the system intialization if the
* driver is linked into the kernel.
*
* This function will parse module parameters if required and then register
* the mouse driver with the USB Device software.
*
*/
static int mouse_cf_modinit (void)
{
int i;
printk (KERN_INFO "%s: vendor_id: %04x product_id: %04x\n", __FUNCTION__, vendor_id, product_id);
#if !defined(OTG_C99)
mouse_cf_global_init();
mouse_cf_ops_init();
#endif /* defined(OTG_C99) */
MOUSE = otg_trace_obtain_tag();
TRACE_MSG2(MOUSE, "vendor_id: %04x product_id: %04x",vendor_id, product_id);
//if (vendor_id)
// mouse_composite_driver.idVendor = cpu_to_le16(vendor_id);
//if (product_id)
// mouse_composite_driver.idProduct = cpu_to_le16(product_id);
// register as usb function driver
TRACE_MSG0(MOUSE, "REGISTER COMPOSITE");
THROW_IF (usbd_register_composite_function (&mouse_composite_driver,
"mouse-random-cf", NULL, mouse_arg_list, NULL), error);
TRACE_MSG0(MOUSE, "REGISTER FINISHED");
CATCH(error) {
otg_trace_invalidate_tag(MOUSE);
return -EINVAL;
}
return 0;
}
示例2: zasevb_isp1301_bh
/*!
* zasevb_isp1301_bh()- call isp1301 bottom half handler
* @param arg
* This is a wrapper to the isp1301 bottom half handler, it
* re-enables the gpio interrupt after processing complete.
*/
void zasevb_isp1301_bh(void *arg)
{
TRACE_MSG0(TCD, "ZASEVB GPIO INTERRUPT: ISP1301_BH");
isp1301_bh(arg);
TRACE_MSG0(TCD, "ZASEVB GPIO INTERRUPT: REENABLE");
gpio_config_int_en(ZGPIO_PORT, ZGPIO_PIN, TRUE);
}
示例3: pmic_otg_wakeup
/*! pmic_otg_wakeup - called to wake up pmic_otg_task
*/
void pmic_otg_wakeup(void)
{
TRACE_MSG0(REMOVE_TCD, "start");
//SCHEDULE_WORK(pmic_otg_wq);
otg_up_work(pmic_otg_task);
TRACE_MSG0(REMOVE_TCD, "finsih");
}
示例4: mxc_gptcr_timer_int_hndlr
/*!
* mxc_gptcr_timer_int_hndlr() - timer interrupt
* @param irq
* @param dev_id
* @param regs
*/
irqreturn_t mxc_gptcr_timer_int_hndlr (int irq, void *dev_id, struct pt_regs *regs)
{
u32 gptsr = *_reg_GPT_GPTSR;
*_reg_GPT_GPTIR &= ~(0x04);
if (gptsr & (0x01 << 2)){
TRACE_MSG7(OCD, "cnt: %08x match: %08x gptsr: %08x GPTCNT: %08x GPTCR: %08x GPTSR: %08x GPTOCR3: %08x\n",
mxc_gptcr_ticks_set, mxc_gptcr_match_set, gptsr,
*_reg_GPT_GPTCNT, *_reg_GPT_GPTCR, *_reg_GPT_GPTSR, *_reg_GPT_GPTOCR3);
*_reg_GPT_GPTCR &= ~(0x7 << 26);
*_reg_GPT_GPTOCR3 = 0;
TRACE_MSG0(OCD, "OCM3");
TRACE_MSG1(OCD, "active: %x", mxc_gptcr_active);
if (mxc_gptcr_active) {
TRACE_MSG0(OCD, "calling otg_event");
mxc_gptcr_active = 0;
otg_event(ocd_instance->otg, TMOUT, OCD, "TMOUT");
}
else {
TRACE_MSG0(OCD, "skipping otg_event");
}
*_reg_GPT_GPTSR |= 0x4;
return IRQ_HANDLED;
}
if (!mxc_shared_int)
*_reg_GPT_GPTIR |= 0x4;
return IRQ_NONE;
}
示例5: generic_cl_modinit
/*!
* generic_cl_modinit() - module init
*
* This is called by the Linux kernel; either when the module is loaded
* if compiled as a module, or during the system intialization if the
* driver is linked into the kernel.
*
* This function will parse module parameters if required and then register
* the generic driver with the USB Device software.
*
*/
static int generic_cl_modinit (void)
{
#if !defined(OTG_C99)
/*! function_ops - operations table for the USB Device Core
*/
ZERO(generic_function_ops);
generic_function_ops.device_request=generic_cl_device_request; /*! called for each received device request */
/*! class_driver - USB Device Core function driver definition
*/
ZERO(generic_class_driver);
generic_class_driver.driver.name = "generic-class"; /*! driver name */
generic_class_driver.driver.fops = &generic_function_ops; /*! operations table */
#endif /* defined(OTG_C99) */
GCLASS = otg_trace_obtain_tag(NULL, "generic-cf");
// register as usb function driver
TRACE_MSG0(GCLASS, "REGISTER CLASS");
THROW_IF (usbd_register_class_function (&generic_class_driver, "generic-class", NULL), error);
TRACE_MSG0(GCLASS, "REGISTER FINISHED");
CATCH(error) {
generic_cl_modexit();
return -EINVAL;
}
return 0;
}
示例6: mxc_pmic_dm_pulldown_func
/*! mxc_pmic_dm_pulldown_func - used to enable or disable peripheral connecting to bus
*
* @param otg - otg instance
* @param flag - enable/disable flag
*/
void mxc_pmic_dm_pulldown_func(struct otg_instance *otg, u8 flag)
{
struct tcd_instance *tcd = (struct tcd_instance *)otg->tcd;
//TRACE_MSG0(tcd->TAG, "--");
switch (flag) {
case SET:
TRACE_MSG0(tcd->TAG, "MC13783_LOC_CONN SET - Set DM PULLDOWN");
// global_flag |= UDM_FLAG_SET;
global_flag_array[end_flag] = UDM_FLAG_SET;
pmic_bh_wakeup();
// mc13783_convity_set_pull_down_switch(PD_UDM_15, TRUE);
break;
case RESET:
TRACE_MSG0(tcd->TAG, "MC13783_LOC_CONN RESET - Clr DM PULLDOWN");
// global_flag |= UDM_FLAG_RESET;
global_flag_array[end_flag] = UDM_FLAG_RESET;
pmic_bh_wakeup();
// mc13783_convity_set_pull_down_switch(PD_UDM_15, TRUE);
break;
}
if (end_flag++ > 15)
end_flag = 0;
}
示例7: otg_pci_isr
/*!
* otg_pci_isr() - interrupt service handler
*/
irqreturn_t otg_pci_isr(int irq, void *data, struct pt_regs *r)
{
struct pci_dev *pci_dev = data;
struct otg_dev *otg_dev = pci_get_drvdata(pci_dev);
int i;
/* XXX spinlock */
RETURN_IRQ_HANDLED_UNLESS(otg_dev);
TRACE_MSG0(otg_dev->PCI, "---------------------------------------- Start");
for (i = OTG_DRIVER_TCD; i < OTG_DRIVER_TYPES; i++) {
struct otg_driver *otg_driver;
otg_driver = otg_dev->otg_pci_driver->drivers[i];
CONTINUE_UNLESS(otg_driver);
TRACE_MSG2(otg_dev->PCI, "try %s %d", otg_driver->name, i);
CONTINUE_UNLESS(otg_driver->isr);
RETURN_IRQ_HANDLED_IF_IRQ_HANDLED (otg_driver->isr(otg_dev, data));
TRACE_MSG2(otg_dev->PCI, "not handled by %s %d", otg_driver->name, i);
}
TRACE_MSG2(otg_dev->PCI, "try %s %d", otg_dev->otg_pci_driver->name, i);
if (otg_dev->otg_pci_driver->isr)
RETURN_IRQ_HANDLED_IF_IRQ_HANDLED (otg_dev->otg_pci_driver->isr(otg_dev, data));
/* XXX spinlock */
TRACE_MSG0(otg_dev->PCI, "---------------------------------------- IRQ_NONE ----");
return IRQ_NONE;
}
示例8: net_fd_recv_urb2
/*! net_fd_recv_urb2 - callback to process a received URB
*
* @param urb - pointer to copy of received urb,
* @param rc - receiving urb result code
*
* @return non-zero for failure.
*/
int net_fd_recv_urb2(struct usbd_urb *urb, int rc)
{
struct usbd_function_instance *function_instance = urb->function_instance;
struct usb_network_private *npd = function_instance->privdata;
int hs = usbd_high_speed(function_instance);
int endpoint_index = urb->endpoint_index;
#ifndef CONFIG_OTG_NETWORK_DOUBLE_OUT
int recv_index = 0;
#else /* CONFIG_OTG_NETWORK_DOUBLE_OUT */
int recv_index = (endpoint_index == BULK_OUT_A) ? 0 : 1;
#endif /* CONFIG_OTG_NETWORK_DOUBLE_OUT */
int alloc_length = usbd_endpoint_transferSize(function_instance, endpoint_index, hs);
int status = urb->status;
void *os_data;
u8 *os_buffer;
if (TRACE_VERY_VERBOSE) {
TRACE_MSG4(NTT, "status: %d actual_length: %d bus status: %d device_state: %d",
urb->status, urb->actual_length,
usbd_get_device_status(function_instance), usbd_get_device_state(function_instance)
);
TRACE_NRECV(NTT, 32, urb->buffer);
TRACE_MSG0(NTT, "--");
TRACE_RECV(NTT, urb->actual_length, urb->buffer);
}
otg_atomic_dec(&npd->recv_urbs_started[recv_index]);
/* process the data */
if (urb->status == USBD_URB_OK)
npd->net_recv_urb(urb, rc);
if (urb->status == USBD_URB_CANCELLED)
net_os_dealloc_buffer(function_instance, urb->function_privdata, urb->buffer);
/* disconnect os_data buffer from urb */
urb->function_privdata = NULL;
urb->buffer = NULL;
urb->function_instance = NULL;
urb->status = USBD_URB_OK;
usbd_free_urb(urb);
if ((USBD_OK == usbd_get_device_status(function_instance)) &&
(STATE_CONFIGURED == usbd_get_device_state(function_instance))) {
blan_start_recv(function_instance);
}
else {
TRACE_MSG0(NTT, "NOT RESTARTING");
}
return 0;
}
示例9: zasevb_modexit
/*!
* zasevb_modexit() - This is used as module exit, and as cleanup if modinit fails.
*/
static void zasevb_modexit (void)
{
struct otg_instance *otg = ocd_instance->otg;
//struct pcd_instance *pcd = (struct pcd_instance *)otg->pcd;
//struct usbd_bus_instance *bus= pcd->bus;
TRACE_MSG0(ZAS, "Modules exit!");
if (otg) otg_exit(otg);
mxc_procfs_exit();
/* Disable GPT
*/
#if defined(CONFIG_OTG_GPTR)
mxc_gptcr_mod_exit();
#endif /* defined(CONFIG_OTG_GPTR) */
#if defined(CONFIG_OTG_HRT)
mxc_hrt_mod_exit();
#endif /* defined(CONFIG_OTG_GPTR) */
#ifdef OTG_USE_I2C
TRACE_MSG0(ZAS, "0. I2C");
i2c_mod_exit(otg);
#endif
#if !defined(CONFIG_USB_HOST)
if (pcd_ops.mod_exit) pcd_ops.mod_exit(otg);
REMOVE_pcd_instance = otg_set_pcd_ops(otg, NULL);
#else /* !defined(CONFIG_USB_HOST) */
printk(KERN_INFO"%s: PCD DRIVER N/A\n", __FUNCTION__);
#endif /* !defined(CONFIG_USB_HOST) */
#if defined(CONFIG_OTG_USB_HOST) || defined(CONFIG_OTG_USB_PERIPHERAL_OR_HOST)|| defined(CONFIG_OTG_DEVICE)
if (hcd_ops.mod_exit) hcd_ops.mod_exit(otg);
hcd_instance = otg_set_hcd_ops(otg, NULL);
//HCD = otg_trace_invalidate_tag(HCD);
#else /* defined(CONFIG_OTG_USB_HOST) || defined(CONFIG_OTG_USB_PERIPHERAL_OR_HOST)|| defined(CONFIG_OTG_DEVICE) */
printk(KERN_INFO"%s: HCD DRIVER N/A\n", __FUNCTION__);
#endif /* defined(CONFIG_OTG_USB_HOST) || defined(CONFIG_OTG_USB_PERIPHERAL_OR_HOST)|| defined(CONFIG_OTG_DEVICE) */
if (tcd_ops.mod_exit) tcd_ops.mod_exit(otg);
printk(KERN_INFO"%s: set_tcd_ops\n", __FUNCTION__);
REMOVE_tcd_instance = otg_set_tcd_ops(otg, NULL);
//REMOVE_TCD = otg_trace_invalidate_tag(REMOVE_TCD);
if (ocd_ops.mod_exit) ocd_ops.mod_exit(otg);
ocd_instance = otg_set_ocd_ops(otg, NULL);
ZAS = otg_trace_invalidate_tag(ZAS);
otg_destroy(otg);
}
示例10: TRACE_MSG0
/*!
* zasevb_isp1301_bh()- call isp1301 bottom half handler
* @param arg
* This is a wrapper to the isp1301 bottom half handler, it
* re-enables the gpio interrupt after processing complete.
*/
void *zasevb_isp1301_bh(void *arg)
{
TRACE_MSG0(REMOVE_TCD, "ZASEVB GPIO INTERRUPT: ISP1301_BH");
isp1301_bh(arg);
TRACE_MSG0(REMOVE_TCD, "ZASEVB GPIO INTERRUPT: REENABLE");
if (zasevb_int_disabled) {
zasevb_int_disabled = FALSE;
enable_irq(IOMUX_TO_IRQ(PIN_GPIO2));
}
return 0;
}
示例11: mxc_mc13783_mx21_vbus_drain_func
/*! mxc_mc13783_mx21_vbus_drain - used to enable Vbus discharge
*/
void mxc_mc13783_mx21_vbus_drain_func(struct otg_instance *otg, u8 flag)
{
struct tcd_instance *tcd = otg->tcd;
//TRACE_MSG0(TCD, "--");
switch (flag) {
case SET:
TRACE_MSG0(TCD, "OUTPUT: TCD_DISCHRG_VBUS_SET");
break;
case RESET:
TRACE_MSG0(TCD, "OUTPUT: TCD_DISCHRG_VBUS_RESET");
break;
}
}
示例12: mxc_mc13783_tcd_en
/*! mxc_mc13783_tcd_en() - used to enable
*
*/
void mxc_mc13783_tcd_en(struct otg_instance *otg, u8 flag)
{
switch (flag) {
case SET:
case PULSE:
TRACE_MSG0(TCD, "SET/PULSE");
mc13783_otg_wakeup ();
break;
case RESET:
TRACE_MSG0(TCD, "RESET");
break;
}
}
示例13: mxc_pmic_dp_det_func
/*! mxc_pmic_dp_det_func - used to enable or disable D+ detect
*
* @param otg - otg instance
* @param flag - enable/disable flag
*/
void mxc_pmic_dp_det_func(struct otg_instance *otg, u8 flag)
{
struct tcd_instance *tcd = (struct tcd_instance *)otg->tcd;
//TRACE_MSG0(tcd->TAG, "--");
switch (flag) {
case SET:
TRACE_MSG0(tcd->TAG, "setting DP_HI detect");
break;
case RESET:
TRACE_MSG0(tcd->TAG, "reseting DP_HI detect");
break;
}
}
示例14: mxc_mc13783_audio_func
/*! mxc_mc13783_audio_func - used to enable or disable Carkit Interrupt
*
*/
void mxc_mc13783_audio_func(struct otg_instance *otg, u8 flag)
{
struct tcd_instance *tcd = (struct tcd_instance *)otg->tcd;
//TRACE_MSG0(TCD, "--");
switch (flag) {
case SET:
TRACE_MSG0(TCD, "SET AUDIO_EN");
break;
case RESET:
TRACE_MSG0(TCD, "RESET AUDIO_EN");
break;
}
}
示例15: mxc_mc13783_bdis_acon_func
/*! mxc_mc13783_bdis_acon_func - used to enable or disable auto a-connect
*
*/
void mxc_mc13783_bdis_acon_func(struct otg_instance *otg, u8 flag)
{
struct tcd_instance *tcd = (struct tcd_instance *)otg->tcd;
//TRACE_MSG0(TCD, "--");
switch (flag) {
case SET:
TRACE_MSG0(TCD, "setting BDIS ACON");
break;
case RESET:
TRACE_MSG0(TCD, "reseting BDIS ACON");
break;
}
}