From: Pankaj Bharadiya <pankaj.laxminarayan.bharadiya@intel.com>
To: jani.nikula@linux.intel.com, daniel@ffwll.ch,
intel-gfx@lists.freedesktop.org, dri-devel@lists.freedesktop.org,
Joonas Lahtinen <joonas.lahtinen@linux.intel.com>,
Rodrigo Vivi <rodrigo.vivi@intel.com>,
David Airlie <airlied@linux.ie>
Cc: pankaj.laxminarayan.bharadiya@intel.com
Subject: [Intel-gfx][PATCH 01/10] drm/i915: Add i915 device based MISSING_CASE macro
Date: Tue, 25 Feb 2020 19:17:00 +0530 [thread overview]
Message-ID: <20200225134709.6153-2-pankaj.laxminarayan.bharadiya@intel.com> (raw)
In-Reply-To: <20200225134709.6153-1-pankaj.laxminarayan.bharadiya@intel.com>
Now that we have struct drm_device based drm_WARN, introduce struct
drm_i915_private based i915_MISSING_CASE macro which uses drm_WARN so
that device specific information will also get printed in backtrace.
i915_MISSING_CASE macro should be preferred over MISSING_CASE,
wherever possible.
Signed-off-by: Pankaj Bharadiya <pankaj.laxminarayan.bharadiya@intel.com>
---
drivers/gpu/drm/i915/i915_utils.h | 4 ++++
1 file changed, 4 insertions(+)
diff --git a/drivers/gpu/drm/i915/i915_utils.h b/drivers/gpu/drm/i915/i915_utils.h
index b0ade76bec90..f8db1eb9c1cc 100644
--- a/drivers/gpu/drm/i915/i915_utils.h
+++ b/drivers/gpu/drm/i915/i915_utils.h
@@ -52,6 +52,10 @@ struct timer_list;
#define MISSING_CASE(x) WARN(1, "Missing case (%s == %ld)\n", \
__stringify(x), (long)(x))
+#define i915_MISSING_CASE(i915, x) drm_WARN(&(i915)->drm, 1, \
+ "Missing case (%s == %ld)\n", \
+ __stringify(x), (long)(x))
+
void __printf(3, 4)
__i915_printk(struct drm_i915_private *dev_priv, const char *level,
const char *fmt, ...);
--
2.23.0
_______________________________________________
dri-devel mailing list
dri-devel@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/dri-devel
next prev parent reply other threads:[~2020-02-25 13:57 UTC|newest]
Thread overview: 15+ messages / expand[flat|nested] mbox.gz Atom feed top
2020-02-25 13:46 [Intel-gfx][PATCH 00/10] drm/i915: Introduce i915 based i915_MISSING_CASE macro and us it in i915 Pankaj Bharadiya
2020-02-25 13:47 ` Pankaj Bharadiya [this message]
2020-02-25 14:01 ` [Intel-gfx][PATCH 01/10] drm/i915: Add i915 device based MISSING_CASE macro Chris Wilson
2020-02-27 6:33 ` Laxminarayan Bharadiya, Pankaj
2020-02-27 8:29 ` Jani Nikula
2020-02-28 5:02 ` Laxminarayan Bharadiya, Pankaj
2020-02-25 13:47 ` [Intel-gfx][PATCH 02/10] drm/i915/display/cdclk: Make MISSING_CASE backtrace i915 specific Pankaj Bharadiya
2020-02-25 13:47 ` [Intel-gfx][PATCH 03/10] drm/i915/display/ddi: " Pankaj Bharadiya
2020-02-25 13:47 ` [Intel-gfx][PATCH 04/10] drm/i915/display/display: " Pankaj Bharadiya
2020-02-25 13:47 ` [Intel-gfx][PATCH 05/10] drm/i915/dp: " Pankaj Bharadiya
2020-02-25 13:47 ` [Intel-gfx][PATCH 06/10] drm/i915/display/hdmi: " Pankaj Bharadiya
2020-02-25 13:47 ` [Intel-gfx][PATCH 07/10] drm/i915/display: " Pankaj Bharadiya
2020-02-25 13:47 ` [Intel-gfx][PATCH 08/10] drm/i915/gem: " Pankaj Bharadiya
2020-02-25 13:47 ` [Intel-gfx][PATCH 09/10] drm/i915/gt: " Pankaj Bharadiya
2020-02-25 13:47 ` [Intel-gfx][PATCH 10/10] drm/i915: " Pankaj Bharadiya
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=20200225134709.6153-2-pankaj.laxminarayan.bharadiya@intel.com \
--to=pankaj.laxminarayan.bharadiya@intel.com \
--cc=airlied@linux.ie \
--cc=daniel@ffwll.ch \
--cc=dri-devel@lists.freedesktop.org \
--cc=intel-gfx@lists.freedesktop.org \
--cc=jani.nikula@linux.intel.com \
--cc=joonas.lahtinen@linux.intel.com \
--cc=rodrigo.vivi@intel.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).