2017-11-03 10:28:30 +00:00
|
|
|
// SPDX-License-Identifier: GPL-2.0
|
2008-07-24 09:27:36 +00:00
|
|
|
/*
|
|
|
|
* MUSB OTG driver debug defines
|
|
|
|
*
|
|
|
|
* Copyright 2005 Mentor Graphics Corporation
|
|
|
|
* Copyright (C) 2005-2006 by Texas Instruments
|
|
|
|
* Copyright (C) 2006-2007 Nokia Corporation
|
|
|
|
*/
|
|
|
|
|
|
|
|
#ifndef __MUSB_LINUX_DEBUG_H__
|
|
|
|
#define __MUSB_LINUX_DEBUG_H__
|
|
|
|
|
|
|
|
#define yprintk(facility, format, args...) \
|
|
|
|
do { printk(facility "%s %d: " format , \
|
|
|
|
__func__, __LINE__ , ## args); } while (0)
|
|
|
|
#define WARNING(fmt, args...) yprintk(KERN_WARNING, fmt, ## args)
|
|
|
|
#define INFO(fmt, args...) yprintk(KERN_INFO, fmt, ## args)
|
|
|
|
#define ERR(fmt, args...) yprintk(KERN_ERR, fmt, ## args)
|
|
|
|
|
2016-06-30 17:12:21 +00:00
|
|
|
void musb_dbg(struct musb *musb, const char *fmt, ...);
|
|
|
|
|
2010-03-12 08:29:11 +00:00
|
|
|
#ifdef CONFIG_DEBUG_FS
|
2018-05-29 15:30:48 +00:00
|
|
|
void musb_init_debugfs(struct musb *musb);
|
2011-12-19 14:54:02 +00:00
|
|
|
void musb_exit_debugfs(struct musb *musb);
|
2010-03-12 08:29:11 +00:00
|
|
|
#else
|
2018-05-29 15:30:48 +00:00
|
|
|
static inline void musb_init_debugfs(struct musb *musb)
|
2010-03-12 08:29:11 +00:00
|
|
|
{
|
|
|
|
}
|
|
|
|
static inline void musb_exit_debugfs(struct musb *musb)
|
|
|
|
{
|
|
|
|
}
|
|
|
|
#endif
|
|
|
|
|
2008-07-24 09:27:36 +00:00
|
|
|
#endif /* __MUSB_LINUX_DEBUG_H__ */
|