All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH v2 0/4] drm: Fix errors about uninitialized/wrong variables
@ 2023-11-03 13:14 ` Tomi Valkeinen
  0 siblings, 0 replies; 14+ messages in thread
From: Tomi Valkeinen @ 2023-11-03 13:14 UTC (permalink / raw)
  To: Maarten Lankhorst, Maxime Ripard, Thomas Zimmermann,
	David Airlie, Daniel Vetter, Laurent Pinchart, Francesco Dolcini,
	Andrzej Hajda, Neil Armstrong, Robert Foss, Jonas Karlman,
	Jernej Skrabec, Parshuram Thombare
  Cc: Tomi Valkeinen, Laurent Pinchart, linux-kernel, dri-devel

Fix cases where smatch reports a use of an uninitialized variable, and
one where the variable is initialized but contains wrong value.

 Tomi

Signed-off-by: Tomi Valkeinen <tomi.valkeinen@ideasonboard.com>
---
Changes in v2:
- Added two more fixes
- Link to v1: https://lore.kernel.org/r/20230804-uninit-fixes-v1-0-a60772c04db5@ideasonboard.com

---
Tomi Valkeinen (4):
      drm/drm_file: fix use of uninitialized variable
      drm/framebuffer: Fix use of uninitialized variable
      drm/bridge: cdns-mhdp8546: Fix use of uninitialized variable
      drm/bridge: tc358767: Fix return value on error case

 drivers/gpu/drm/bridge/cadence/cdns-mhdp8546-hdcp.c | 3 ++-
 drivers/gpu/drm/bridge/tc358767.c                   | 2 +-
 drivers/gpu/drm/drm_file.c                          | 2 +-
 drivers/gpu/drm/drm_framebuffer.c                   | 2 +-
 4 files changed, 5 insertions(+), 4 deletions(-)
---
base-commit: 9d7c8c066916f231ca0ed4e4fce6c4b58ca3e451
change-id: 20230804-uninit-fixes-188f92d60ac3

Best regards,
-- 
Tomi Valkeinen <tomi.valkeinen@ideasonboard.com>


^ permalink raw reply	[flat|nested] 14+ messages in thread

* [PATCH v2 0/4] drm: Fix errors about uninitialized/wrong variables
@ 2023-11-03 13:14 ` Tomi Valkeinen
  0 siblings, 0 replies; 14+ messages in thread
From: Tomi Valkeinen @ 2023-11-03 13:14 UTC (permalink / raw)
  To: Maarten Lankhorst, Maxime Ripard, Thomas Zimmermann,
	David Airlie, Daniel Vetter, Laurent Pinchart, Francesco Dolcini,
	Andrzej Hajda, Neil Armstrong, Robert Foss, Jonas Karlman,
	Jernej Skrabec, Parshuram Thombare
  Cc: dri-devel, linux-kernel, Tomi Valkeinen, Laurent Pinchart

Fix cases where smatch reports a use of an uninitialized variable, and
one where the variable is initialized but contains wrong value.

 Tomi

Signed-off-by: Tomi Valkeinen <tomi.valkeinen@ideasonboard.com>
---
Changes in v2:
- Added two more fixes
- Link to v1: https://lore.kernel.org/r/20230804-uninit-fixes-v1-0-a60772c04db5@ideasonboard.com

---
Tomi Valkeinen (4):
      drm/drm_file: fix use of uninitialized variable
      drm/framebuffer: Fix use of uninitialized variable
      drm/bridge: cdns-mhdp8546: Fix use of uninitialized variable
      drm/bridge: tc358767: Fix return value on error case

 drivers/gpu/drm/bridge/cadence/cdns-mhdp8546-hdcp.c | 3 ++-
 drivers/gpu/drm/bridge/tc358767.c                   | 2 +-
 drivers/gpu/drm/drm_file.c                          | 2 +-
 drivers/gpu/drm/drm_framebuffer.c                   | 2 +-
 4 files changed, 5 insertions(+), 4 deletions(-)
---
base-commit: 9d7c8c066916f231ca0ed4e4fce6c4b58ca3e451
change-id: 20230804-uninit-fixes-188f92d60ac3

Best regards,
-- 
Tomi Valkeinen <tomi.valkeinen@ideasonboard.com>


^ permalink raw reply	[flat|nested] 14+ messages in thread

* [PATCH v2 1/4] drm/drm_file: fix use of uninitialized variable
  2023-11-03 13:14 ` Tomi Valkeinen
@ 2023-11-03 13:14   ` Tomi Valkeinen
  -1 siblings, 0 replies; 14+ messages in thread
From: Tomi Valkeinen @ 2023-11-03 13:14 UTC (permalink / raw)
  To: Maarten Lankhorst, Maxime Ripard, Thomas Zimmermann,
	David Airlie, Daniel Vetter, Laurent Pinchart, Francesco Dolcini,
	Andrzej Hajda, Neil Armstrong, Robert Foss, Jonas Karlman,
	Jernej Skrabec, Parshuram Thombare
  Cc: dri-devel, linux-kernel, Tomi Valkeinen, Laurent Pinchart

smatch reports:

drivers/gpu/drm/drm_file.c:967 drm_show_memory_stats() error: uninitialized symbol 'supported_status'.

'supported_status' is only set in one code path. I'm not familiar with
the code to say if that path will always be ran in real life, but
whether that is the case or not, I think it is good to initialize
'supported_status' to 0 to silence the warning (and possibly fix a bug).

Reviewed-by: Laurent Pinchart <laurent.pinchart+renesas@ideasonboard.com>
Signed-off-by: Tomi Valkeinen <tomi.valkeinen@ideasonboard.com>
---
 drivers/gpu/drm/drm_file.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/drivers/gpu/drm/drm_file.c b/drivers/gpu/drm/drm_file.c
index 446458aca8e9..54a7103c1c0f 100644
--- a/drivers/gpu/drm/drm_file.c
+++ b/drivers/gpu/drm/drm_file.c
@@ -958,7 +958,7 @@ void drm_show_memory_stats(struct drm_printer *p, struct drm_file *file)
 {
 	struct drm_gem_object *obj;
 	struct drm_memory_stats status = {};
-	enum drm_gem_object_status supported_status;
+	enum drm_gem_object_status supported_status = 0;
 	int id;
 
 	spin_lock(&file->table_lock);

-- 
2.34.1


^ permalink raw reply related	[flat|nested] 14+ messages in thread

* [PATCH v2 1/4] drm/drm_file: fix use of uninitialized variable
@ 2023-11-03 13:14   ` Tomi Valkeinen
  0 siblings, 0 replies; 14+ messages in thread
From: Tomi Valkeinen @ 2023-11-03 13:14 UTC (permalink / raw)
  To: Maarten Lankhorst, Maxime Ripard, Thomas Zimmermann,
	David Airlie, Daniel Vetter, Laurent Pinchart, Francesco Dolcini,
	Andrzej Hajda, Neil Armstrong, Robert Foss, Jonas Karlman,
	Jernej Skrabec, Parshuram Thombare
  Cc: Tomi Valkeinen, Laurent Pinchart, linux-kernel, dri-devel

smatch reports:

drivers/gpu/drm/drm_file.c:967 drm_show_memory_stats() error: uninitialized symbol 'supported_status'.

'supported_status' is only set in one code path. I'm not familiar with
the code to say if that path will always be ran in real life, but
whether that is the case or not, I think it is good to initialize
'supported_status' to 0 to silence the warning (and possibly fix a bug).

Reviewed-by: Laurent Pinchart <laurent.pinchart+renesas@ideasonboard.com>
Signed-off-by: Tomi Valkeinen <tomi.valkeinen@ideasonboard.com>
---
 drivers/gpu/drm/drm_file.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/drivers/gpu/drm/drm_file.c b/drivers/gpu/drm/drm_file.c
index 446458aca8e9..54a7103c1c0f 100644
--- a/drivers/gpu/drm/drm_file.c
+++ b/drivers/gpu/drm/drm_file.c
@@ -958,7 +958,7 @@ void drm_show_memory_stats(struct drm_printer *p, struct drm_file *file)
 {
 	struct drm_gem_object *obj;
 	struct drm_memory_stats status = {};
-	enum drm_gem_object_status supported_status;
+	enum drm_gem_object_status supported_status = 0;
 	int id;
 
 	spin_lock(&file->table_lock);

-- 
2.34.1


^ permalink raw reply related	[flat|nested] 14+ messages in thread

* [PATCH v2 2/4] drm/framebuffer: Fix use of uninitialized variable
  2023-11-03 13:14 ` Tomi Valkeinen
@ 2023-11-03 13:14   ` Tomi Valkeinen
  -1 siblings, 0 replies; 14+ messages in thread
From: Tomi Valkeinen @ 2023-11-03 13:14 UTC (permalink / raw)
  To: Maarten Lankhorst, Maxime Ripard, Thomas Zimmermann,
	David Airlie, Daniel Vetter, Laurent Pinchart, Francesco Dolcini,
	Andrzej Hajda, Neil Armstrong, Robert Foss, Jonas Karlman,
	Jernej Skrabec, Parshuram Thombare
  Cc: Tomi Valkeinen, Laurent Pinchart, linux-kernel, dri-devel

smatch reports:

drivers/gpu/drm/drm_framebuffer.c:654 drm_mode_getfb2_ioctl() error: uninitialized symbol 'ret'.

'ret' is possibly not set when there are no errors, causing the error
above. I can't say if that ever happens in real-life, but in any case I
think it is good to initialize 'ret' to 0.

Reviewed-by: Laurent Pinchart <laurent.pinchart+renesas@ideasonboard.com>
Signed-off-by: Tomi Valkeinen <tomi.valkeinen@ideasonboard.com>
---
 drivers/gpu/drm/drm_framebuffer.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/drivers/gpu/drm/drm_framebuffer.c b/drivers/gpu/drm/drm_framebuffer.c
index 09e289fca5c3..3cc0ffc28e86 100644
--- a/drivers/gpu/drm/drm_framebuffer.c
+++ b/drivers/gpu/drm/drm_framebuffer.c
@@ -583,7 +583,7 @@ int drm_mode_getfb2_ioctl(struct drm_device *dev,
 	struct drm_mode_fb_cmd2 *r = data;
 	struct drm_framebuffer *fb;
 	unsigned int i;
-	int ret;
+	int ret = 0;
 
 	if (!drm_core_check_feature(dev, DRIVER_MODESET))
 		return -EINVAL;

-- 
2.34.1


^ permalink raw reply related	[flat|nested] 14+ messages in thread

* [PATCH v2 2/4] drm/framebuffer: Fix use of uninitialized variable
@ 2023-11-03 13:14   ` Tomi Valkeinen
  0 siblings, 0 replies; 14+ messages in thread
From: Tomi Valkeinen @ 2023-11-03 13:14 UTC (permalink / raw)
  To: Maarten Lankhorst, Maxime Ripard, Thomas Zimmermann,
	David Airlie, Daniel Vetter, Laurent Pinchart, Francesco Dolcini,
	Andrzej Hajda, Neil Armstrong, Robert Foss, Jonas Karlman,
	Jernej Skrabec, Parshuram Thombare
  Cc: dri-devel, linux-kernel, Tomi Valkeinen, Laurent Pinchart

smatch reports:

drivers/gpu/drm/drm_framebuffer.c:654 drm_mode_getfb2_ioctl() error: uninitialized symbol 'ret'.

'ret' is possibly not set when there are no errors, causing the error
above. I can't say if that ever happens in real-life, but in any case I
think it is good to initialize 'ret' to 0.

Reviewed-by: Laurent Pinchart <laurent.pinchart+renesas@ideasonboard.com>
Signed-off-by: Tomi Valkeinen <tomi.valkeinen@ideasonboard.com>
---
 drivers/gpu/drm/drm_framebuffer.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/drivers/gpu/drm/drm_framebuffer.c b/drivers/gpu/drm/drm_framebuffer.c
index 09e289fca5c3..3cc0ffc28e86 100644
--- a/drivers/gpu/drm/drm_framebuffer.c
+++ b/drivers/gpu/drm/drm_framebuffer.c
@@ -583,7 +583,7 @@ int drm_mode_getfb2_ioctl(struct drm_device *dev,
 	struct drm_mode_fb_cmd2 *r = data;
 	struct drm_framebuffer *fb;
 	unsigned int i;
-	int ret;
+	int ret = 0;
 
 	if (!drm_core_check_feature(dev, DRIVER_MODESET))
 		return -EINVAL;

-- 
2.34.1


^ permalink raw reply related	[flat|nested] 14+ messages in thread

* [PATCH v2 3/4] drm/bridge: cdns-mhdp8546: Fix use of uninitialized variable
  2023-11-03 13:14 ` Tomi Valkeinen
@ 2023-11-03 13:14   ` Tomi Valkeinen
  -1 siblings, 0 replies; 14+ messages in thread
From: Tomi Valkeinen @ 2023-11-03 13:14 UTC (permalink / raw)
  To: Maarten Lankhorst, Maxime Ripard, Thomas Zimmermann,
	David Airlie, Daniel Vetter, Laurent Pinchart, Francesco Dolcini,
	Andrzej Hajda, Neil Armstrong, Robert Foss, Jonas Karlman,
	Jernej Skrabec, Parshuram Thombare
  Cc: Tomi Valkeinen, linux-kernel, dri-devel

'ret' could be uninitialized at the end of the function, although it's
not clear if that can happen in practice.

Fixes: 6a3608eae6d3 ("drm: bridge: cdns-mhdp8546: Enable HDCP")
Signed-off-by: Tomi Valkeinen <tomi.valkeinen@ideasonboard.com>
---
 drivers/gpu/drm/bridge/cadence/cdns-mhdp8546-hdcp.c | 3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)

diff --git a/drivers/gpu/drm/bridge/cadence/cdns-mhdp8546-hdcp.c b/drivers/gpu/drm/bridge/cadence/cdns-mhdp8546-hdcp.c
index 946212a95598..5e3b8edcf794 100644
--- a/drivers/gpu/drm/bridge/cadence/cdns-mhdp8546-hdcp.c
+++ b/drivers/gpu/drm/bridge/cadence/cdns-mhdp8546-hdcp.c
@@ -403,7 +403,8 @@ static int _cdns_mhdp_hdcp_disable(struct cdns_mhdp_device *mhdp)
 
 static int _cdns_mhdp_hdcp_enable(struct cdns_mhdp_device *mhdp, u8 content_type)
 {
-	int ret, tries = 3;
+	int ret = -EINVAL;
+	int tries = 3;
 	u32 i;
 
 	for (i = 0; i < tries; i++) {

-- 
2.34.1


^ permalink raw reply related	[flat|nested] 14+ messages in thread

* [PATCH v2 3/4] drm/bridge: cdns-mhdp8546: Fix use of uninitialized variable
@ 2023-11-03 13:14   ` Tomi Valkeinen
  0 siblings, 0 replies; 14+ messages in thread
From: Tomi Valkeinen @ 2023-11-03 13:14 UTC (permalink / raw)
  To: Maarten Lankhorst, Maxime Ripard, Thomas Zimmermann,
	David Airlie, Daniel Vetter, Laurent Pinchart, Francesco Dolcini,
	Andrzej Hajda, Neil Armstrong, Robert Foss, Jonas Karlman,
	Jernej Skrabec, Parshuram Thombare
  Cc: dri-devel, linux-kernel, Tomi Valkeinen

'ret' could be uninitialized at the end of the function, although it's
not clear if that can happen in practice.

Fixes: 6a3608eae6d3 ("drm: bridge: cdns-mhdp8546: Enable HDCP")
Signed-off-by: Tomi Valkeinen <tomi.valkeinen@ideasonboard.com>
---
 drivers/gpu/drm/bridge/cadence/cdns-mhdp8546-hdcp.c | 3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)

diff --git a/drivers/gpu/drm/bridge/cadence/cdns-mhdp8546-hdcp.c b/drivers/gpu/drm/bridge/cadence/cdns-mhdp8546-hdcp.c
index 946212a95598..5e3b8edcf794 100644
--- a/drivers/gpu/drm/bridge/cadence/cdns-mhdp8546-hdcp.c
+++ b/drivers/gpu/drm/bridge/cadence/cdns-mhdp8546-hdcp.c
@@ -403,7 +403,8 @@ static int _cdns_mhdp_hdcp_disable(struct cdns_mhdp_device *mhdp)
 
 static int _cdns_mhdp_hdcp_enable(struct cdns_mhdp_device *mhdp, u8 content_type)
 {
-	int ret, tries = 3;
+	int ret = -EINVAL;
+	int tries = 3;
 	u32 i;
 
 	for (i = 0; i < tries; i++) {

-- 
2.34.1


^ permalink raw reply related	[flat|nested] 14+ messages in thread

* [PATCH v2 4/4] drm/bridge: tc358767: Fix return value on error case
  2023-11-03 13:14 ` Tomi Valkeinen
@ 2023-11-03 13:14   ` Tomi Valkeinen
  -1 siblings, 0 replies; 14+ messages in thread
From: Tomi Valkeinen @ 2023-11-03 13:14 UTC (permalink / raw)
  To: Maarten Lankhorst, Maxime Ripard, Thomas Zimmermann,
	David Airlie, Daniel Vetter, Laurent Pinchart, Francesco Dolcini,
	Andrzej Hajda, Neil Armstrong, Robert Foss, Jonas Karlman,
	Jernej Skrabec, Parshuram Thombare
  Cc: Tomi Valkeinen, linux-kernel, dri-devel

If the hpd_pin is invalid, the driver returns 'ret'. But 'ret' contains
0, instead of an error value.

Return -EINVAL instead.

Fixes: f25ee5017e4f ("drm/bridge: tc358767: add IRQ and HPD support")
Signed-off-by: Tomi Valkeinen <tomi.valkeinen@ideasonboard.com>
---
 drivers/gpu/drm/bridge/tc358767.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/drivers/gpu/drm/bridge/tc358767.c b/drivers/gpu/drm/bridge/tc358767.c
index ef2e373606ba..615cc8f950d7 100644
--- a/drivers/gpu/drm/bridge/tc358767.c
+++ b/drivers/gpu/drm/bridge/tc358767.c
@@ -2273,7 +2273,7 @@ static int tc_probe(struct i2c_client *client)
 	} else {
 		if (tc->hpd_pin < 0 || tc->hpd_pin > 1) {
 			dev_err(dev, "failed to parse HPD number\n");
-			return ret;
+			return -EINVAL;
 		}
 	}
 

-- 
2.34.1


^ permalink raw reply related	[flat|nested] 14+ messages in thread

* [PATCH v2 4/4] drm/bridge: tc358767: Fix return value on error case
@ 2023-11-03 13:14   ` Tomi Valkeinen
  0 siblings, 0 replies; 14+ messages in thread
From: Tomi Valkeinen @ 2023-11-03 13:14 UTC (permalink / raw)
  To: Maarten Lankhorst, Maxime Ripard, Thomas Zimmermann,
	David Airlie, Daniel Vetter, Laurent Pinchart, Francesco Dolcini,
	Andrzej Hajda, Neil Armstrong, Robert Foss, Jonas Karlman,
	Jernej Skrabec, Parshuram Thombare
  Cc: dri-devel, linux-kernel, Tomi Valkeinen

If the hpd_pin is invalid, the driver returns 'ret'. But 'ret' contains
0, instead of an error value.

Return -EINVAL instead.

Fixes: f25ee5017e4f ("drm/bridge: tc358767: add IRQ and HPD support")
Signed-off-by: Tomi Valkeinen <tomi.valkeinen@ideasonboard.com>
---
 drivers/gpu/drm/bridge/tc358767.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/drivers/gpu/drm/bridge/tc358767.c b/drivers/gpu/drm/bridge/tc358767.c
index ef2e373606ba..615cc8f950d7 100644
--- a/drivers/gpu/drm/bridge/tc358767.c
+++ b/drivers/gpu/drm/bridge/tc358767.c
@@ -2273,7 +2273,7 @@ static int tc_probe(struct i2c_client *client)
 	} else {
 		if (tc->hpd_pin < 0 || tc->hpd_pin > 1) {
 			dev_err(dev, "failed to parse HPD number\n");
-			return ret;
+			return -EINVAL;
 		}
 	}
 

-- 
2.34.1


^ permalink raw reply related	[flat|nested] 14+ messages in thread

* Re: [PATCH v2 0/4] drm: Fix errors about uninitialized/wrong variables
  2023-11-03 13:14 ` Tomi Valkeinen
@ 2023-12-06 12:50   ` Tomi Valkeinen
  -1 siblings, 0 replies; 14+ messages in thread
From: Tomi Valkeinen @ 2023-12-06 12:50 UTC (permalink / raw)
  To: Maarten Lankhorst, Maxime Ripard, Thomas Zimmermann,
	David Airlie, Daniel Vetter, Laurent Pinchart, Francesco Dolcini,
	Andrzej Hajda, Neil Armstrong, Robert Foss, Jonas Karlman,
	Jernej Skrabec, Parshuram Thombare
  Cc: dri-devel, linux-kernel, Laurent Pinchart

Hi all,

On 03/11/2023 15:14, Tomi Valkeinen wrote:
> Fix cases where smatch reports a use of an uninitialized variable, and
> one where the variable is initialized but contains wrong value.
> 
>   Tomi
> 
> Signed-off-by: Tomi Valkeinen <tomi.valkeinen@ideasonboard.com>
> ---
> Changes in v2:
> - Added two more fixes
> - Link to v1: https://lore.kernel.org/r/20230804-uninit-fixes-v1-0-a60772c04db5@ideasonboard.com
> 
> ---
> Tomi Valkeinen (4):
>        drm/drm_file: fix use of uninitialized variable
>        drm/framebuffer: Fix use of uninitialized variable
>        drm/bridge: cdns-mhdp8546: Fix use of uninitialized variable
>        drm/bridge: tc358767: Fix return value on error case
> 
>   drivers/gpu/drm/bridge/cadence/cdns-mhdp8546-hdcp.c | 3 ++-
>   drivers/gpu/drm/bridge/tc358767.c                   | 2 +-
>   drivers/gpu/drm/drm_file.c                          | 2 +-
>   drivers/gpu/drm/drm_framebuffer.c                   | 2 +-
>   4 files changed, 5 insertions(+), 4 deletions(-)
> ---
> base-commit: 9d7c8c066916f231ca0ed4e4fce6c4b58ca3e451
> change-id: 20230804-uninit-fixes-188f92d60ac3
> 
> Best regards,

Ping on this (or I'll forget the series...).

  Tomi


^ permalink raw reply	[flat|nested] 14+ messages in thread

* Re: [PATCH v2 0/4] drm: Fix errors about uninitialized/wrong variables
@ 2023-12-06 12:50   ` Tomi Valkeinen
  0 siblings, 0 replies; 14+ messages in thread
From: Tomi Valkeinen @ 2023-12-06 12:50 UTC (permalink / raw)
  To: Maarten Lankhorst, Maxime Ripard, Thomas Zimmermann,
	David Airlie, Daniel Vetter, Laurent Pinchart, Francesco Dolcini,
	Andrzej Hajda, Neil Armstrong, Robert Foss, Jonas Karlman,
	Jernej Skrabec, Parshuram Thombare
  Cc: Laurent Pinchart, linux-kernel, dri-devel

Hi all,

On 03/11/2023 15:14, Tomi Valkeinen wrote:
> Fix cases where smatch reports a use of an uninitialized variable, and
> one where the variable is initialized but contains wrong value.
> 
>   Tomi
> 
> Signed-off-by: Tomi Valkeinen <tomi.valkeinen@ideasonboard.com>
> ---
> Changes in v2:
> - Added two more fixes
> - Link to v1: https://lore.kernel.org/r/20230804-uninit-fixes-v1-0-a60772c04db5@ideasonboard.com
> 
> ---
> Tomi Valkeinen (4):
>        drm/drm_file: fix use of uninitialized variable
>        drm/framebuffer: Fix use of uninitialized variable
>        drm/bridge: cdns-mhdp8546: Fix use of uninitialized variable
>        drm/bridge: tc358767: Fix return value on error case
> 
>   drivers/gpu/drm/bridge/cadence/cdns-mhdp8546-hdcp.c | 3 ++-
>   drivers/gpu/drm/bridge/tc358767.c                   | 2 +-
>   drivers/gpu/drm/drm_file.c                          | 2 +-
>   drivers/gpu/drm/drm_framebuffer.c                   | 2 +-
>   4 files changed, 5 insertions(+), 4 deletions(-)
> ---
> base-commit: 9d7c8c066916f231ca0ed4e4fce6c4b58ca3e451
> change-id: 20230804-uninit-fixes-188f92d60ac3
> 
> Best regards,

Ping on this (or I'll forget the series...).

  Tomi


^ permalink raw reply	[flat|nested] 14+ messages in thread

* Re: [PATCH v2 0/4] drm: Fix errors about uninitialized/wrong variables
  2023-12-06 12:50   ` Tomi Valkeinen
@ 2023-12-06 14:31     ` Maxime Ripard
  -1 siblings, 0 replies; 14+ messages in thread
From: Maxime Ripard @ 2023-12-06 14:31 UTC (permalink / raw)
  To: Tomi Valkeinen
  Cc: Maarten Lankhorst, Thomas Zimmermann, David Airlie,
	Daniel Vetter, Laurent Pinchart, Francesco Dolcini,
	Andrzej Hajda, Neil Armstrong, Robert Foss, Jonas Karlman,
	Jernej Skrabec, Parshuram Thombare, dri-devel, linux-kernel,
	Laurent Pinchart

[-- Attachment #1: Type: text/plain, Size: 1405 bytes --]

On Wed, Dec 06, 2023 at 02:50:57PM +0200, Tomi Valkeinen wrote:
> Hi all,
> 
> On 03/11/2023 15:14, Tomi Valkeinen wrote:
> > Fix cases where smatch reports a use of an uninitialized variable, and
> > one where the variable is initialized but contains wrong value.
> > 
> >   Tomi
> > 
> > Signed-off-by: Tomi Valkeinen <tomi.valkeinen@ideasonboard.com>
> > ---
> > Changes in v2:
> > - Added two more fixes
> > - Link to v1: https://lore.kernel.org/r/20230804-uninit-fixes-v1-0-a60772c04db5@ideasonboard.com
> > 
> > ---
> > Tomi Valkeinen (4):
> >        drm/drm_file: fix use of uninitialized variable
> >        drm/framebuffer: Fix use of uninitialized variable
> >        drm/bridge: cdns-mhdp8546: Fix use of uninitialized variable
> >        drm/bridge: tc358767: Fix return value on error case
> > 
> >   drivers/gpu/drm/bridge/cadence/cdns-mhdp8546-hdcp.c | 3 ++-
> >   drivers/gpu/drm/bridge/tc358767.c                   | 2 +-
> >   drivers/gpu/drm/drm_file.c                          | 2 +-
> >   drivers/gpu/drm/drm_framebuffer.c                   | 2 +-
> >   4 files changed, 5 insertions(+), 4 deletions(-)
> > ---
> > base-commit: 9d7c8c066916f231ca0ed4e4fce6c4b58ca3e451
> > change-id: 20230804-uninit-fixes-188f92d60ac3
> > 
> > Best regards,
> 
> Ping on this (or I'll forget the series...).

Acked-by: Maxime Ripard <mripard@kernel.org>

Maxime

[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 228 bytes --]

^ permalink raw reply	[flat|nested] 14+ messages in thread

* Re: [PATCH v2 0/4] drm: Fix errors about uninitialized/wrong variables
@ 2023-12-06 14:31     ` Maxime Ripard
  0 siblings, 0 replies; 14+ messages in thread
From: Maxime Ripard @ 2023-12-06 14:31 UTC (permalink / raw)
  To: Tomi Valkeinen
  Cc: Neil Armstrong, Laurent Pinchart, Robert Foss, Thomas Zimmermann,
	Jonas Karlman, dri-devel, Parshuram Thombare, linux-kernel,
	Jernej Skrabec, Andrzej Hajda, Laurent Pinchart,
	Francesco Dolcini

[-- Attachment #1: Type: text/plain, Size: 1405 bytes --]

On Wed, Dec 06, 2023 at 02:50:57PM +0200, Tomi Valkeinen wrote:
> Hi all,
> 
> On 03/11/2023 15:14, Tomi Valkeinen wrote:
> > Fix cases where smatch reports a use of an uninitialized variable, and
> > one where the variable is initialized but contains wrong value.
> > 
> >   Tomi
> > 
> > Signed-off-by: Tomi Valkeinen <tomi.valkeinen@ideasonboard.com>
> > ---
> > Changes in v2:
> > - Added two more fixes
> > - Link to v1: https://lore.kernel.org/r/20230804-uninit-fixes-v1-0-a60772c04db5@ideasonboard.com
> > 
> > ---
> > Tomi Valkeinen (4):
> >        drm/drm_file: fix use of uninitialized variable
> >        drm/framebuffer: Fix use of uninitialized variable
> >        drm/bridge: cdns-mhdp8546: Fix use of uninitialized variable
> >        drm/bridge: tc358767: Fix return value on error case
> > 
> >   drivers/gpu/drm/bridge/cadence/cdns-mhdp8546-hdcp.c | 3 ++-
> >   drivers/gpu/drm/bridge/tc358767.c                   | 2 +-
> >   drivers/gpu/drm/drm_file.c                          | 2 +-
> >   drivers/gpu/drm/drm_framebuffer.c                   | 2 +-
> >   4 files changed, 5 insertions(+), 4 deletions(-)
> > ---
> > base-commit: 9d7c8c066916f231ca0ed4e4fce6c4b58ca3e451
> > change-id: 20230804-uninit-fixes-188f92d60ac3
> > 
> > Best regards,
> 
> Ping on this (or I'll forget the series...).

Acked-by: Maxime Ripard <mripard@kernel.org>

Maxime

[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 228 bytes --]

^ permalink raw reply	[flat|nested] 14+ messages in thread

end of thread, other threads:[~2023-12-06 14:31 UTC | newest]

Thread overview: 14+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2023-11-03 13:14 [PATCH v2 0/4] drm: Fix errors about uninitialized/wrong variables Tomi Valkeinen
2023-11-03 13:14 ` Tomi Valkeinen
2023-11-03 13:14 ` [PATCH v2 1/4] drm/drm_file: fix use of uninitialized variable Tomi Valkeinen
2023-11-03 13:14   ` Tomi Valkeinen
2023-11-03 13:14 ` [PATCH v2 2/4] drm/framebuffer: Fix " Tomi Valkeinen
2023-11-03 13:14   ` Tomi Valkeinen
2023-11-03 13:14 ` [PATCH v2 3/4] drm/bridge: cdns-mhdp8546: " Tomi Valkeinen
2023-11-03 13:14   ` Tomi Valkeinen
2023-11-03 13:14 ` [PATCH v2 4/4] drm/bridge: tc358767: Fix return value on error case Tomi Valkeinen
2023-11-03 13:14   ` Tomi Valkeinen
2023-12-06 12:50 ` [PATCH v2 0/4] drm: Fix errors about uninitialized/wrong variables Tomi Valkeinen
2023-12-06 12:50   ` Tomi Valkeinen
2023-12-06 14:31   ` Maxime Ripard
2023-12-06 14:31     ` Maxime Ripard

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.