Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit a7482259 authored by Bhaumik Bhatt's avatar Bhaumik Bhatt Committed by Yue Ma
Browse files

cnss2: print message for abrupt device reset to PBL



At times, the device can abruptly reset due to power rail or
other related issues which can manifest as a linkdown on the
host. As linkdown recovery mechanism is put in place, it would
be helpful to understand why a set of ramdumps was not collected
in these abrupt reset cases. Hence, it is wise to add a print
message to check whether the device has reset to PBL and make
the users aware.

Change-Id: I545a5b87461b05ea436e383fddd2a8d037a8389d
Signed-off-by: default avatarBhaumik Bhatt <bbhatt@codeaurora.org>
parent 146ff543
Loading
Loading
Loading
Loading
+6 −0
Original line number Diff line number Diff line
@@ -4240,12 +4240,18 @@ static void cnss_dev_rddm_timeout_hdlr(struct timer_list *t)
{
	struct cnss_pci_data *pci_priv =
		from_timer(pci_priv, t, dev_rddm_timer);
	struct mhi_controller *mhi_ctrl = pci_priv->mhi_ctrl;

	if (!pci_priv)
		return;

	cnss_fatal_err("Timeout waiting for RDDM notification\n");

	if (mhi_get_exec_env(mhi_ctrl) == MHI_EE_PBL)
		cnss_pr_err("Unable to collect ramdumps due to abrupt reset\n");

	mhi_debug_reg_dump(mhi_ctrl);

	cnss_schedule_recovery(&pci_priv->pci_dev->dev, CNSS_REASON_TIMEOUT);
}