From: Jani Nikula <jani.nikula@linux.intel.com>
To: Daniel Vetter <daniel@ffwll.ch>, Dave Gordon <david.s.gordon@intel.com>
Cc: intel-gfx@lists.freedesktop.org, thomas@m3y3r.de
Subject: Re: [PATCH] drm/i915: use in_interrupt() not in_irq() to check context
Date: Tue, 10 Mar 2015 11:59:47 +0200 [thread overview]
Message-ID: <87egoxrx4c.fsf@intel.com> (raw)
In-Reply-To: <20150306164603.GB18775@phenom.ffwll.local>
On Fri, 06 Mar 2015, Daniel Vetter <daniel@ffwll.ch> wrote:
> On Fri, Mar 06, 2015 at 03:34:26PM +0000, Dave Gordon wrote:
>> The kernel in_irq() function tests for hard-IRQ context only, so if a
>> system is run with the kernel 'threadirqs' option selected, the test in
>> intel_check_page_flip() generates lots of warnings, because then it gets
>> called in soft-IRQ context.
>>
>> We can instead use in_interrupt() which allows for either type of
>> interrupt, while still detecting and complaining about misuse of the
>> page flip code if it is ever called from non-interrupt context.
>>
>> Signed-off-by: Dave Gordon <david.s.gordon@intel.com>
>
> Makes sense.
>
> Reviewed-by: Daniel Vetter <daniel.vetter@ffwll.ch>
> Cc: stable@vger.kernel.org
Pushed to drm-intel-fixes, thanks for the patch and review. Also added
Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=89321
BR,
Jani.
>
> Cheers, Daniel
>> ---
>> drivers/gpu/drm/i915/intel_display.c | 2 +-
>> 1 file changed, 1 insertion(+), 1 deletion(-)
>>
>> diff --git a/drivers/gpu/drm/i915/intel_display.c b/drivers/gpu/drm/i915/intel_display.c
>> index 43d3575..73213a7 100644
>> --- a/drivers/gpu/drm/i915/intel_display.c
>> +++ b/drivers/gpu/drm/i915/intel_display.c
>> @@ -9817,7 +9817,7 @@ void intel_check_page_flip(struct drm_device *dev, int pipe)
>> struct drm_crtc *crtc = dev_priv->pipe_to_crtc_mapping[pipe];
>> struct intel_crtc *intel_crtc = to_intel_crtc(crtc);
>>
>> - WARN_ON(!in_irq());
>> + WARN_ON(!in_interrupt());
>>
>> if (crtc == NULL)
>> return;
>> --
>> 1.7.9.5
>>
>> _______________________________________________
>> Intel-gfx mailing list
>> Intel-gfx@lists.freedesktop.org
>> http://lists.freedesktop.org/mailman/listinfo/intel-gfx
>
> --
> Daniel Vetter
> Software Engineer, Intel Corporation
> +41 (0) 79 365 57 48 - http://blog.ffwll.ch
--
Jani Nikula, Intel Open Source Technology Center
_______________________________________________
Intel-gfx mailing list
Intel-gfx@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/intel-gfx
next prev parent reply other threads:[~2015-03-10 9:58 UTC|newest]
Thread overview: 12+ messages / expand[flat|nested] mbox.gz Atom feed top
2015-03-04 17:42 [4.0-rc2] WARNING at intel_check_page_flip Thomas Meyer
2015-03-04 18:32 ` Ville Syrjälä
2015-03-06 15:34 ` [PATCH] drm/i915: use in_interrupt() not in_irq() to check context Dave Gordon
2015-03-06 16:46 ` Daniel Vetter
2015-03-10 9:59 ` Jani Nikula [this message]
2015-03-06 20:20 ` shuang.he
-- strict thread matches above, loose matches on Subject: below --
2015-02-01 23:35 Kernel 3.19rc6 flooding intel_check_page_flip warnings when using compton Sakari Kapanen
2015-02-02 7:44 ` Sakari Kapanen
2015-02-04 9:26 ` Jani Nikula
2015-02-05 10:44 ` Sakari Kapanen
2015-02-05 11:01 ` Chris Wilson
2015-02-09 17:30 ` 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=87egoxrx4c.fsf@intel.com \
--to=jani.nikula@linux.intel.com \
--cc=daniel@ffwll.ch \
--cc=david.s.gordon@intel.com \
--cc=intel-gfx@lists.freedesktop.org \
--cc=thomas@m3y3r.de \
/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