mail archive of the barebox mailing list
 help / color / mirror / Atom feed
* [PATCH v2] ARM: i.MX9: tqma93xx: workaround warning in variant detection
@ 2024-10-23 17:05 Ahmad Fatoum
  2024-10-25  6:33 ` Sascha Hauer
  0 siblings, 1 reply; 2+ messages in thread
From: Ahmad Fatoum @ 2024-10-23 17:05 UTC (permalink / raw)
  To: barebox; +Cc: Ahmad Fatoum

Some versions of GCC emit a false positive warning that fdt may be
uninitialized. This can't happen, so tell the compiler that.

Signed-off-by: Ahmad Fatoum <a.fatoum@pengutronix.de>
---
v1 -> v2:
  - removed warning and fallthrough to CONNECTOR case. As Sascha
    correctly notes, this path is impossible to reach and indeed
    new compiler versions don't warn about it, thus just tell the
    compiler that it's unreachable.
---
 arch/arm/boards/tqma93xx/lowlevel.c | 2 ++
 1 file changed, 2 insertions(+)

diff --git a/arch/arm/boards/tqma93xx/lowlevel.c b/arch/arm/boards/tqma93xx/lowlevel.c
index 8d89ee530ff8..14733d52a3c3 100644
--- a/arch/arm/boards/tqma93xx/lowlevel.c
+++ b/arch/arm/boards/tqma93xx/lowlevel.c
@@ -92,6 +92,8 @@ static noinline void tqma93xx_continue(void)
 	case VARD_FORMFACTOR_TYPE_CONNECTOR:
 		fdt = __dtb_z_imx93_tqma9352_mba93xxca_start;
 		break;
+	default:
+		__builtin_unreachable();
 	}
 
 	imx93_barebox_entry(fdt);
-- 
2.39.5




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

end of thread, other threads:[~2024-10-25  6:34 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2024-10-23 17:05 [PATCH v2] ARM: i.MX9: tqma93xx: workaround warning in variant detection Ahmad Fatoum
2024-10-25  6:33 ` Sascha Hauer

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox