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

Commit 72c311fc authored by Karthik Kantamneni's avatar Karthik Kantamneni Committed by Madan Koyyalamudi
Browse files

qcacmn: Introduce intermediate EP voting access state

Introduce intermediate EP voting state during this transition state
access the votes only if direct writes are not possible.

Change-Id: Ib4522aef2209b4797100ca84e4e230a00e14b654
CRs-Fixed: 2954903
parent 40b9b54a
Loading
Loading
Loading
Loading
+8 −3
Original line number Diff line number Diff line
@@ -1283,13 +1283,18 @@ void hal_delayed_reg_write(struct hal_soc *hal_soc,
			   void __iomem *addr,
			   uint32_t value)
{
	uint8_t vote_access;

	switch (srng->ring_type) {
	case CE_SRC:
	case CE_DST:
	case CE_DST_STATUS:
		if (hif_get_ep_vote_access(hal_soc->hif_handle,
					   HIF_EP_VOTE_NONDP_ACCESS) ==
					   HIF_EP_VOTE_ACCESS_DISABLE) {
		vote_access = hif_get_ep_vote_access(hal_soc->hif_handle,
						     HIF_EP_VOTE_NONDP_ACCESS);
		if ((vote_access == HIF_EP_VOTE_ACCESS_DISABLE) ||
		    (vote_access == HIF_EP_VOTE_INTERMEDIATE_ACCESS &&
		     PLD_MHI_STATE_L0 ==
		     pld_get_mhi_state(hal_soc->qdf_dev->dev))) {
			hal_write_address_32_mb(hal_soc, addr, value, false);
			qdf_atomic_inc(&hal_soc->stats.wstats.direct);
			srng->wstats.direct++;
+2 −0
Original line number Diff line number Diff line
@@ -1075,10 +1075,12 @@ enum hif_ep_vote_type {
/**
 * enum hif_ep_vote_access - hif ep vote access
 * HIF_EP_VOTE_ACCESS_ENABLE: Enable ep voting
 * HIF_EP_VOTE_INTERMEDIATE_ACCESS: allow during transistion
 * HIF_EP_VOTE_ACCESS_DISABLE: disable ep voting
 */
enum hif_ep_vote_access {
	HIF_EP_VOTE_ACCESS_ENABLE,
	HIF_EP_VOTE_INTERMEDIATE_ACCESS,
	HIF_EP_VOTE_ACCESS_DISABLE
};