[<prev] [next>] [thread-next>] [day] [month] [year] [list]
Message-Id: <1354620448-14317-1-git-send-email-dinggnu@gmail.com>
Date: Tue, 4 Dec 2012 11:26:59 +0000
From: Cong Ding <dinggnu@...il.com>
To: Benoit Cousson <b-cousson@...com>, Aneesh V <aneesh@...com>,
Santosh Shilimkar <santosh.shilimkar@...com>,
Greg Kroah-Hartman <gregkh@...uxfoundation.org>,
Grant Likely <grant.likely@...retlab.ca>,
linux-kernel@...r.kernel.org
Cc: Cong Ding <dinggnu@...il.com>
Subject: [PATCH] memory: of_memory.c: remove unnecessary initialization
the initialization of variable ret is unnecessary, we can remove it while save
one time "or" operation.
Signed-off-by: Cong Ding <dinggnu@...il.com>
---
drivers/memory/of_memory.c | 4 ++--
1 files changed, 2 insertions(+), 2 deletions(-)
diff --git a/drivers/memory/of_memory.c b/drivers/memory/of_memory.c
index 6007435..c59a946 100644
--- a/drivers/memory/of_memory.c
+++ b/drivers/memory/of_memory.c
@@ -30,14 +30,14 @@
const struct lpddr2_min_tck *of_get_min_tck(struct device_node *np,
struct device *dev)
{
- int ret = 0;
+ int ret;
struct lpddr2_min_tck *min;
min = devm_kzalloc(dev, sizeof(*min), GFP_KERNEL);
if (!min)
goto default_min_tck;
- ret |= of_property_read_u32(np, "tRPab-min-tck", &min->tRPab);
+ ret = of_property_read_u32(np, "tRPab-min-tck", &min->tRPab);
ret |= of_property_read_u32(np, "tRCD-min-tck", &min->tRCD);
ret |= of_property_read_u32(np, "tWR-min-tck", &min->tWR);
ret |= of_property_read_u32(np, "tRASmin-min-tck", &min->tRASmin);
--
1.7.4.5
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/
Powered by blists - more mailing lists