On Tue, Oct 11, 2022 at 04:49:49PM +0300, Jani Nikula wrote: > Convert to drm_kms_dbg/drm_err where possible, and unify the rest of the > debugs to DRM_DEBUG_KMS. > > Signed-off-by: Jani Nikula <jani.nikula@xxxxxxxxx> > --- > drivers/gpu/drm/drm_edid.c | 105 ++++++++++++++++++------------------- > 1 file changed, 50 insertions(+), 55 deletions(-) > > diff --git a/drivers/gpu/drm/drm_edid.c b/drivers/gpu/drm/drm_edid.c > index 935bdf4e6269..09b0b8337382 100644 > --- a/drivers/gpu/drm/drm_edid.c > +++ b/drivers/gpu/drm/drm_edid.c > @@ -1979,7 +1979,7 @@ bool drm_edid_block_valid(u8 *_block, int block_num, bool print_bad_edid, > > status = edid_block_check(block, is_base_block); > if (status == EDID_BLOCK_HEADER_REPAIR) { > - DRM_DEBUG("Fixing EDID header, your hardware may be failing\n"); > + DRM_DEBUG_KMS("Fixing EDID header, your hardware may be failing\n"); > edid_header_fix(block); > > /* Retry with fixed header, update status if that worked. */ > @@ -2281,8 +2281,9 @@ int drm_edid_override_connector_update(struct drm_connector *connector) > > drm_edid_free(override); > > - DRM_DEBUG_KMS("[CONNECTOR:%d:%s] adding %d modes via fallback override/firmware EDID\n", > - connector->base.id, connector->name, num_modes); > + drm_dbg_kms(connector->dev, > + "[CONNECTOR:%d:%s] adding %d modes via fallback override/firmware EDID\n", > + connector->base.id, connector->name, num_modes); > } > > return num_modes; > @@ -3389,17 +3390,16 @@ static struct drm_display_mode *drm_mode_detailed(struct drm_device *dev, > return NULL; > > if (pt->misc & DRM_EDID_PT_STEREO) { > - DRM_DEBUG_KMS("stereo mode not supported\n"); > + drm_dbg_kms(dev, "Stereo mode not supported\n"); > return NULL; > } > if (!(pt->misc & DRM_EDID_PT_SEPARATE_SYNC)) { > - DRM_DEBUG_KMS("composite sync not supported\n"); > + drm_dbg_kms(dev, "Composite sync not supported\n"); > } > > /* it is incorrect if hsync/vsync width is zero */ > if (!hsync_pulse_width || !vsync_pulse_width) { > - DRM_DEBUG_KMS("Incorrect Detailed timing. " > - "Wrong Hsync/Vsync pulse width\n"); > + drm_dbg_kms(dev, "Incorrect Detailed timing. Wrong Hsync/Vsync pulse width\n"); > return NULL; > } > > @@ -4643,7 +4643,7 @@ static int add_hdmi_mode(struct drm_connector *connector, u8 vic) > struct drm_display_mode *newmode; > > if (!drm_valid_hdmi_vic(vic)) { > - DRM_ERROR("Unknown HDMI VIC: %d\n", vic); > + drm_err(connector->dev, "Unknown HDMI VIC: %d\n", vic); Quit a lot of these could also do the full [CONNECTOR:...] thing it seems. -- Ville Syrjälä Intel