mobile/vty: add a command to trigger LUR
Change-Id: I98ff3fb2611785a897723ea1edca8d8b4b3b5ec2fixeria/research
parent
6878fc2565
commit
1c1ffd1af2
|
@ -48,7 +48,7 @@ extern void *l23_ctx;
|
|||
void mm_conn_free(struct gsm48_mm_conn *conn);
|
||||
static int gsm48_rcv_rr(struct osmocom_ms *ms, struct msgb *msg);
|
||||
static int gsm48_rcv_mmr(struct osmocom_ms *ms, struct msgb *msg);
|
||||
static int gsm48_mm_ev(struct osmocom_ms *ms, int msg_type, struct msgb *msg);
|
||||
int gsm48_mm_ev(struct osmocom_ms *ms, int msg_type, struct msgb *msg);
|
||||
static int gsm48_mm_tx_id_rsp(struct osmocom_ms *ms, uint8_t mi_type);
|
||||
static int gsm48_mm_tx_loc_upd_req(struct osmocom_ms *ms);
|
||||
static int gsm48_mm_loc_upd_failed(struct osmocom_ms *ms, struct msgb *msg);
|
||||
|
@ -4295,7 +4295,7 @@ static struct eventstate {
|
|||
#define EVENTSLLEN \
|
||||
(sizeof(eventstatelist) / sizeof(struct eventstate))
|
||||
|
||||
static int gsm48_mm_ev(struct osmocom_ms *ms, int msg_type, struct msgb *msg)
|
||||
int gsm48_mm_ev(struct osmocom_ms *ms, int msg_type, struct msgb *msg)
|
||||
{
|
||||
struct gsm48_mmlayer *mm = &ms->mmlayer;
|
||||
int i, rc;
|
||||
|
|
|
@ -1081,6 +1081,28 @@ DEFUN(test_reselection, test_reselection_cmd, "test re-selection NAME",
|
|||
return CMD_SUCCESS;
|
||||
}
|
||||
|
||||
DEFUN(test_lur, test_lur_cmd, "test location-update NAME",
|
||||
"Manually trigger Location Update procedure\n"
|
||||
"Name of MS (see \"show ms\")")
|
||||
{
|
||||
struct osmocom_ms *ms;
|
||||
struct gsm48_mmlayer *mm;
|
||||
|
||||
ms = get_ms(argv[0], vty);
|
||||
if (!ms)
|
||||
return CMD_WARNING;
|
||||
|
||||
/* Reset attempt counter when attempting to update (4.4.4.5) */
|
||||
mm = &ms->mmlayer;
|
||||
if (mm->state == GSM48_MM_ST_MM_IDLE
|
||||
&& mm->substate == GSM48_MM_SST_ATTEMPT_UPDATE)
|
||||
mm->lupd_attempt = 0;
|
||||
|
||||
gsm48_mm_ev(ms, GSM48_MM_EVENT_TIMEOUT_T3212, NULL);
|
||||
|
||||
return CMD_SUCCESS;
|
||||
}
|
||||
|
||||
DEFUN(delete_forbidden_plmn, delete_forbidden_plmn_cmd,
|
||||
"delete forbidden plmn NAME MCC MNC",
|
||||
"Delete\nForbidden\nplmn\nName of MS (see \"show ms\")\n"
|
||||
|
@ -2986,6 +3008,7 @@ int ms_vty_init(void)
|
|||
install_element(ENABLE_NODE, &sms_cmd);
|
||||
install_element(ENABLE_NODE, &service_cmd);
|
||||
install_element(ENABLE_NODE, &test_reselection_cmd);
|
||||
install_element(ENABLE_NODE, &test_lur_cmd);
|
||||
install_element(ENABLE_NODE, &delete_forbidden_plmn_cmd);
|
||||
install_element(ENABLE_NODE, &clone_tsmi_cmd);
|
||||
install_element(ENABLE_NODE, &clone_imsi_cmd);
|
||||
|
|
Loading…
Reference in New Issue