firmware/layer1: avoid 'for' loop initial declarations
commit7c60c5d6d95a059a50c85b68a5128c5cfd55f04c
authorVadim Yanitskiy <vyanitskiy@sysmocom.de>
Tue, 21 Nov 2023 10:03:19 +0000 (21 17:03 +0700)
committerVadim Yanitskiy <vyanitskiy@sysmocom.de>
Tue, 21 Nov 2023 10:04:10 +0000 (21 17:04 +0700)
tree11857885d792f78443b86aa7a8aeba8d47fa37f7
parentc56247071cc6faf8bcbbb511795d1e39aa87a0de
firmware/layer1: avoid 'for' loop initial declarations

As was reported by roox, osmocom-bb currently fails to build on OBS:

https://build.opensuse.org/build/home:mnhauke:osmocom:nightly/openSUSE_Tumbleweed/x86_64/osmocom-bb/_log

[   24s] layer1/prim_tch.c: In function 'l1s_tch_meas_avg':
[   24s] layer1/prim_tch.c:183:2: error: 'for' loop initial declarations are only allowed in C99 mode
[   24s] layer1/prim_tch.c:183:2: note: use option -std=c99 or -std=gnu99 to compile your code

We don't specify the C standard explicitly, so let's move the variable
declaration out of the for-loop in l1s_tch_meas_avg().

Change-Id: I6c65fbead4e612c81728e9c6601d5f2107616ee6
Fixes: 7286560a3 "firmware/layer1: fill-in DL info for L1CTL TRAFFIC.ind"
src/target/firmware/layer1/prim_tch.c