From: Laura Abbott <labbott@redhat.com>
To: simran singhal <singhalsimran0@gmail.com>
Cc: "Sumit Semwal" <sumit.semwal@linaro.org>,
"Greg Kroah-Hartman" <gregkh@linuxfoundation.org>,
"Arve Hjønnevåg" <arve@android.com>,
"Riley Andrews" <riandrews@android.com>,
devel@driverdev.osuosl.org, linux-kernel@vger.kernel.org,
outreachy-kernel@googlegroups.com
Subject: Re: [PATCH] staging: android: ion: Replace pr_err with dev_err
Date: Mon, 13 Mar 2017 13:57:08 -0700 [thread overview]
Message-ID: <1d40e93b-d384-353a-43e9-cdfb976d7168@redhat.com> (raw)
In-Reply-To: <20170313135624.GA9869@singhal-Inspiron-5558>
On 03/13/2017 06:56 AM, simran singhal wrote:
> All devm functions has a device structure as the first argument which is
> required by dev_{err,info,dbg} printing functions.
> This patch converts pr_err to dev_err as dev_* is preferred after calls
> to devm functions.
>
> Done using coccinelle:
>
> @r1 exists@
> expression e,e1;
> identifier f =~ "^devm_";
> identifier g =~ "^pcim_";
> identifier h =~ "^dmam_";
> @@
> e=\(f\|g\|h\)(e1,...);
> <+...
> (
> - pr_info(
> + dev_info(e1,
> ...);
> |
> - pr_err(
> + dev_err(e1,
> ...);
> |
> - pr_debug(
> + dev_dbg(e1,
> ...);
> )
> ...+>
>
> Signed-off-by: simran singhal <singhalsimran0@gmail.com>
> ---
> drivers/staging/android/ion/ion_test.c | 2 +-
> 1 file changed, 1 insertion(+), 1 deletion(-)
>
> diff --git a/drivers/staging/android/ion/ion_test.c b/drivers/staging/android/ion/ion_test.c
> index 5abf8320..0ab7d11 100644
> --- a/drivers/staging/android/ion/ion_test.c
> +++ b/drivers/staging/android/ion/ion_test.c
> @@ -255,7 +255,7 @@ static int __init ion_test_probe(struct platform_device *pdev)
> testdev->misc.parent = &pdev->dev;
> ret = misc_register(&testdev->misc);
> if (ret) {
> - pr_err("failed to register misc device.\n");
> + dev_err(&pdev->dev, "failed to register misc device.\n");
> return ret;
> }
>
>
Acked-by: Laura Abbott <labbott@redhat.com>
prev parent reply other threads:[~2017-03-13 20:57 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
2017-03-13 13:56 simran singhal
2017-03-13 20:57 ` Laura Abbott [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=1d40e93b-d384-353a-43e9-cdfb976d7168@redhat.com \
--to=labbott@redhat.com \
--cc=arve@android.com \
--cc=devel@driverdev.osuosl.org \
--cc=gregkh@linuxfoundation.org \
--cc=linux-kernel@vger.kernel.org \
--cc=outreachy-kernel@googlegroups.com \
--cc=riandrews@android.com \
--cc=singhalsimran0@gmail.com \
--cc=sumit.semwal@linaro.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
all inboxes | Powered by JetHome®