staging: lustre: ldlm: ldlm_resource.c removed unecessary braces
PATCH 1/3 staging: lustre: ldlm: ldlm_resource.c removed unecessary braces
From: Anil Belur <[email protected]>
- this fixed the "WARNING: braces {} are not necessary for single statement blocks"
--- drivers/staging/lustre/lustre/ldlm/ldlm_resource.c | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-)
drivers/staging/lustre/lustre/ldlm/ldlm_resource.c +2 -4
@@ -854,9 +854,8 @@ void ldlm_namespace_free_prior(struct ldlm_namespace *ns, {int rc; -if (!ns) { +if (!ns)return ; - }spin_lock (&ns->ns_lock); ns->ns_stopping =1 ;
@@ -888,9 +887,8 @@ void ldlm_namespace_free_prior(struct ldlm_namespace *ns,*/ void ldlm_namespace_free_post (struct ldlm_namespace *ns) { -if (!ns) { +if (!ns)return ; - }/* Make sure that nobody can find this ns in its list. */ ldlm_namespace_unregister (ns, ns->ns_client);
Signature · 1 line
1.9.0
PATCH 2/3 staging: lustre: lustre: ldlm: ldlm_lib.c - removed unnecessary braces
From: Anil Belur <[email protected]>
- this change fixes "WARNING: braces {} are not necessary for single statement blocks"
--- drivers/staging/lustre/lustre/ldlm/ldlm_lib.c | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-)
drivers/staging/lustre/lustre/ldlm/ldlm_lib.c +2 -4
@@ -74,9 +74,8 @@ static int import_set_conn(struct obd_import *imp, struct obd_uuid *uuid,if (create) {OBD_ALLOC (imp_conn,sizeof (*imp_conn)); -if (!imp_conn) { +if (!imp_conn)GOTO (out_put, rc = -ENOMEM ); - } }spin_lock (&imp->imp_lock);
@@ -662,9 +661,8 @@ void target_send_reply(struct ptlrpc_request *req, int rc, int fail_id)struct ptlrpc_reply_state *rs;struct obd_export *exp; -if (req->rq_no_reply) { +if (req->rq_no_reply)return ; - } svcpt = req->rq_rqbd->rqbd_svcpt; rs = req->rq_reply_state;
Signature · 1 line
1.9.0
PATCH 3/3 staging: lustre: ldlm: ldlm_lib.c removed unecessary space after function name
In reply to Anil BelurFrom: Anil Belur <[email protected]>
- this fixes "WARNING: space prohibited between function name and open parenthesis '("
--- drivers/staging/lustre/lustre/ldlm/ldlm_lib.c | 24 ++++++++++++------------ 1 file changed, 12 insertions(+), 12 deletions(-)
drivers/staging/lustre/lustre/ldlm/ldlm_lib.c +12 -12
@@ -510,7 +510,7 @@ int client_connect_import(const struct lu_env *env, rc =ptlrpc_connect_import (imp);if (rc !=0 ) { -LASSERT (imp->imp_state ==LUSTRE_IMP_DISCON ); +LASSERT (imp->imp_state ==LUSTRE_IMP_DISCON );GOTO (out_ldlm, rc); }LASSERT (*exp !=NULL && (*exp)->exp_connection);
@@ -668,25 +668,25 @@ void target_send_reply(struct ptlrpc_request *req, int rc, int fail_id) rs = req->rq_reply_state;if (rs ==NULL || !rs->rs_difficult) {/* no notifiers */ -target_send_reply_msg (req, rc, fail_id); +target_send_reply_msg (req, rc, fail_id);return ; }/* must be an export if locks saved */ -LASSERT (req->rq_export !=NULL ); +LASSERT (req->rq_export !=NULL );/* req/reply consistent */ LASSERT (rs->rs_svcpt == svcpt);/* "fresh" reply */ -LASSERT (!rs->rs_scheduled); -LASSERT (!rs->rs_scheduled_ever); -LASSERT (!rs->rs_handled); -LASSERT (!rs->rs_on_net); -LASSERT (rs->rs_export ==NULL ); -LASSERT (list_empty (&rs->rs_obd_list)); -LASSERT (list_empty (&rs->rs_exp_list)); - - exp =class_export_get (req->rq_export); +LASSERT (!rs->rs_scheduled); +LASSERT (!rs->rs_scheduled_ever); +LASSERT (!rs->rs_handled); +LASSERT (!rs->rs_on_net); +LASSERT (rs->rs_export ==NULL ); +LASSERT (list_empty (&rs->rs_obd_list)); +LASSERT (list_empty (&rs->rs_exp_list)); + + exp =class_export_get (req->rq_export);/* disable reply scheduling while I'm setting up */ rs->rs_scheduled =1 ;
Signature · 1 line
1.9.0
Greg KH
maintainerQuoted 9 lines · Anil Belur
From: Anil Belur <[email protected]>
- this fixed the "WARNING: braces {} are not necessary for single statement blocks"
Signed-off-by Anil Belur <[email protected]>--- drivers/staging/lustre/lustre/ldlm/ldlm_resource.c | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-)
Doesn't apply :(
drivers/staging/lustre/lustre/ldlm/ldlm_resource.c | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-)
Quoted 1 line
Doesn't apply :(
Thanks - Its probably because I have included a patch already sent earlier, will redo this set.