mirror of
https://gitea.osmocom.org/sim-card/simtrace2.git
synced 2026-03-23 08:48:35 +03:00
[firmware] sim_switch + wwan_perst: Don't re-initialize
The logic to detect if the respective module is already initialized or not was broken. When performing initialization, we of course need to set initialized=1.
This commit is contained in:
@@ -69,5 +69,6 @@ int sim_switch_init(void)
|
|||||||
PIO_Configure(&pin_conn_usim2, 1);
|
PIO_Configure(&pin_conn_usim2, 1);
|
||||||
num_switch++;
|
num_switch++;
|
||||||
#endif
|
#endif
|
||||||
|
initialized = 1;
|
||||||
return num_switch;
|
return num_switch;
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -109,5 +109,6 @@ int wwan_perst_init(void)
|
|||||||
perst2.timer.data = (void *) &perst2;
|
perst2.timer.data = (void *) &perst2;
|
||||||
num_perst++;
|
num_perst++;
|
||||||
#endif
|
#endif
|
||||||
|
initialized = 1;
|
||||||
return num_perst;
|
return num_perst;
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user