staging/lustre: use __printf(...) instead of __attribute__(format(__printf, ...))
authorMario J. Rugiero <mrugiero@gmail.com>
Tue, 10 Mar 2015 15:02:03 +0000 (12:02 -0300)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Wed, 18 Mar 2015 09:41:29 +0000 (10:41 +0100)
Replace uses of __attribute__(format(__printf,...)) by __printf(...), as suggested by checkpatch.

Signed-off-by: Mario J. Rugiero <mrugiero@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
drivers/staging/lustre/include/linux/libcfs/libcfs_debug.h
drivers/staging/lustre/lustre/include/lu_object.h
drivers/staging/lustre/lustre/include/lustre_dlm.h
drivers/staging/lustre/lustre/include/lustre_net.h

index 840dd1bde29333e20cb38afcd4f5a2f4130528f0..8251ac932e37b22110c0cf5deacde6c53ecc4e78 100644 (file)
@@ -244,12 +244,12 @@ do {                                                                      \
 
 int libcfs_debug_msg(struct libcfs_debug_msg_data *msgdata,
                            const char *format1, ...)
-       __attribute__ ((format (printf, 2, 3)));
+       __printf(2, 3);
 
 int libcfs_debug_vmsg2(struct libcfs_debug_msg_data *msgdata,
                              const char *format1,
                              va_list args, const char *format2, ...)
-       __attribute__ ((format (printf, 4, 5)));
+       __printf(4, 5);
 
 /* other external symbols that tracefile provides: */
 int cfs_trace_copyin_string(char *knl_buffer, int knl_buffer_nob,
index 2ddb2b054d8d5ac618ebaff9765990f6ed7da36f..c8cc48f0002690f130a1b246fdfb3870d1c99781 100644 (file)
@@ -192,7 +192,7 @@ struct lu_object_conf {
  */
 typedef int (*lu_printer_t)(const struct lu_env *env,
                            void *cookie, const char *format, ...)
-       __attribute__ ((format (printf, 3, 4)));
+       __printf(3, 4);
 
 /**
  * Operations specific for particular lu_object.
index 83bc0a9d7d4cd380c7779f9691c31989543d50d5..bac9902b56bbf48a4840116fe9efd154acb36a06 100644 (file)
@@ -1075,7 +1075,7 @@ extern char *ldlm_it2str(int it);
 void _ldlm_lock_debug(struct ldlm_lock *lock,
                      struct libcfs_debug_msg_data *data,
                      const char *fmt, ...)
-       __attribute__ ((format (printf, 3, 4)));
+       __printf(3, 4);
 
 /**
  * Rate-limited version of lock printing function.
index 36396d1c94dc9eecc81e4f2446462ff23122e6c8..e2805bd1acf1070b176b22f974515dd567f9e2a9 100644 (file)
@@ -1673,7 +1673,7 @@ ptlrpc_rqphase2str(struct ptlrpc_request *req)
 
 void _debug_req(struct ptlrpc_request *req,
                struct libcfs_debug_msg_data *data, const char *fmt, ...)
-       __attribute__ ((format (printf, 3, 4)));
+       __printf(3, 4);
 
 /**
  * Helper that decides if we need to print request according to current debug