Intel-GFX Archive on lore.kernel.org
 help / color / mirror / Atom feed
From: Jani Nikula <jani.nikula@linux.intel.com>
To: Ville Syrjala <ville.syrjala@linux.intel.com>,
	intel-gfx@lists.freedesktop.org
Subject: Re: [Intel-gfx] [PATCH 2/2] drm/i915: Make intel_get_crtc_new_encoder() less oopsy
Date: Fri, 14 Apr 2023 12:39:59 +0300	[thread overview]
Message-ID: <87jzyeg5u8.fsf@intel.com> (raw)
In-Reply-To: <87r0smg68w.fsf@intel.com>

On Fri, 14 Apr 2023, Jani Nikula <jani.nikula@linux.intel.com> wrote:
> On Thu, 13 Apr 2023, Ville Syrjala <ville.syrjala@linux.intel.com> wrote:
>> From: Ville Syrjälä <ville.syrjala@linux.intel.com>
>>
>> The point of the WARN was to print something, not oops
>> straight up. Currently that is precisely what happens
>> if we can't find the connector for the crtc in the atomic
>> state. Get the dev pointer from the atomic state instead
>> of the potentially NULL encoder to avoid that.
>
> Fixes: ?

Reviewed-by: Jani Nikula <jani.nikula@intel.com>

>
>>
>> Signed-off-by: Ville Syrjälä <ville.syrjala@linux.intel.com>
>> ---
>>  drivers/gpu/drm/i915/display/intel_display.c | 2 +-
>>  1 file changed, 1 insertion(+), 1 deletion(-)
>>
>> diff --git a/drivers/gpu/drm/i915/display/intel_display.c b/drivers/gpu/drm/i915/display/intel_display.c
>> index 0334565cec82..5208b07505b2 100644
>> --- a/drivers/gpu/drm/i915/display/intel_display.c
>> +++ b/drivers/gpu/drm/i915/display/intel_display.c
>> @@ -959,7 +959,7 @@ intel_get_crtc_new_encoder(const struct intel_atomic_state *state,
>>  		num_encoders++;
>>  	}
>>  
>> -	drm_WARN(encoder->base.dev, num_encoders != 1,
>> +	drm_WARN(state->base.dev, num_encoders != 1,
>>  		 "%d encoders for pipe %c\n",
>>  		 num_encoders, pipe_name(master_crtc->pipe));

-- 
Jani Nikula, Intel Open Source Graphics Center

  reply	other threads:[~2023-04-14  9:40 UTC|newest]

Thread overview: 12+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2023-04-13 20:06 [Intel-gfx] [PATCH 1/2] drm/i915: Make intel_mpllb_state_verify() safer Ville Syrjala
2023-04-13 20:06 ` [Intel-gfx] [PATCH 2/2] drm/i915: Make intel_get_crtc_new_encoder() less oopsy Ville Syrjala
2023-04-14  9:31   ` Jani Nikula
2023-04-14  9:39     ` Jani Nikula [this message]
2023-04-14  0:02 ` [Intel-gfx] ✗ Fi.CI.SPARSE: warning for series starting with [1/2] drm/i915: Make intel_mpllb_state_verify() safer Patchwork
2023-04-14  0:15 ` [Intel-gfx] ✓ Fi.CI.BAT: success " Patchwork
2023-04-14  6:48 ` [Intel-gfx] ✓ Fi.CI.IGT: " Patchwork
2023-04-14  9:38 ` [Intel-gfx] [PATCH 1/2] " Jani Nikula
2023-04-14 19:01 ` [Intel-gfx] [PATCH v2 1/2] drm/i915: Make intel_{mpllb, c10pll}_state_verify() safer Ville Syrjala
2023-04-14 19:38 ` [Intel-gfx] ✗ Fi.CI.SPARSE: warning for series starting with [v2,1/2] drm/i915: Make intel_{mpllb, c10pll}_state_verify() safer (rev2) Patchwork
2023-04-14 19:52 ` [Intel-gfx] ✓ Fi.CI.BAT: success " Patchwork
2023-04-15  3:01 ` [Intel-gfx] ✓ Fi.CI.IGT: " Patchwork

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=87jzyeg5u8.fsf@intel.com \
    --to=jani.nikula@linux.intel.com \
    --cc=intel-gfx@lists.freedesktop.org \
    --cc=ville.syrjala@linux.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