public inbox for linux-kernel@vger.kernel.org
 help / color / mirror / Atom feed
* [PATCH 1/3] staging: lustre: ldlm: ldlm_resource.c removed unecessary braces
@ 2014-06-19 16:01 Anil Belur
  2014-06-19 16:01 ` [PATCH 2/3] staging: lustre: lustre: ldlm: ldlm_lib.c - removed unnecessary braces Anil Belur
                   ` (2 more replies)
  0 siblings, 3 replies; 5+ messages in thread
From: Anil Belur @ 2014-06-19 16:01 UTC (permalink / raw)
  To: andreas.dilger, oleg.drokin, gregkh
  Cc: linux-kernel, hpdd-discuss, Anil Belur

From: Anil Belur <askb23@gmail.com>

- this fixed the "WARNING: braces {} are not necessary for
  single statement blocks"

Signed-off-by: Anil Belur <askb23@gmail.com>
---
 drivers/staging/lustre/lustre/ldlm/ldlm_resource.c | 6 ++----
 1 file changed, 2 insertions(+), 4 deletions(-)

diff --git a/drivers/staging/lustre/lustre/ldlm/ldlm_resource.c b/drivers/staging/lustre/lustre/ldlm/ldlm_resource.c
index c55d72f..e5171da 100644
--- a/drivers/staging/lustre/lustre/ldlm/ldlm_resource.c
+++ b/drivers/staging/lustre/lustre/ldlm/ldlm_resource.c
@@ -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);
-- 
1.9.0


^ permalink raw reply related	[flat|nested] 5+ messages in thread

* [PATCH 2/3] staging: lustre: lustre: ldlm: ldlm_lib.c - removed unnecessary braces
  2014-06-19 16:01 [PATCH 1/3] staging: lustre: ldlm: ldlm_resource.c removed unecessary braces Anil Belur
@ 2014-06-19 16:01 ` Anil Belur
  2014-06-19 16:01 ` [PATCH 3/3] staging: lustre: ldlm: ldlm_lib.c removed unecessary space after function name Anil Belur
  2014-06-20  0:23 ` [PATCH 1/3] staging: lustre: ldlm: ldlm_resource.c removed unecessary braces Greg KH
  2 siblings, 0 replies; 5+ messages in thread
From: Anil Belur @ 2014-06-19 16:01 UTC (permalink / raw)
  To: andreas.dilger, oleg.drokin, gregkh
  Cc: linux-kernel, hpdd-discuss, Anil Belur

From: Anil Belur <askb23@gmail.com>

- this change fixes "WARNING: braces {} are not necessary for single
  statement blocks"

Signed-off-by: Anil Belur <askb23@gmail.com>
---
 drivers/staging/lustre/lustre/ldlm/ldlm_lib.c | 6 ++----
 1 file changed, 2 insertions(+), 4 deletions(-)

diff --git a/drivers/staging/lustre/lustre/ldlm/ldlm_lib.c b/drivers/staging/lustre/lustre/ldlm/ldlm_lib.c
index 8bb5915..5d69af5 100644
--- a/drivers/staging/lustre/lustre/ldlm/ldlm_lib.c
+++ b/drivers/staging/lustre/lustre/ldlm/ldlm_lib.c
@@ -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;
-- 
1.9.0


^ permalink raw reply related	[flat|nested] 5+ messages in thread

* [PATCH 3/3] staging: lustre: ldlm: ldlm_lib.c removed unecessary space after function name
  2014-06-19 16:01 [PATCH 1/3] staging: lustre: ldlm: ldlm_resource.c removed unecessary braces Anil Belur
  2014-06-19 16:01 ` [PATCH 2/3] staging: lustre: lustre: ldlm: ldlm_lib.c - removed unnecessary braces Anil Belur
@ 2014-06-19 16:01 ` Anil Belur
  2014-06-20  0:23 ` [PATCH 1/3] staging: lustre: ldlm: ldlm_resource.c removed unecessary braces Greg KH
  2 siblings, 0 replies; 5+ messages in thread
From: Anil Belur @ 2014-06-19 16:01 UTC (permalink / raw)
  To: andreas.dilger, oleg.drokin, gregkh
  Cc: linux-kernel, hpdd-discuss, Anil Belur

From: Anil Belur <askb23@gmail.com>

- this fixes "WARNING: space prohibited between function name and open
  parenthesis '("

Signed-off-by: Anil Belur <askb23@gmail.com>
---
 drivers/staging/lustre/lustre/ldlm/ldlm_lib.c | 24 ++++++++++++------------
 1 file changed, 12 insertions(+), 12 deletions(-)

diff --git a/drivers/staging/lustre/lustre/ldlm/ldlm_lib.c b/drivers/staging/lustre/lustre/ldlm/ldlm_lib.c
index 5d69af5..d8ad808 100644
--- a/drivers/staging/lustre/lustre/ldlm/ldlm_lib.c
+++ b/drivers/staging/lustre/lustre/ldlm/ldlm_lib.c
@@ -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;
-- 
1.9.0


^ permalink raw reply related	[flat|nested] 5+ messages in thread

* Re: [PATCH 1/3] staging: lustre: ldlm: ldlm_resource.c removed unecessary braces
  2014-06-19 16:01 [PATCH 1/3] staging: lustre: ldlm: ldlm_resource.c removed unecessary braces Anil Belur
  2014-06-19 16:01 ` [PATCH 2/3] staging: lustre: lustre: ldlm: ldlm_lib.c - removed unnecessary braces Anil Belur
  2014-06-19 16:01 ` [PATCH 3/3] staging: lustre: ldlm: ldlm_lib.c removed unecessary space after function name Anil Belur
@ 2014-06-20  0:23 ` Greg KH
  2014-06-20  5:02   ` Anil Shashikumar Belur
  2 siblings, 1 reply; 5+ messages in thread
From: Greg KH @ 2014-06-20  0:23 UTC (permalink / raw)
  To: Anil Belur; +Cc: andreas.dilger, oleg.drokin, linux-kernel, hpdd-discuss

On Fri, Jun 20, 2014 at 02:01:46AM +1000, Anil Belur wrote:
> From: Anil Belur <askb23@gmail.com>
> 
> - this fixed the "WARNING: braces {} are not necessary for
>   single statement blocks"
> 
> Signed-off-by: Anil Belur <askb23@gmail.com>
> ---
>  drivers/staging/lustre/lustre/ldlm/ldlm_resource.c | 6 ++----
>  1 file changed, 2 insertions(+), 4 deletions(-)

Doesn't apply :(

^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: [PATCH 1/3] staging: lustre: ldlm: ldlm_resource.c removed unecessary braces
  2014-06-20  0:23 ` [PATCH 1/3] staging: lustre: ldlm: ldlm_resource.c removed unecessary braces Greg KH
@ 2014-06-20  5:02   ` Anil Shashikumar Belur
  0 siblings, 0 replies; 5+ messages in thread
From: Anil Shashikumar Belur @ 2014-06-20  5:02 UTC (permalink / raw)
  To: Greg KH; +Cc: andreas.dilger, oleg.drokin, linux-kernel, hpdd-discuss


 drivers/staging/lustre/lustre/ldlm/ldlm_resource.c | 6 ++----
 1 file changed, 2 insertions(+), 4 deletions(-)

> Doesn't apply :(
Thanks - Its probably because I have included a patch already sent
earlier, will redo this set.

^ permalink raw reply	[flat|nested] 5+ messages in thread

end of thread, other threads:[~2014-06-20  5:02 UTC | newest]

Thread overview: 5+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2014-06-19 16:01 [PATCH 1/3] staging: lustre: ldlm: ldlm_resource.c removed unecessary braces Anil Belur
2014-06-19 16:01 ` [PATCH 2/3] staging: lustre: lustre: ldlm: ldlm_lib.c - removed unnecessary braces Anil Belur
2014-06-19 16:01 ` [PATCH 3/3] staging: lustre: ldlm: ldlm_lib.c removed unecessary space after function name Anil Belur
2014-06-20  0:23 ` [PATCH 1/3] staging: lustre: ldlm: ldlm_resource.c removed unecessary braces Greg KH
2014-06-20  5:02   ` Anil Shashikumar Belur

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox