aboutsummaryrefslogtreecommitdiffstats
path: root/src/osmo-bts-sysmo/misc/sysmobts_par.c
diff options
context:
space:
mode:
authorHolger Hans Peter Freyther <holger@moiji-mobile.com>2016-07-01 18:16:13 +0200
committerHolger Hans Peter Freyther <holger@moiji-mobile.com>2016-07-02 10:52:01 +0200
commitf41e1ae11b604d2146b658639d732eef61c3dbb0 (patch)
tree604009408a2746a761070b80ca92a99aebfb5090 /src/osmo-bts-sysmo/misc/sysmobts_par.c
parentf4cefcfb15003aeb43fd284ce94c4cbbbf7f4b94 (diff)
sysmobts: Fix eeprom padding before gpg key
Correct the too short padding I introduced in the commit a55b166c6c7af79cbefe8e65fe77b2d61c634d2d. The result needs to be 121 and not 120. Add static asserts to make sure it does not happen again. Change-Id: Icaaf520a280ee58c483fa64df4e447702ec746ac
Diffstat (limited to 'src/osmo-bts-sysmo/misc/sysmobts_par.c')
-rw-r--r--src/osmo-bts-sysmo/misc/sysmobts_par.c6
1 files changed, 6 insertions, 0 deletions
diff --git a/src/osmo-bts-sysmo/misc/sysmobts_par.c b/src/osmo-bts-sysmo/misc/sysmobts_par.c
index 6800fded..d1fc37a2 100644
--- a/src/osmo-bts-sysmo/misc/sysmobts_par.c
+++ b/src/osmo-bts-sysmo/misc/sysmobts_par.c
@@ -19,6 +19,7 @@
*
*/
+#include <stddef.h>
#include <stdio.h>
#include <stdlib.h>
#include <stdint.h>
@@ -289,3 +290,8 @@ int sysmobts_par_set_buf(enum sysmobts_par par, const uint8_t *buf,
return len;
}
+
+osmo_static_assert(offsetof(struct sysmobts_eeprom, trx_nr) == 36, offset_36);
+osmo_static_assert(offsetof(struct sysmobts_eeprom, boot_state) == 37, offset_37);
+osmo_static_assert(offsetof(struct sysmobts_eeprom, _pad1) == 85, offset_85);
+osmo_static_assert(offsetof(struct sysmobts_eeprom, gpg_key) == 121, offset_121);