Skip to contentSkip to conversation

drm/tegra/fb: Delete an error message for a failed memory allocation in tegra_fbdev_create()

PATCH New SF Markus Elfring 1 participant 1 message Feb 7, 2018

Subsystems (4)
lore
Share & tools
lore
#0 lore raw

PATCH 1/1 drm/tegra/fb: Delete an error message for a failed memory allocation in tegra_fbdev_create()

From: Markus Elfring <[email protected]>
Date: Wed, 7 Feb 2018 21:17:17 +0100

Omit an extra message for a memory allocation failure in this function.

This issue was detected by using the Coccinelle software.

---
 drivers/gpu/drm/tegra/fb.c | 4 +---
 1 file changed, 1 insertion(+), 3 deletions(-)
drivers/gpu/drm/tegra/fb.c +1 -3
index 001cb77e2f59..e63a0b228751 100644
@@ -325,10 +325,8 @@ static struct tegra_fbdev *tegra_fbdev_create(struct drm_device *drm)
 	struct tegra_fbdev *fbdev;
 
 	fbdev = kzalloc(sizeof(*fbdev), GFP_KERNEL);
-	if (!fbdev) {
-		dev_err(drm->dev, "failed to allocate DRM fbdev\n");
+	if (!fbdev)
 		return ERR_PTR(-ENOMEM);
-	}
 
 	drm_fb_helper_prepare(drm, &fbdev->base, &tegra_fb_helper_funcs);
 
Signature · 1 line
2.16.1