Attention is currently required from: osmith. pespin has posted comments on this change. ( https://gerrit.osmocom.org/c/osmo-bsc-nat/+/27473 )
Change subject: Store MSC ......................................................................
Patch Set 1: Code-Review-1
(6 comments)
File include/osmocom/bsc_nat/bsc_nat.h:
https://gerrit.osmocom.org/c/osmo-bsc-nat/+/27473/comment/15be0799_e226b1d5 PS1, Line 57: struct msc *bsc_nat_msc_add_from_addr_book(struct bsc_nat *bsc_nat); I wonder what is this function doing.
https://gerrit.osmocom.org/c/osmo-bsc-nat/+/27473/comment/a1410564_d67bbe2d PS1, Line 58: struct msc *bsc_nat_msc_get(struct bsc_nat *bsc_nat); you get it identified by nothing?
File src/osmo-bsc-nat/bsc_nat.c:
https://gerrit.osmocom.org/c/osmo-bsc-nat/+/27473/comment/592e1021_235ac302 PS1, Line 70: struct msc *bsc_nat_msc_add_from_addr_book(struct bsc_nat *bsc_nat) Not sure we really need this function, just use the content directly, since this will go away at some point afaiu.
https://gerrit.osmocom.org/c/osmo-bsc-nat/+/27473/comment/332d2787_1688ebb6 PS1, Line 93: void bsc_nat_msc_del(struct bsc_nat *bsc_nat, struct msc *msc) IMHO this should be an API of the MSC object (see the bsc_nat is actually not used at all). We usually do it that way. msc_free(struct msc *msc);
Same for the "bsc" object.
File src/osmo-bsc-nat/main.c:
https://gerrit.osmocom.org/c/osmo-bsc-nat/+/27473/comment/4c156774_aac1655e PS1, Line 202: if (!bsc_nat_msc_add_from_addr_book(g_bsc_nat)) You can probably call the content of the function here directly. It's not going to be used elsewhere anyway.
File src/osmo-bsc-nat/msc_fsm.c:
https://gerrit.osmocom.org/c/osmo-bsc-nat/+/27473/comment/67deaa01_4cb05f9b PS1, Line 44: { 0, NULL } this half done FSM shouldn't be submitted this way. Better add all the content in the commit adding something useful here.