mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: "Rafael J. Wysocki" <rjw@sisk.pl>
To: Thomas Meyer <thomas@m3y3r.de>
Cc: Len Brown <len.brown@intel.com>, Pavel Machek <pavel@ucw.cz>,
	"Greg Kroah-Hartman" <gregkh@suse.de>,
	linux-kernel@vger.kernel.org
Subject: Re: [PATCH] PM / OPP: Use ERR_CAST inlined function
Date: Tue, 8 Nov 2011 22:52:03 +0100	[thread overview]
Message-ID: <201111082252.04069.rjw@sisk.pl> (raw)
In-Reply-To: <1320778667.8062.137.camel@localhost.localdomain>

On Tuesday, November 08, 2011, Thomas Meyer wrote:
> From: Thomas Meyer <thomas@m3y3r.de>
> 
>  Use ERR_CAST inlined function instead of ERR_PTR(PTR_ERR(...))
> 
>  The semantic patch that makes this change is available
>  in scripts/coccinelle/api/err_cast.cocci.
> 
>  More information about semantic patching is available at
>  http://coccinelle.lip6.fr/
> 
> Signed-off-by: Thomas Meyer <thomas@m3y3r.de>

Applied to linux-pm/pm-fixes, will push to Linus shortly.

Thanks,
Rafael


> ---
> 
> diff -u -p a/drivers/base/power/opp.c b/drivers/base/power/opp.c
> --- a/drivers/base/power/opp.c 2011-11-07 19:37:43.009876832 +0100
> +++ b/drivers/base/power/opp.c 2011-11-08 09:55:51.808539048 +0100
> @@ -669,7 +669,7 @@ struct srcu_notifier_head *opp_get_notif
>  	struct device_opp *dev_opp = find_device_opp(dev);
>  
>  	if (IS_ERR(dev_opp))
> -		return ERR_PTR(PTR_ERR(dev_opp)); /* matching type */
> +		return ERR_CAST(dev_opp); /* matching type */
>  
>  	return &dev_opp->head;
>  }
> 
> 
> 
> 


      reply	other threads:[~2011-11-08 21:49 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2011-11-08 18:57 Thomas Meyer
2011-11-08 21:52 ` Rafael J. Wysocki [this message]

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=201111082252.04069.rjw@sisk.pl \
    --to=rjw@sisk.pl \
    --cc=gregkh@suse.de \
    --cc=len.brown@intel.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=pavel@ucw.cz \
    --cc=thomas@m3y3r.de \
    /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

all inboxes | Powered by JetHome®