Skip to contentSkip to conversation

drm/nouveau/therm: Fix fall-through warnings for Clang

PATCH RESEND Superseded Gustavo A. R. Silva 2 participants 4 messages Mar 5, 2021 – Jun 4, 2021

Subsystems (3)

v1 of 3 Superseded Latest is v3 →

lore
Share & tools
lore
#0 lore raw

PATCH RESEND 1/1 drm/nouveau/therm: Fix fall-through warnings for Clang

In preparation to enable -Wimplicit-fallthrough for Clang, fix a warning by explicitly adding a break statement instead of letting the code fall through to the next case.

---
 drivers/gpu/drm/nouveau/nvkm/subdev/therm/gf119.c | 1 +
 1 file changed, 1 insertion(+)
drivers/gpu/drm/nouveau/nvkm/subdev/therm/gf119.c +1 -0
index 2b031d4eaeb6..684aff7437ee 100644
@@ -41,6 +41,7 @@ pwm_info(struct nvkm_therm *therm, int line)
 		default:
 			break;
 		}
+		break;
 	default:
 		break;
 	}
Signature · 6 lines
2.27.0

_______________________________________________
dri-devel mailing list
[email protected]
https://lists.freedesktop.org/mailman/listinfo/dri-devel
#1 lore raw

Hi all,

Friendly ping: who can take this, please?

Thanks
--
Gustavo

Quoted 23 lines · Gustavo A. R. Silva

In preparation to enable -Wimplicit-fallthrough for Clang, fix a warning by explicitly adding a break statement instead of letting the code fall through to the next case.

---
 drivers/gpu/drm/nouveau/nvkm/subdev/therm/gf119.c | 1 +
 1 file changed, 1 insertion(+)
drivers/gpu/drm/nouveau/nvkm/subdev/therm/gf119.c +1 -0
index 2b031d4eaeb6..684aff7437ee 100644
@@ -41,6 +41,7 @@ pwm_info(struct nvkm_therm *therm, int line)
 		default:
 			break;
 		}
+		break;
 	default:
 		break;
 	}
#2 lore raw

Hi,

Friendly second ping: who can take this?

I can add this to my -next branch for 5.14 if you don't mind.

JFYI: We had thousands of these sorts of warnings and now we are down to just 23 in linux-next. This is one of those last remaining warnings.

Thanks
--
Gustavo

Quoted 32 lines · Gustavo A. R. Silva

Hi all,

Friendly ping: who can take this, please?

Thanks
--
Gustavo

Quoted 23 lines · Gustavo A. R. Silva

In preparation to enable -Wimplicit-fallthrough for Clang, fix a warning by explicitly adding a break statement instead of letting the code fall through to the next case.

---
 drivers/gpu/drm/nouveau/nvkm/subdev/therm/gf119.c | 1 +
 1 file changed, 1 insertion(+)
drivers/gpu/drm/nouveau/nvkm/subdev/therm/gf119.c +1 -0
index 2b031d4eaeb6..684aff7437ee 100644
@@ -41,6 +41,7 @@ pwm_info(struct nvkm_therm *therm, int line)
 		default:
 			break;
 		}
+		break;
 	default:
 		break;
 	}
#3 lore raw

Hi all,

If you don't mind, I'm taking this in my -next[1] branch for v5.14.

Thanks
--
Gustavo

[1] https://git.kernel.org/pub/scm/linux/kernel/git/gustavoars/linux.git/log/?h=for-next/kspp

Quoted 46 lines · Gustavo A. R. Silva

Hi,

Friendly second ping: who can take this?

I can add this to my -next branch for 5.14 if you don't mind.

JFYI: We had thousands of these sorts of warnings and now we are down to just 23 in linux-next. This is one of those last remaining warnings.

Thanks
--
Gustavo

Quoted 32 lines · Gustavo A. R. Silva

Hi all,

Friendly ping: who can take this, please?

Thanks
--
Gustavo

Quoted 23 lines · Gustavo A. R. Silva

In preparation to enable -Wimplicit-fallthrough for Clang, fix a warning by explicitly adding a break statement instead of letting the code fall through to the next case.

---
 drivers/gpu/drm/nouveau/nvkm/subdev/therm/gf119.c | 1 +
 1 file changed, 1 insertion(+)
drivers/gpu/drm/nouveau/nvkm/subdev/therm/gf119.c +1 -0
index 2b031d4eaeb6..684aff7437ee 100644
@@ -41,6 +41,7 @@ pwm_info(struct nvkm_therm *therm, int line)
 		default:
 			break;
 		}
+		break;
 	default:
 		break;
 	}