diff options
author | Holger Hans Peter Freyther <zecke@selfish.org> | 2012-07-26 20:10:39 +0200 |
---|---|---|
committer | Holger Hans Peter Freyther <zecke@selfish.org> | 2012-07-26 20:18:53 +0200 |
commit | b86bf060d334b33628e192218915526a526ebe46 (patch) | |
tree | 12f1a8e0514399fce89e89932d51b7a9ad97221b /src/osmo-bts-sysmo/femtobts.h | |
parent | fde8e6dc0c1b493f70c2ffdb5182afe8d426bd9e (diff) |
sysmobts: Support older firmware on the RevB hardware
For the firmware used on RevB the GsmL1_Prim_t was bigger than
the femtobts control structure. Solve it by introducing a macro
that will select the biggest size and use this macro. This is a
follow up fix for 08fce19cfce84432fbf8293318486a96437a3427.
Diffstat (limited to 'src/osmo-bts-sysmo/femtobts.h')
-rw-r--r-- | src/osmo-bts-sysmo/femtobts.h | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/src/osmo-bts-sysmo/femtobts.h b/src/osmo-bts-sysmo/femtobts.h index fd5142bc..a880562d 100644 --- a/src/osmo-bts-sysmo/femtobts.h +++ b/src/osmo-bts-sysmo/femtobts.h @@ -21,6 +21,14 @@ #define SUPERFEMTO_API_VERSION SUPERFEMTO_API(2,2,0) #endif +/* + * Depending on the firmware version either GsmL1_Prim_t or SuperFemto_Prim_t + * is the bigger struct. For earlier firmware versions the GsmL1_Prim_t was the + * bigger struct. + */ +#define SYSMOBTS_PRIM_SIZE \ + (OSMO_MAX(sizeof(SuperFemto_Prim_t), sizeof(GsmL1_Prim_t)) + 128) + enum l1prim_type { L1P_T_REQ, L1P_T_CONF, |