Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux

drm/scdc-helper: Convert errors into debug messages

Since we may attempt to reconfigure SCDC when the sink has already been
disconnected we probably shouldn't scare the user with errors in dmesg
that are 100% expected in that case. Just leave it up to the caller
whether to print an error message or not, and just output debug
messages from the helper itself.

Cc: Shashank Sharma <shashank.sharma@intel.com>
Signed-off-by: Ville Syrjälä <ville.syrjala@linux.intel.com>
Link: https://patchwork.freedesktop.org/patch/msgid/20180323182537.30784-1-ville.syrjala@linux.intel.com
Reviewed-by: Shashank Sharma <shashank.sharma@intel.com>

+5 -5
+5 -5
drivers/gpu/drm/drm_scdc_helper.c
··· 141 141 142 142 ret = drm_scdc_readb(adapter, SCDC_SCRAMBLER_STATUS, &status); 143 143 if (ret < 0) { 144 - DRM_ERROR("Failed to read scrambling status: %d\n", ret); 144 + DRM_DEBUG_KMS("Failed to read scrambling status: %d\n", ret); 145 145 return false; 146 146 } 147 147 ··· 168 168 169 169 ret = drm_scdc_readb(adapter, SCDC_TMDS_CONFIG, &config); 170 170 if (ret < 0) { 171 - DRM_ERROR("Failed to read TMDS config: %d\n", ret); 171 + DRM_DEBUG_KMS("Failed to read TMDS config: %d\n", ret); 172 172 return false; 173 173 } 174 174 ··· 179 179 180 180 ret = drm_scdc_writeb(adapter, SCDC_TMDS_CONFIG, config); 181 181 if (ret < 0) { 182 - DRM_ERROR("Failed to enable scrambling: %d\n", ret); 182 + DRM_DEBUG_KMS("Failed to enable scrambling: %d\n", ret); 183 183 return false; 184 184 } 185 185 ··· 223 223 224 224 ret = drm_scdc_readb(adapter, SCDC_TMDS_CONFIG, &config); 225 225 if (ret < 0) { 226 - DRM_ERROR("Failed to read TMDS config: %d\n", ret); 226 + DRM_DEBUG_KMS("Failed to read TMDS config: %d\n", ret); 227 227 return false; 228 228 } 229 229 ··· 234 234 235 235 ret = drm_scdc_writeb(adapter, SCDC_TMDS_CONFIG, config); 236 236 if (ret < 0) { 237 - DRM_ERROR("Failed to set TMDS clock ratio: %d\n", ret); 237 + DRM_DEBUG_KMS("Failed to set TMDS clock ratio: %d\n", ret); 238 238 return false; 239 239 } 240 240