]> git.baikalelectronics.ru Git - kernel.git/commit
net: wwan: iosm: allow trace port be uninitialized
authorSergey Ryazanov <ryazanov.s.a@gmail.com>
Tue, 7 Dec 2021 09:21:38 +0000 (12:21 +0300)
committerJakub Kicinski <kuba@kernel.org>
Thu, 9 Dec 2021 01:58:58 +0000 (17:58 -0800)
commite9c3fd8567f6fccacdfa0d28b3bc4e3ece7edef8
tree65e0f75ad88a696581a30ac8e7d4d5ce2808ceda
parent97c9af36a005e3ede74121899ba141cbaa28d753
net: wwan: iosm: allow trace port be uninitialized

Collecting modem firmware traces is optional for the regular modem use.
There are not many reasons for aborting device initialization due to an
inability to initialize the trace port and (or) its debugfs interface.
So, demote the initialization failure erro message into a warning and do
not break the initialization sequence in this case. Rework packet
processing and deinitialization so that they do not crash in case of
uninitialized trace port.

This change is mainly a preparation for an upcoming configuration option
introduction that will help disable driver debugfs functionality.

Signed-off-by: Sergey Ryazanov <ryazanov.s.a@gmail.com>
Reviewed-by: Loic Poulain <loic.poulain@linaro.org>
Acked-by: M Chetan Kumar <m.chetan.kumar@intel.com>
Signed-off-by: Jakub Kicinski <kuba@kernel.org>
drivers/net/wwan/iosm/iosm_ipc_imem.c
drivers/net/wwan/iosm/iosm_ipc_trace.c
drivers/net/wwan/iosm/iosm_ipc_trace.h