All of lore.kernel.org
 help / color / mirror / Atom feed
From: jhbird.choi@samsung.com
To: linux-pm@lists.linux-foundation.org, linux-kernel@vger.kernel.org
Cc: "Rafael J. Wysocki" <rjw@sisk.pl>,
	Jonghwan Choi <jhbird.choi@samsung.com>
Subject: [PATCH] PM / OPP: Fix dev_opp initial value
Date: Thu, 21 Jul 2011 15:31:48 +0900	[thread overview]
Message-ID: <1311229908-6046-1-git-send-email-jhbird.choi@samsung.com> (raw)

From: Jonghwan Choi <jhbird.choi@samsung.com>

Dev_opp initial value shoule be ERR_PTR(),
IS_ERR() is used to check error.

Signed-off-by: Jonghwan Choi <jhbird.choi@samsung.com>
---
 drivers/base/power/opp.c |    2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)

diff --git a/drivers/base/power/opp.c b/drivers/base/power/opp.c
index 56a6899..d4ebf80 100644
--- a/drivers/base/power/opp.c
+++ b/drivers/base/power/opp.c
@@ -453,7 +453,7 @@ int opp_add(struct device *dev, unsigned long freq, unsigned long u_volt)
 static int opp_set_availability(struct device *dev, unsigned long freq,
 		bool availability_req)
 {
-	struct device_opp *tmp_dev_opp, *dev_opp = NULL;
+	struct device_opp *tmp_dev_opp, *dev_opp = ERR_PTR(-ENODEV);
 	struct opp *new_opp, *tmp_opp, *opp = ERR_PTR(-ENODEV);
 	int r = 0;
 
-- 
1.7.0


             reply	other threads:[~2011-07-21  6:38 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2011-07-21  6:31 jhbird.choi [this message]
  -- strict thread matches above, loose matches on Subject: below --
2011-07-21  6:31 [PATCH] PM / OPP: Fix dev_opp initial value jhbird.choi

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=1311229908-6046-1-git-send-email-jhbird.choi@samsung.com \
    --to=jhbird.choi@samsung.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-pm@lists.linux-foundation.org \
    --cc=rjw@sisk.pl \
    /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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.