dri-devel Archive on lore.kernel.org
 help / color / mirror / Atom feed
From: Thomas Zimmermann <tzimmermann@suse.de>
To: Sam Ravnborg <sam@ravnborg.org>
Cc: airlied@redhat.com, chen@aspeedtech.com, kraxel@redhat.com,
	dri-devel@lists.freedesktop.org, emil.velikov@collabora.com
Subject: Re: [PATCH 3/3] drm/ast: Use per-device logging macros
Date: Fri, 12 Jun 2020 09:12:53 +0200	[thread overview]
Message-ID: <fa3f9331-e9cb-b43d-3972-9b6f18f1a85a@suse.de> (raw)
In-Reply-To: <20200612070137.GA172811@ravnborg.org>


[-- Attachment #1.1.1: Type: text/plain, Size: 2237 bytes --]

Hi

Am 12.06.20 um 09:01 schrieb Sam Ravnborg:
> Hi Thomas
> 
> On Fri, Jun 12, 2020 at 08:28:40AM +0200, Thomas Zimmermann wrote:
>> Hi Sam
>>
>> Am 11.06.20 um 21:24 schrieb Sam Ravnborg:
>>> Hi Thomas.
>>> On Thu, Jun 11, 2020 at 10:28:09AM +0200, Thomas Zimmermann wrote:
>>>> Converts the ast driver to drm_info() and drm_err(). No functional
>>>> changes are made.
>>>>
>>>> Signed-off-by: Thomas Zimmermann <tzimmermann@suse.de>
>>> Acked-by: Sam Ravnborg <sam@ravnborg.org>
>>>
>>> I hope you will later follow-up with a patch that introduces drm_WARN_*.
>>
>> I only found DRM_INFO and DRM_ERROR calls. Did I miss any other warning
>> macros?
> 
> The following:
> ast_mode.c:     if (WARN_ON_ONCE(gpu_addr < 0))
> ast_mode.c:     if (WARN_ON_ONCE(fb->width > AST_MAX_HWC_WIDTH) ||
> ast_mode.c:         WARN_ON_ONCE(fb->height > AST_MAX_HWC_HEIGHT))
> ast_mode.c:             if (WARN_ON_ONCE(off < 0))
> ast_mode.c:     if (WARN_ON(!crtc->state))

Thanks! I'll fix those.

Best regards
Thomas

> 
> can benefit from:
> 
> /*
>  * struct drm_device based WARNs
>  *
>  * drm_WARN*() acts like WARN*(), but with the key difference of
>  * using device specific information so that we know from which device
>  * warning is originating from.
>  *
>  * Prefer drm_device based drm_WARN* over regular WARN*
>  */
> 
> ...
> 
> #define drm_WARN_ON(drm, x)                                             \
>         drm_WARN((drm), (x), "%s",                                      \
>                  "drm_WARN_ON(" __stringify(x) ")")
> 
> #define drm_WARN_ON_ONCE(drm, x)                                        \
>         drm_WARN_ONCE((drm), (x), "%s",                                 \
>                       "drm_WARN_ON_ONCE(" __stringify(x) ")")
> 
> 
> Also from drm/drm_print.h
> 
> 	Sam
> _______________________________________________
> dri-devel mailing list
> dri-devel@lists.freedesktop.org
> https://lists.freedesktop.org/mailman/listinfo/dri-devel
> 

-- 
Thomas Zimmermann
Graphics Driver Developer
SUSE Software Solutions Germany GmbH
Maxfeldstr. 5, 90409 Nürnberg, Germany
(HRB 36809, AG Nürnberg)
Geschäftsführer: Felix Imendörffer


[-- Attachment #1.2: OpenPGP digital signature --]
[-- Type: application/pgp-signature, Size: 488 bytes --]

[-- Attachment #2: Type: text/plain, Size: 160 bytes --]

_______________________________________________
dri-devel mailing list
dri-devel@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/dri-devel

      reply	other threads:[~2020-06-12  7:13 UTC|newest]

Thread overview: 17+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2020-06-11  8:28 [PATCH 0/3] ast cleanups Thomas Zimmermann
2020-06-11  8:28 ` [PATCH 1/3] drm/ast: Remove unused code paths for AST 1180 Thomas Zimmermann
2020-06-11 17:24   ` Daniel Vetter
2020-06-15 23:21   ` Emil Velikov
2020-06-17  7:13     ` Thomas Zimmermann
2020-06-11  8:28 ` [PATCH 2/3] drm/ast: Upcast from DRM device to ast structure via to_ast_private() Thomas Zimmermann
2020-06-11 17:32   ` Daniel Vetter
2020-06-12  6:31     ` Thomas Zimmermann
2020-06-11 19:23   ` Sam Ravnborg
2020-06-12  6:30     ` Thomas Zimmermann
2020-06-12  6:57       ` Daniel Vetter
2020-06-11  8:28 ` [PATCH 3/3] drm/ast: Use per-device logging macros Thomas Zimmermann
2020-06-11 17:33   ` Daniel Vetter
2020-06-11 19:24   ` Sam Ravnborg
2020-06-12  6:28     ` Thomas Zimmermann
2020-06-12  7:01       ` Sam Ravnborg
2020-06-12  7:12         ` Thomas Zimmermann [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=fa3f9331-e9cb-b43d-3972-9b6f18f1a85a@suse.de \
    --to=tzimmermann@suse.de \
    --cc=airlied@redhat.com \
    --cc=chen@aspeedtech.com \
    --cc=dri-devel@lists.freedesktop.org \
    --cc=emil.velikov@collabora.com \
    --cc=kraxel@redhat.com \
    --cc=sam@ravnborg.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