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

Commit a4a9dd92 authored by Bhaumik Bhatt's avatar Bhaumik Bhatt Committed by Gerrit - the friendly Code Review server
Browse files

mhi: core: check for special events at mission mode entry



In some cases, the special purpose event scheduler may not run
if the interrupt comes close to mission mode entry point and if
no suspend/resume activity follows. Do a check to see if any
pending events need to be processed.

Change-Id: Ic3bf22562f250ec4bb46c14f58617c3b0d5de883
Signed-off-by: default avatarBhaumik Bhatt <bbhatt@codeaurora.org>
parent 81c74d71
Loading
Loading
Loading
Loading
+4 −0
Original line number Original line Diff line number Diff line
@@ -15,6 +15,8 @@
#include <linux/mhi.h>
#include <linux/mhi.h>
#include "mhi_internal.h"
#include "mhi_internal.h"


static void mhi_special_events_pending(struct mhi_controller *mhi_cntrl);

/*
/*
 * Not all MHI states transitions are sync transitions. Linkdown, SSR, and
 * Not all MHI states transitions are sync transitions. Linkdown, SSR, and
 * shutdown can happen anytime asynchronously. This function will transition to
 * shutdown can happen anytime asynchronously. This function will transition to
@@ -525,6 +527,8 @@ static int mhi_pm_mission_mode_transition(struct mhi_controller *mhi_cntrl)
	if (MHI_REG_ACCESS_VALID(mhi_cntrl->pm_state))
	if (MHI_REG_ACCESS_VALID(mhi_cntrl->pm_state))
		mhi_timesync_log(mhi_cntrl);
		mhi_timesync_log(mhi_cntrl);


	mhi_special_events_pending(mhi_cntrl);

	MHI_LOG("Adding new devices\n");
	MHI_LOG("Adding new devices\n");


	/* add supported devices */
	/* add supported devices */