[PATCH 1/3] drm/plane: Clean up 0 vs NULL issue

Dan Carpenter posted 3 patches 1 month, 2 weeks ago
[PATCH 1/3] drm/plane: Clean up 0 vs NULL issue
Posted by Dan Carpenter 1 month, 2 weeks ago
The create_in_format_blob() function returns pointers, not integers.
Change the zero to a NULL.

Signed-off-by: Dan Carpenter <dan.carpenter@linaro.org>
---
 drivers/gpu/drm/drm_plane.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/drivers/gpu/drm/drm_plane.c b/drivers/gpu/drm/drm_plane.c
index 38f82391bfda..ad21fc855aea 100644
--- a/drivers/gpu/drm/drm_plane.c
+++ b/drivers/gpu/drm/drm_plane.c
@@ -210,7 +210,7 @@ static struct drm_property_blob *create_in_format_blob(struct drm_device *dev,
 	formats_size = sizeof(__u32) * plane->format_count;
 	if (WARN_ON(!formats_size)) {
 		/* 0 formats are never expected */
-		return 0;
+		return NULL;
 	}
 
 	modifiers_size =
-- 
2.47.2