blob: fc4b1a5dd75531739bdd0d856e2f85782c3fe356 [file] [log] [blame]
Linus Torvalds1da177e2005-04-16 15:20:36 -07001/*
2 * Defines some debug macros for smbfs.
3 */
4
5/* This makes a dentry parent/child name pair. Useful for debugging printk's */
6#define DENTRY_PATH(dentry) \
7 (dentry)->d_parent->d_name.name,(dentry)->d_name.name
8
9/*
10 * safety checks that should never happen ???
11 * these are normally enabled.
12 */
13#ifdef SMBFS_PARANOIA
Harvey Harrison8e24eea2008-04-30 00:55:09 -070014# define PARANOIA(f, a...) printk(KERN_NOTICE "%s: " f, __func__ , ## a)
Linus Torvalds1da177e2005-04-16 15:20:36 -070015#else
16# define PARANOIA(f, a...) do { ; } while(0)
17#endif
18
19/* lots of debug messages */
20#ifdef SMBFS_DEBUG_VERBOSE
Harvey Harrison8e24eea2008-04-30 00:55:09 -070021# define VERBOSE(f, a...) printk(KERN_DEBUG "%s: " f, __func__ , ## a)
Linus Torvalds1da177e2005-04-16 15:20:36 -070022#else
23# define VERBOSE(f, a...) do { ; } while(0)
24#endif
25
26/*
27 * "normal" debug messages, but not with a normal DEBUG define ... way
28 * too common name.
29 */
30#ifdef SMBFS_DEBUG
Harvey Harrison8e24eea2008-04-30 00:55:09 -070031#define DEBUG1(f, a...) printk(KERN_DEBUG "%s: " f, __func__ , ## a)
Linus Torvalds1da177e2005-04-16 15:20:36 -070032#else
33#define DEBUG1(f, a...) do { ; } while(0)
34#endif