[Open-FCoE] [PATCH 9/9 v2] libfc: Remove unused FC_DBG macro

Robert Love robert.w.love at intel.com
Fri Apr 3 17:59:08 UTC 2009


This patch also removes the final two uses of this macro.
The last two uses are in inline functions and are unnecessary.
If statements are needed to show invalid op codes those
statements can be outside of the inline functions as the
inline's return value is checked.

Signed-off-by: Robert Love <robert.w.love at intel.com>
---

 include/scsi/fc_encode.h |    2 --
 include/scsi/libfc.h     |   12 ------------
 2 files changed, 0 insertions(+), 14 deletions(-)

diff --git a/include/scsi/fc_encode.h b/include/scsi/fc_encode.h
index 6300f55..a0ff61c 100644
--- a/include/scsi/fc_encode.h
+++ b/include/scsi/fc_encode.h
@@ -107,7 +107,6 @@ static inline int fc_ct_fill(struct fc_lport *lport, struct fc_frame *fp,
 		break;
 
 	default:
-		FC_DBG("Invalid op code %x \n", op);
 		return -EINVAL;
 	}
 	*r_ctl = FC_RCTL_DD_UNSOL_CTL;
@@ -298,7 +297,6 @@ static inline int fc_els_fill(struct fc_lport *lport, struct fc_rport *rport,
 		break;
 
 	default:
-		FC_DBG("Invalid op code %x \n", op);
 		return -EINVAL;
 	}
 
diff --git a/include/scsi/libfc.h b/include/scsi/libfc.h
index 3afa005..bceb00b 100644
--- a/include/scsi/libfc.h
+++ b/include/scsi/libfc.h
@@ -34,18 +34,6 @@
 
 #include <scsi/fc_frame.h>
 
-#define LIBFC_DEBUG
-
-#ifdef LIBFC_DEBUG
-/* Log messages */
-#define FC_DBG(fmt, args...)						\
-	do {								\
-		printk(KERN_INFO "%s " fmt, __func__, ##args);		\
-	} while (0)
-#else
-#define FC_DBG(fmt, args...)
-#endif
-
 #define FC_LIBFC_LOGGING 0x01 /* General logging, not categorized */
 #define FC_LPORT_LOGGING 0x02 /* lport layer logging */
 #define FC_DISC_LOGGING  0x04 /* discovery layer logging */




More information about the devel mailing list