From: Tvrtko Ursulin <tvrtko.ursulin@linux.intel.com>
To: Dave Gordon <david.s.gordon@intel.com>,
intel-gfx@lists.freedesktop.org, Dave Airlie <airlied@gmail.com>,
Daniel Vetter <daniel@ffwll.ch>
Cc: dri-devel@lists.freedesktop.org
Subject: Re: [PATCH v4 1/4] drm: extra printk() wrapper macros
Date: Fri, 19 Aug 2016 13:56:31 +0100 [thread overview]
Message-ID: <57B701FF.6030706@linux.intel.com> (raw)
In-Reply-To: <1471540645-17106-2-git-send-email-david.s.gordon@intel.com>
Hi Dave, Daniel,
We had this i915 series with a single DRM core patch (reviewed) ready
for a while - just waiting for an ack to merge it via i915 trees.
Can we proceed with merging it?
Regards,
Tvrtko
On 18/08/16 18:17, Dave Gordon wrote:
> We had only DRM_INFO() and DRM_ERROR(), whereas the underlying printk()
> provides several other useful intermediate levels such as NOTICE and
> WARNING. So this patch fills out the set by providing both regular and
> once-only macros for each of the levels INFO, NOTICE, and WARNING, using
> a common underlying macro that does all the token-pasting.
>
> DRM_ERROR is unchanged, as it's not just a printk wrapper.
>
> v2:
> Fix whitespace, missing ## (Eric Engestrom)
>
> Signed-off-by: Dave Gordon <david.s.gordon@intel.com>
> Reviewed-by: Eric Engestrom <eric.engestrom@imgtec.com>
> Cc: dri-devel@lists.freedesktop.org
> ---
> include/drm/drmP.h | 26 ++++++++++++++++++++------
> 1 file changed, 20 insertions(+), 6 deletions(-)
>
> diff --git a/include/drm/drmP.h b/include/drm/drmP.h
> index f8e87fd..734e4fb 100644
> --- a/include/drm/drmP.h
> +++ b/include/drm/drmP.h
> @@ -163,6 +163,26 @@ void drm_err(const char *format, ...);
> /** \name Macros to make printk easier */
> /*@{*/
>
> +#define _DRM_PRINTK(once, level, fmt, ...) \
> + do { \
> + printk##once(KERN_##level "[" DRM_NAME "] " fmt, \
> + ##__VA_ARGS__); \
> + } while (0)
> +
> +#define DRM_INFO(fmt, ...) \
> + _DRM_PRINTK(, INFO, fmt, ##__VA_ARGS__)
> +#define DRM_NOTE(fmt, ...) \
> + _DRM_PRINTK(, NOTICE, fmt, ##__VA_ARGS__)
> +#define DRM_WARN(fmt, ...) \
> + _DRM_PRINTK(, WARNING, fmt, ##__VA_ARGS__)
> +
> +#define DRM_INFO_ONCE(fmt, ...) \
> + _DRM_PRINTK(_once, INFO, fmt, ##__VA_ARGS__)
> +#define DRM_NOTE_ONCE(fmt, ...) \
> + _DRM_PRINTK(_once, NOTICE, fmt, ##__VA_ARGS__)
> +#define DRM_WARN_ONCE(fmt, ...) \
> + _DRM_PRINTK(_once, WARNING, fmt, ##__VA_ARGS__)
> +
> /**
> * Error output.
> *
> @@ -188,12 +208,6 @@ void drm_err(const char *format, ...);
> drm_err(fmt, ##__VA_ARGS__); \
> })
>
> -#define DRM_INFO(fmt, ...) \
> - printk(KERN_INFO "[" DRM_NAME "] " fmt, ##__VA_ARGS__)
> -
> -#define DRM_INFO_ONCE(fmt, ...) \
> - printk_once(KERN_INFO "[" DRM_NAME "] " fmt, ##__VA_ARGS__)
> -
> /**
> * Debug output.
> *
>
_______________________________________________
Intel-gfx mailing list
Intel-gfx@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/intel-gfx
next prev parent reply other threads:[~2016-08-19 12:56 UTC|newest]
Thread overview: 11+ messages / expand[flat|nested] mbox.gz Atom feed top
2016-08-18 17:17 [PATCH v4 0/4] Reclassify messages from GuC loader/submission Dave Gordon
2016-08-18 17:17 ` [PATCH v4 1/4] drm: extra printk() wrapper macros Dave Gordon
2016-08-19 12:56 ` Tvrtko Ursulin [this message]
2016-08-19 21:00 ` Dave Airlie
2016-08-18 17:17 ` [PATCH v4 2/4] drm/i915/guc: downgrade some DRM_ERROR() messages to DRM_WARN() Dave Gordon
2016-08-18 17:17 ` [PATCH v4 3/4] drm/i915/guc: revisit GuC loader message levels Dave Gordon
2016-08-18 17:17 ` [PATCH v4 4/4] NOMERGE: next version of GuC firmware is 8.11 Dave Gordon
2016-08-19 5:27 ` ✗ Ro.CI.BAT: failure for Reclassify messages from GuC loader/submission (rev4) Patchwork
-- strict thread matches above, loose matches on Subject: below --
2016-08-11 17:00 [PATCH v4 0/4] Reclassify messages from GuC loader/submission Dave Gordon
2016-08-11 17:01 ` [PATCH v4 1/4] drm: extra printk() wrapper macros Dave Gordon
2016-08-11 11:14 [PATCH v4 0/4] Reclassify messages from GuC loader/submission Dave Gordon
2016-08-11 11:14 ` [PATCH v4 1/4] drm: extra printk() wrapper macros Dave Gordon
2016-08-10 15:13 [PATCH v4 0/4] Reclassify messages from GuC loader/submission Dave Gordon
2016-08-10 15:13 ` [PATCH v4 1/4] drm: extra printk() wrapper macros Dave Gordon
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=57B701FF.6030706@linux.intel.com \
--to=tvrtko.ursulin@linux.intel.com \
--cc=airlied@gmail.com \
--cc=daniel@ffwll.ch \
--cc=david.s.gordon@intel.com \
--cc=dri-devel@lists.freedesktop.org \
--cc=intel-gfx@lists.freedesktop.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 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.