net: wwan: iosm: Call mutex_init before locking it
wwan_register_ops calls wwan_create_default_link, which ends up in the ipc_wwan_newlink callback that locks ipc_wwan->if_mutex. However, this mutex is not yet initialized by that point. Fix it by moving mutex_init above the wwan_register_ops call. This also makes the order of operations in ipc_wwan_init symmetric to ipc_wwan_deinit. Fixes: 83068395 ("net: iosm: create default link via WWAN core") Signed-off-by: NMaxim Mikityanskiy <maxtram95@gmail.com> Reviewed-by: NM Chetan Kumar <m.chetan.kumar@intel.com> Signed-off-by: NDavid S. Miller <davem@davemloft.net>
Showing
想要评论请 注册 或 登录