Skip to content
Commit b7eb2202 authored by Yong Cong Sin's avatar Yong Cong Sin Committed by Carles Cufí
Browse files

drivers: modem: gsm: introduce lock



After the introduction of start/stop & rssi query work, these
additional functions can be invoked from different threads.

Things can quickly become hard to analyze when an interrupt
fires during one of these functions and upon return the
scheduler schedules another thread and run another function.

This PR introduces a simple mutex lock that guarantees thread
safety. Similar implementation can be found in hl7800 driver,
which has lots of public APIs that can be invoked from different
threads.

Signed-off-by: default avatarYong Cong Sin <yongcong.sin@gmail.com>

Update gsm_ppp.c
parent 975bc85b
Loading
Loading
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please to comment