diff options
author | Harald Welte <laforge@gnumonks.org> | 2009-01-04 12:02:08 +0000 |
---|---|---|
committer | Harald Welte <laforge@gnumonks.org> | 2009-01-04 12:02:08 +0000 |
commit | 47d88aecafefa8fa1272ee405a631782ed6abd48 (patch) | |
tree | d3fe7a734d41918da3cfecb49ba52a1b15ec73c8 /src | |
parent | 868b8cdd589ce77200f8da96a3f1771cd39d9ac3 (diff) |
Add some functions to CREATE OBJECTs in the BS-11 internal database
Diffstat (limited to 'src')
-rw-r--r-- | src/abis_nm.c | 39 |
1 files changed, 39 insertions, 0 deletions
diff --git a/src/abis_nm.c b/src/abis_nm.c index 729832887..b297a11db 100644 --- a/src/abis_nm.c +++ b/src/abis_nm.c @@ -424,6 +424,8 @@ int abis_nm_event_reports(struct gsm_bts *bts, int on) return __simple_cmd(bts, NM_MT_REST_EVENT_REP); } +/* Siemens (or BS-11) specific commands */ + int abis_nm_reset_resource(struct gsm_bts *bts) { return __simple_cmd(bts, NM_MT_BS11_RESET_RESOURCE); @@ -436,3 +438,40 @@ int abis_nm_db_transmission(struct gsm_bts *bts, int begin) else return __simple_cmd(bts, NM_MT_BS11_END_DB_TX); } + +int abis_nm_create_object(struct gsm_bts *bts, enum abis_bs11_objtype type, + u_int8_t idx) +{ + struct abis_om_hdr *oh; + struct msgb *msg = nm_msgb_alloc(); + + oh = (struct abis_om_hdr *) msgb_put(msg, ABIS_OM_FOM_HDR_SIZE); + fill_om_fom_hdr(oh, 0, NM_MT_BS11_CREATE_OBJ, NM_OC_BS11, + type, idx, 0); + + return abis_nm_sendmsg(bts, msg); +} + +int abis_nm_create_envaBTSE(struct gsm_bts *bts, u_int8_t idx) +{ + struct abis_om_hdr *oh; + struct msgb *msg = nm_msgb_alloc(); + + oh = (struct abis_om_hdr *) msgb_put(msg, ABIS_OM_FOM_HDR_SIZE); + fill_om_fom_hdr(oh, 0, NM_MT_BS11_CREATE_OBJ, NM_OC_BS11_ENVABTSE, + 0, idx, 0); + + return abis_nm_sendmsg(bts, msg); +} + +int abis_nm_create_bport(struct gsm_bts *bts, u_int8_t idx) +{ + struct abis_om_hdr *oh; + struct msgb *msg = nm_msgb_alloc(); + + oh = (struct abis_om_hdr *) msgb_put(msg, ABIS_OM_FOM_HDR_SIZE); + fill_om_fom_hdr(oh, 0, NM_MT_BS11_CREATE_OBJ, NM_OC_BS11_BPORT, + idx, 0, 0); + + return abis_nm_sendmsg(bts, msg); +} |