From: Rodrigo Vivi <rodrigo.vivi@intel.com>
To: Matthew Brost <matthew.brost@intel.com>
Cc: <intel-xe@lists.freedesktop.org>
Subject: Re: [PATCH] drm/xe: Use xe_assert in xe_device_assert_mem_access
Date: Wed, 13 Mar 2024 15:56:25 -0400 [thread overview]
Message-ID: <ZfIE6SVMYz5B7x1X@intel.com> (raw)
In-Reply-To: <20240313184430.999397-1-matthew.brost@intel.com>
On Wed, Mar 13, 2024 at 11:44:30AM -0700, Matthew Brost wrote:
> The implementation of xe_device_assert_mem_access has a non-zero cost.
> Use xe_assert rather than XE_WARN_ON so it will compile out in non-debug
> kernel builds (Kconfig CONFIG_DRM_XE_DEBUG=n).
>
> Cc: Rodrigo Vivi <rodrigo.vivi@intel.com>
> Signed-off-by: Matthew Brost <matthew.brost@intel.com>
Reviewed-by: Rodrigo Vivi <rodrigo.vivi@intel.com>
> ---
> drivers/gpu/drm/xe/xe_device.c | 2 +-
> 1 file changed, 1 insertion(+), 1 deletion(-)
>
> diff --git a/drivers/gpu/drm/xe/xe_device.c b/drivers/gpu/drm/xe/xe_device.c
> index 919ad88f0495..b0bfe75eb59f 100644
> --- a/drivers/gpu/drm/xe/xe_device.c
> +++ b/drivers/gpu/drm/xe/xe_device.c
> @@ -666,7 +666,7 @@ bool xe_device_mem_access_ongoing(struct xe_device *xe)
> */
> void xe_device_assert_mem_access(struct xe_device *xe)
> {
> - XE_WARN_ON(xe_pm_runtime_suspended(xe));
> + xe_assert(xe, !xe_pm_runtime_suspended(xe));
> }
>
> bool xe_device_mem_access_get_if_ongoing(struct xe_device *xe)
> --
> 2.34.1
>
prev parent reply other threads:[~2024-03-13 19:56 UTC|newest]
Thread overview: 9+ messages / expand[flat|nested] mbox.gz Atom feed top
2024-03-13 18:44 [PATCH] drm/xe: Use xe_assert in xe_device_assert_mem_access Matthew Brost
2024-03-13 18:52 ` ✓ CI.Patch_applied: success for " Patchwork
2024-03-13 18:52 ` ✓ CI.checkpatch: " Patchwork
2024-03-13 18:53 ` ✓ CI.KUnit: " Patchwork
2024-03-13 19:04 ` ✓ CI.Build: " Patchwork
2024-03-13 19:06 ` ✓ CI.Hooks: " Patchwork
2024-03-13 19:07 ` ✓ CI.checksparse: " Patchwork
2024-03-13 19:29 ` ✓ CI.BAT: " Patchwork
2024-03-13 19:56 ` Rodrigo Vivi [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=ZfIE6SVMYz5B7x1X@intel.com \
--to=rodrigo.vivi@intel.com \
--cc=intel-xe@lists.freedesktop.org \
--cc=matthew.brost@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 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.