From: Wambui Karuga <wambui@karuga.xyz>
To: Sean Paul <sean@poorly.run>
Cc: "Heiko Stübner" <heiko@sntech.de>,
"Wambui Karuga" <wambui.karugax@gmail.com>,
hjc@rock-chips.com, airlied@linux.ie, daniel@ffwll.ch,
dri-devel@lists.freedesktop.org,
linux-arm-kernel@lists.infradead.org,
linux-rockchip@lists.infradead.org, linux-kernel@vger.kernel.org
Subject: Re: [PATCH] drm/rockchip: use DRM_DEV_ERROR for log output
Date: Fri, 8 Nov 2019 23:07:44 +0300 (EAT) [thread overview]
Message-ID: <alpine.LNX.2.21.99999.375.1911082306460.13123@wambui> (raw)
In-Reply-To: <20191108160602.GG63329@art_vandelay>
[-- Attachment #1: Type: text/plain, Size: 2739 bytes --]
On Fri, 8 Nov 2019, Sean Paul wrote:
> On Fri, Nov 08, 2019 at 03:06:44PM +0100, Heiko Stübner wrote:
>> Hi,
>>
>> [it seems your Reply-To mail header is set strangely as
>> Reply-To: 20191107133851.GF63329@art_vandelay
>> which confuses my MTA]
>>
>> Am Freitag, 8. November 2019, 13:46:30 CET schrieb Wambui Karuga:
>>> On Thu, Nov 07, 2019 at 08:38:51AM -0500, Sean Paul wrote:
>>>> On Thu, Nov 07, 2019 at 01:54:22AM -0800, Joe Perches wrote:
>>>>> On Thu, 2019-11-07 at 12:29 +0300, Wambui Karuga wrote:
>>>>>> Replace the use of the dev_err macro with the DRM_DEV_ERROR
>>>>>> DRM helper macro.
>>>>>
>>>>> The commit message should show the reason _why_ you are doing
>>>>> this instead of just stating that you are doing this.
>>>>>
>>>>> It's not that dev_err is uncommon in drivers/gpu/drm.
>>>>>
>>>>
>>>> It is uncommon (this is the sole instance) in rockchip, however. So it makes
>>>> sense to convert the dev_* prints in rockchip to DRM_DEV for consistency.
>>>>
>>>> Wambui, could you also please convert the dev_warn instance as well?
>>>>
>>> Hey, Sean.
>>> Trying to convert this dev_warn instance, but the corresponding DRM_WARN
>>> macro does not take the dev parameter which seems to be useful in the
>>> original output.
>>> Should I still convert it to DRM_WARN without the hdmi->dev parameter?
>>
>> There exists DRM_DEV_ERROR, DRM_DEV_INFO and DRM_DEV_DEBUG to
>> handle actual devices. Interestingly there is no DRM_DEV_WARN though.
>>
>> So depending on what Sean suggest another option would be to add the
>> missing DRM_DEV_WARN and then use it to replace the dev_warn.
>
> Yep, this sounds good to me me.
>
> Sean
>
Okay, I can add DRM_DEV_WARN and replace it there.
wambui
>>
>>
>> Heiko
>>
>>
>>
>>>
>>> Thanks,
>>> wambui
>>>> I'll apply this to drm-misc-next and expand on the commit message a bit.
>>>>
>>>> Thanks,
>>>>
>>>> Sean
>>>>
>>>>> $ git grep -w dev_err drivers/gpu/drm | wc -l
>>>>> 1950
>>>>> $ git grep -w DRM_DEV_ERROR drivers/gpu/drm | wc -l
>>>>> 756
>>>>>
>>>>>> diff --git a/drivers/gpu/drm/rockchip/dw-mipi-dsi-rockchip.c b/drivers/gpu/drm/rockchip/dw-mipi-dsi-rockchip.c
>>>>> []
>>>>>> @@ -916,7 +916,7 @@ static int dw_mipi_dsi_rockchip_probe(struct platform_device *pdev)
>>>>>> }
>>>>>>
>>>>>> if (!dsi->cdata) {
>>>>>> - dev_err(dev, "no dsi-config for %s node\n", np->name);
>>>>>> + DRM_DEV_ERROR(dev, "no dsi-config for %s node\n", np->name);
>>>>>> return -EINVAL;
>>>>>> }
>>>>>
>>>>>
>>>>>
>>>>> _______________________________________________
>>>>> dri-devel mailing list
>>>>> dri-devel@lists.freedesktop.org
>>>>> https://lists.freedesktop.org/mailman/listinfo/dri-devel
>>>>
>>>
>>
>>
>>
>>
>
> --
> Sean Paul, Software Engineer, Google / Chromium OS
>
next prev parent reply other threads:[~2019-11-08 20:07 UTC|newest]
Thread overview: 9+ messages / expand[flat|nested] mbox.gz Atom feed top
2019-11-07 9:29 [PATCH] drm/rockchip: use DRM_DEV_ERROR for log output Wambui Karuga
2019-11-07 9:54 ` Joe Perches
2019-11-07 13:38 ` Sean Paul
2019-11-07 18:22 ` Wambui Karuga
2019-11-08 12:46 ` Wambui Karuga
2019-11-08 14:06 ` Heiko Stübner
2019-11-08 16:06 ` Sean Paul
2019-11-08 20:07 ` Wambui Karuga [this message]
2019-11-09 0:42 ` Joe Perches
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=alpine.LNX.2.21.99999.375.1911082306460.13123@wambui \
--to=wambui@karuga.xyz \
--cc=airlied@linux.ie \
--cc=daniel@ffwll.ch \
--cc=dri-devel@lists.freedesktop.org \
--cc=heiko@sntech.de \
--cc=hjc@rock-chips.com \
--cc=linux-arm-kernel@lists.infradead.org \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-rockchip@lists.infradead.org \
--cc=sean@poorly.run \
--cc=wambui.karugax@gmail.com \
/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;
as well as URLs for NNTP newsgroup(s).