Received: by 2002:a05:6a10:f347:0:0:0:0 with SMTP id d7csp9110724pxu; Mon, 28 Dec 2020 06:55:40 -0800 (PST) X-Google-Smtp-Source: ABdhPJxj3Aad5qNxgie1WIsKvIYu8KVXzZoNEsXe0xRgoxOP7dpS4MuB48ZhRQXT85HUG1dGuk4G X-Received: by 2002:aa7:c94a:: with SMTP id h10mr42511788edt.247.1609167339886; Mon, 28 Dec 2020 06:55:39 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1609167339; cv=none; d=google.com; s=arc-20160816; b=QYCwI5nx9VieytVs54vXyP7gGidJvcWzPaVQ7wSsFqRYHqFE0tAPuIVhJ4ILRvq+Gl yZ0m6Q3KWEmjSvCA4/zu3jnR9QGfTflLKol1iWNwIx4lPYUKm46vVU9wtXfeEYmZsVSU JC9zF1HaAwFKIBVuOOIvFlP1UyWHeqFOB/dzjFFs8dcpAf4qUPCoeVpM0rLYnPRptwlc vCZHjO6GE3SxZtBEvClB4nGeOsJyNOGUQyQzm7ofyvlDOw8rk5SZ0kdJtFplqRkk964+ d/Kd+iYYD7z2TtBruhkK/Og6K2YYBe6StKrJj54UeQNB8ifFxXwMNukYTNhJDcRLzq7Q bJxw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:mime-version :user-agent:references:in-reply-to:message-id:date:subject:cc:to :from:dkim-signature; bh=c+tjEyYyvz5MmhBNsq9kZ9ZYKWgcoh01qyVb3R6+Ss8=; b=kXWrtfMyrz6+LIohUf5aqlng7GcGSplTquawbeBb5LeCuf9e9h7XnFkunABetiYF7B 3Qnx3PP+AG2DcCLSRkqfzCnk5BYKJe1OsNIWflF0CYt1AMsddinJvbzehs7Dt+iMT49z pXmnfJI/ndxe7D0LwgeczwCaPO8OCTdaGlBcDutRwAu8P+xa06vhioPYWz7Oe3Na8K9P zqbRZrlmRGJCHSx4j8RMArRdBRUSd/q0ZwXAVjec+9Vl/MW9uDkxI+g50YANgp/kWa7D SKsI/gK2aJPnUuBL4Aspz0hMlJxG0//GXImfzujFX+8E5rV918CSWv2PUQML5wUxw7mr 3JRQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linuxfoundation.org header.s=korg header.b=S9Uq+Tmg; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linuxfoundation.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id t12si24876796edc.228.2020.12.28.06.55.15; Mon, 28 Dec 2020 06:55:39 -0800 (PST) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) client-ip=23.128.96.18; Authentication-Results: mx.google.com; dkim=pass header.i=@linuxfoundation.org header.s=korg header.b=S9Uq+Tmg; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linuxfoundation.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S2502094AbgL1OxR (ORCPT + 99 others); Mon, 28 Dec 2020 09:53:17 -0500 Received: from mail.kernel.org ([198.145.29.99]:54718 "EHLO mail.kernel.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S2441630AbgL1OTZ (ORCPT ); Mon, 28 Dec 2020 09:19:25 -0500 Received: by mail.kernel.org (Postfix) with ESMTPSA id 2CFF122B2C; Mon, 28 Dec 2020 14:18:43 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=linuxfoundation.org; s=korg; t=1609165124; bh=9g0/XxWyP3jMlOsB5v6yCEAHuPcYlFakdyDme1xpF90=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=S9Uq+TmgZMFgxJ038nCf9KWDK+conzJRmbihJ36QHuYDcLgRKHaHdr1LsTQ9jDJ07 2sAycyA7j19PeGEUSmDRVM/KxGdQygIs5pZyt7QOavaRqF1liA2t5UvYcE6dGK8R6b 5kVEXHDXRAsojnczReBAsj20RqlE03X9b8bJnsGM= From: Greg Kroah-Hartman To: linux-kernel@vger.kernel.org Cc: Greg Kroah-Hartman , stable@vger.kernel.org, Peter Ujfalusi , Vinod Koul , Sasha Levin Subject: [PATCH 5.10 421/717] dmaengine: ti: k3-udma: Correct normal channel offset when uchan_cnt is not 0 Date: Mon, 28 Dec 2020 13:46:59 +0100 Message-Id: <20201228125041.133605068@linuxfoundation.org> X-Mailer: git-send-email 2.29.2 In-Reply-To: <20201228125020.963311703@linuxfoundation.org> References: <20201228125020.963311703@linuxfoundation.org> User-Agent: quilt/0.66 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org From: Peter Ujfalusi [ Upstream commit e2de925bbfe321ba0588c99f577c59386ab1f428 ] According to different sections of the TRM, the hchan_cnt of CAP3 includes the number of uchan in UDMA, thus the start offset of the normal channels are hchan_cnt. Fixes: daf4ad0499aa4 ("dmaengine: ti: k3-udma: Query throughput level information from hardware") Signed-off-by: Peter Ujfalusi Link: https://lore.kernel.org/r/20201208090440.31792-2-peter.ujfalusi@ti.com Signed-off-by: Vinod Koul Signed-off-by: Sasha Levin --- drivers/dma/ti/k3-udma.c | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/drivers/dma/ti/k3-udma.c b/drivers/dma/ti/k3-udma.c index 82cf6c77f5c93..d3902784cae24 100644 --- a/drivers/dma/ti/k3-udma.c +++ b/drivers/dma/ti/k3-udma.c @@ -3201,8 +3201,7 @@ static int udma_setup_resources(struct udma_dev *ud) } else if (UDMA_CAP3_UCHAN_CNT(cap3)) { ud->tpl_levels = 3; ud->tpl_start_idx[1] = UDMA_CAP3_UCHAN_CNT(cap3); - ud->tpl_start_idx[0] = ud->tpl_start_idx[1] + - UDMA_CAP3_HCHAN_CNT(cap3); + ud->tpl_start_idx[0] = UDMA_CAP3_HCHAN_CNT(cap3); } else if (UDMA_CAP3_HCHAN_CNT(cap3)) { ud->tpl_levels = 2; ud->tpl_start_idx[0] = UDMA_CAP3_HCHAN_CNT(cap3); -- 2.27.0