smb_debug.h 890 B

12345678910111213141516171819202122232425262728293031323334
  1. /*
  2. * Defines some debug macros for smbfs.
  3. */
  4. /* This makes a dentry parent/child name pair. Useful for debugging printk's */
  5. #define DENTRY_PATH(dentry) \
  6. (dentry)->d_parent->d_name.name,(dentry)->d_name.name
  7. /*
  8. * safety checks that should never happen ???
  9. * these are normally enabled.
  10. */
  11. #ifdef SMBFS_PARANOIA
  12. # define PARANOIA(f, a...) printk(KERN_NOTICE "%s: " f, __FUNCTION__ , ## a)
  13. #else
  14. # define PARANOIA(f, a...) do { ; } while(0)
  15. #endif
  16. /* lots of debug messages */
  17. #ifdef SMBFS_DEBUG_VERBOSE
  18. # define VERBOSE(f, a...) printk(KERN_DEBUG "%s: " f, __FUNCTION__ , ## a)
  19. #else
  20. # define VERBOSE(f, a...) do { ; } while(0)
  21. #endif
  22. /*
  23. * "normal" debug messages, but not with a normal DEBUG define ... way
  24. * too common name.
  25. */
  26. #ifdef SMBFS_DEBUG
  27. #define DEBUG1(f, a...) printk(KERN_DEBUG "%s: " f, __FUNCTION__ , ## a)
  28. #else
  29. #define DEBUG1(f, a...) do { ; } while(0)
  30. #endif