mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: Kishon Vijay Abraham I <kishon@ti.com>
To: <gregkh@linuxfoundation.org>, <linux-kernel@vger.kernel.org>
Cc: <kishon@ti.com>
Subject: [PATCH 3/4] phy: phy-core.c: remove unnecessary initialization of local variables
Date: Thu, 26 Dec 2013 22:17:19 +0530	[thread overview]
Message-ID: <1388076440-7620-4-git-send-email-kishon@ti.com> (raw)
In-Reply-To: <1388076440-7620-1-git-send-email-kishon@ti.com>

There were a few places where variables are initialized unncessarily.
Remove those initializations.

Signed-off-by: Kishon Vijay Abraham I <kishon@ti.com>
---
 drivers/phy/phy-core.c |    6 +++---
 1 file changed, 3 insertions(+), 3 deletions(-)

diff --git a/drivers/phy/phy-core.c b/drivers/phy/phy-core.c
index 33fcbcc..645c867 100644
--- a/drivers/phy/phy-core.c
+++ b/drivers/phy/phy-core.c
@@ -210,7 +210,7 @@ EXPORT_SYMBOL_GPL(phy_exit);
 
 int phy_power_on(struct phy *phy)
 {
-	int ret = -ENOTSUPP;
+	int ret;
 
 	ret = phy_pm_runtime_get_sync(phy);
 	if (ret < 0 && ret != -ENOTSUPP)
@@ -238,7 +238,7 @@ EXPORT_SYMBOL_GPL(phy_power_on);
 
 int phy_power_off(struct phy *phy)
 {
-	int ret = -ENOTSUPP;
+	int ret;
 
 	mutex_lock(&phy->mutex);
 	if (phy->power_count == 1 && phy->ops->power_off) {
@@ -378,7 +378,7 @@ EXPORT_SYMBOL_GPL(of_phy_simple_xlate);
 struct phy *phy_get(struct device *dev, const char *string)
 {
 	int index = 0;
-	struct phy *phy = NULL;
+	struct phy *phy;
 
 	if (string == NULL) {
 		dev_WARN(dev, "missing string\n");
-- 
1.7.10.4


  parent reply	other threads:[~2013-12-26 16:48 UTC|newest]

Thread overview: 9+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2013-12-26 16:47 [GIT PULL 0/4] PHY: for 3.14 Kishon Vijay Abraham I
2013-12-26 16:47 ` [PATCH 1/4] phy: core: properly handle failure of pm_runtime_get functions Kishon Vijay Abraham I
2013-12-26 16:47 ` [PATCH 2/4] phy: phy-core: increment refcounting variables only on 'success' Kishon Vijay Abraham I
2013-12-26 16:47 ` Kishon Vijay Abraham I [this message]
2013-12-26 16:47 ` [PATCH 4/4] Phy: Add a PHY driver for Marvell MVEBU SATA PHY Kishon Vijay Abraham I
2014-01-08  5:24 ` [GIT PULL 0/4] PHY: for 3.14 Kishon Vijay Abraham I
2014-01-09  3:36   ` Greg KH
2014-01-09  5:58     ` Kishon Vijay Abraham I
2014-01-09  4:14 ` Greg KH

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=1388076440-7620-4-git-send-email-kishon@ti.com \
    --to=kishon@ti.com \
    --cc=gregkh@linuxfoundation.org \
    --cc=linux-kernel@vger.kernel.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox

Powered by JetHome