Commit ccac8bab authored by Simon Ser's avatar Simon Ser Committed by Alex Deucher

drm/amd: use drm_dbg_kms to log addfb2 failures

Avoid printing an error with dev_err, because user-space can trigger
these at will by issuing an ioctl.

Convert a DRM_DEBUG_KMS call to the more modern drm_dbg_kms macro.
Signed-off-by: default avatarSimon Ser <contact@emersion.fr>
Cc: Alex Deucher <alexander.deucher@amd.com>
Cc: Harry Wentland <hwentlan@amd.com>
Cc: Nicholas Kazlauskas <nicholas.kazlauskas@amd.com>
Cc: Michel Dänzer <michel@daenzer.net>
Signed-off-by: default avatarAlex Deucher <alexander.deucher@amd.com>
parent e72868c4
...@@ -887,8 +887,8 @@ int amdgpu_display_framebuffer_init(struct drm_device *dev, ...@@ -887,8 +887,8 @@ int amdgpu_display_framebuffer_init(struct drm_device *dev,
*/ */
for (i = 1; i < rfb->base.format->num_planes; ++i) { for (i = 1; i < rfb->base.format->num_planes; ++i) {
if (mode_cmd->handles[i] != mode_cmd->handles[0]) { if (mode_cmd->handles[i] != mode_cmd->handles[0]) {
dev_err(&dev->pdev->dev, "Plane 0 and %d have different BOs: %u vs. %u\n", drm_dbg_kms(dev, "Plane 0 and %d have different BOs: %u vs. %u\n",
i, mode_cmd->handles[0], mode_cmd->handles[i]); i, mode_cmd->handles[0], mode_cmd->handles[i]);
ret = -EINVAL; ret = -EINVAL;
goto fail; goto fail;
} }
...@@ -928,14 +928,14 @@ amdgpu_display_user_framebuffer_create(struct drm_device *dev, ...@@ -928,14 +928,14 @@ amdgpu_display_user_framebuffer_create(struct drm_device *dev,
obj = drm_gem_object_lookup(file_priv, mode_cmd->handles[0]); obj = drm_gem_object_lookup(file_priv, mode_cmd->handles[0]);
if (obj == NULL) { if (obj == NULL) {
dev_err(&dev->pdev->dev, "No GEM object associated to handle 0x%08X, " drm_dbg_kms(dev, "No GEM object associated to handle 0x%08X, "
"can't create framebuffer\n", mode_cmd->handles[0]); "can't create framebuffer\n", mode_cmd->handles[0]);
return ERR_PTR(-ENOENT); return ERR_PTR(-ENOENT);
} }
/* Handle is imported dma-buf, so cannot be migrated to VRAM for scanout */ /* Handle is imported dma-buf, so cannot be migrated to VRAM for scanout */
if (obj->import_attach) { if (obj->import_attach) {
DRM_DEBUG_KMS("Cannot create framebuffer from imported dma_buf\n"); drm_dbg_kms(dev, "Cannot create framebuffer from imported dma_buf\n");
return ERR_PTR(-EINVAL); return ERR_PTR(-EINVAL);
} }
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment