staging: lustre: moved extern declarations to a header
authorAnton Gerasimov <anton.gerasimov@openmailbox.org>
Wed, 23 Sep 2015 21:02:28 +0000 (00:02 +0300)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Tue, 29 Sep 2015 01:58:40 +0000 (03:58 +0200)
This patch moves declarations of variables used in several files
across the ptlrpc module from source files to a local header.

Signed-off-by: Anton Gerasimov <anton.gerasimov@openmailbox.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
drivers/staging/lustre/lustre/ptlrpc/lproc_ptlrpc.c
drivers/staging/lustre/lustre/ptlrpc/nrs.c
drivers/staging/lustre/lustre/ptlrpc/ptlrpc_internal.h
drivers/staging/lustre/lustre/ptlrpc/ptlrpc_module.c

index 9a10baf711b099bbd0fdd1d133beeafa4a17b19d..2b88aef3201f799a6a9b896a66521bd9a2283c4e 100644 (file)
@@ -420,7 +420,6 @@ LUSTRE_RW_ATTR(threads_max);
  * \addtogoup nrs
  * @{
  */
-extern struct nrs_core nrs_core;
 
 /**
  * Translates \e ptlrpc_nrs_pol_state values to human-readable strings.
index d37cdd5ac58065481ec7403c7d9962cef90df1c4..40696f3678cfc9d8caa2409a645ae1cfeea941be 100644 (file)
@@ -49,7 +49,6 @@
 
 /* XXX: This is just for liblustre. Remove the #if defined directive when the
  * "cfs_" prefix is dropped from cfs_list_head. */
-extern struct list_head ptlrpc_all_services;
 
 /**
  * NRS core object.
index 34c7e28afdafc22e2a4ca2945f9db436efc8fd36..4e35b14a1315cb844da3ee72e2e8cdacaf340fe2 100644 (file)
@@ -47,6 +47,10 @@ struct ldlm_res_id;
 struct ptlrpc_request_set;
 extern int test_req_buffer_pressure;
 extern struct mutex ptlrpc_all_services_mutex;
+extern struct list_head ptlrpc_all_services;
+
+extern struct mutex ptlrpcd_mutex;
+extern struct mutex pinger_mutex;
 
 int ptlrpc_start_thread(struct ptlrpc_service_part *svcpt, int wait);
 /* ptlrpcd.c */
@@ -110,6 +114,8 @@ struct nrs_core {
 
 };
 
+extern struct nrs_core nrs_core;
+
 int ptlrpc_service_nrs_setup(struct ptlrpc_service *svc);
 void ptlrpc_service_nrs_cleanup(struct ptlrpc_service *svc);
 
index 9985fb61f63019a1f0656981a036b1dae861f1e5..d12e95bc9dcebf5c484467ec2214be3a2b79f436 100644 (file)
@@ -48,8 +48,6 @@ extern spinlock_t ptlrpc_last_xid_lock;
 #if RS_DEBUG
 extern spinlock_t ptlrpc_rs_debug_lock;
 #endif
-extern struct mutex pinger_mutex;
-extern struct mutex ptlrpcd_mutex;
 
 static int __init ptlrpc_init(void)
 {