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

Commit 6b4bbcba authored by Sagar Dharia's avatar Sagar Dharia
Browse files

slimbus: Support push-pull data channel protocol



Start supporting push-pull data channel protocol in slimbus driver
since the slimbus HW supports it now.

Change-Id: If6b26a696cd2a459a5c5215588711ea037e778ac
Signed-off-by: default avatarSagar Dharia <sdharia@codeaurora.org>
parent 2a4b1904
Loading
Loading
Loading
Loading
+2 −0
Original line number Diff line number Diff line
@@ -793,6 +793,8 @@ static int ngd_allocbw(struct slim_device *sb, int *subfrmc, int *clkgear)
			wbuf[txn.len++] = (u8) (slc->prop.dataf << 5) |
					(sb->laddr & 0x1f);
			wbuf[txn.len] = slc->seglen;
			if (slc->srch && slc->prop.prot == SLIM_PUSH)
				slc->prop.prot = SLIM_PULL;
			if (slc->coeff == SLIM_COEFF_3)
				wbuf[txn.len] |= 1 << 5;
			wbuf[txn.len++] |= slc->prop.auxf << 6;
+3 −5
Original line number Diff line number Diff line
@@ -1634,7 +1634,7 @@ static u32 slim_calc_prrate(struct slim_controller *ctrl, struct slim_ch *prop)
	bool done = false;
	enum slim_ch_rate ratefam;

	if (prop->prot >= SLIM_PUSH)
	if (prop->prot >= SLIM_ASYNC_SMPLX)
		return 0;
	if (prop->baser == SLIM_RATE_1HZ) {
		rate = prop->ratem / 4000;
@@ -1753,10 +1753,8 @@ static int slim_nextdefine_ch(struct slim_device *sb, u8 chan)
	else if (prop->prot == SLIM_AUTO_ISO) {
		if (exact)
			prop->prot = SLIM_HARD_ISO;
		else {
			/* Push-Pull not supported for now */
			return -EPROTONOSUPPORT;
		}
		else
			prop->prot = SLIM_PUSH;
	}
	slc->rootexp = exp;
	slc->seglen = prop->sampleszbits/SLIM_CL_PER_SL;