Received: by 2002:a05:7412:8d10:b0:f3:1519:9f41 with SMTP id bj16csp2348918rdb; Fri, 8 Dec 2023 05:50:24 -0800 (PST) X-Google-Smtp-Source: AGHT+IFCpLQRtGYQlKNIbLWJEsSQAXsr9nLVqm6mKCIdUpUigZfHMPs+cgbTWYKjQAn3qdsbLJlK X-Received: by 2002:a05:6a21:998e:b0:18c:ece:a2f6 with SMTP id ve14-20020a056a21998e00b0018c0ecea2f6mr65049pzb.19.1702043424136; Fri, 08 Dec 2023 05:50:24 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1702043424; cv=none; d=google.com; s=arc-20160816; b=rCy/kauimi0kl1UybSQaMwUhXg0GnYzPDTG3AszZeJEiX+ClK+9ntdaqh3JbbfZNQP 9jIHchtEdTr7Mc7aGSU5vaJJzN0EuRs1t4DAjeVbNr+kEVEBr2Qc67Zp8i1Q9pWxIVnh FnEqSigovmzpP6cpT+CaoA5e6UUnQmauIZV7pBPB0Y0P2lg4rLUcKx71kEu/BXg4JSND tqnXLi8H1bVL65gQVA/ggs4e86Avw8g+O6Mh+rP6pDHQb9frcYgqtGsQVMdtXL9TvBdt RkF4SGpXrJ1k1MOSwvCM281zSMHCO9KsxwHnBjK4k0xw9mWaDGyU+yeGR2WeyTUEcRbF jXTg== 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 :references:in-reply-to:message-id:date:subject:cc:to:from :dkim-signature:dkim-filter; bh=rjl10Q6vv79c/VjetazpETH5QmjolDY1PkqfCQ5TdI0=; fh=1pmAyp3xZ8sWUV98t98q7URUgX68KjDmTZriOyZWZ/U=; b=oxAny1vavszrKf0pjGgtx9y/Y5zaMfctB+ncGl/ZFNkH/Ju0Edj/wwQo5fbJNsLpxW Xd1s4YEx0aqBmKOftoSiW1EMzf21/Fwuc5WDvG1+t3dRpMyYVWblgEDmY1vAL8JbPI4S FN2ckLz44uixDce6GwW+9+DC5oc8mBm8II6zzGEn9sjsxZBaTGXGGD9cLHDUbVH8cy2T gAQDjxDy5O2jR8txMwyiAEra50ILchSxGF/qpB0gsjDoGyIdoj/3bBqLuPAj53pXaU5F d3U/8G/cQfPc7h1ANYch5e0aAEmJNjZvhjEOFi3jkBLjT7XzuoLh5DfD+69+1sZOTsFO M93g== ARC-Authentication-Results: i=1; mx.google.com; dkim=fail header.i=@alatek.krakow.pl header.s=99EE5E86-D06A-11EC-BE24-DBCCD0A148D3 header.b=qIfwW8Zq; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::3:7 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=alatek.krakow.pl Return-Path: Received: from snail.vger.email (snail.vger.email. [2620:137:e000::3:7]) by mx.google.com with ESMTPS id q28-20020a056a0002bc00b006ce7ff254c2si1559909pfs.368.2023.12.08.05.50.20 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 08 Dec 2023 05:50:24 -0800 (PST) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::3:7 as permitted sender) client-ip=2620:137:e000::3:7; Authentication-Results: mx.google.com; dkim=fail header.i=@alatek.krakow.pl header.s=99EE5E86-D06A-11EC-BE24-DBCCD0A148D3 header.b=qIfwW8Zq; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::3:7 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=alatek.krakow.pl Received: from out1.vger.email (depot.vger.email [IPv6:2620:137:e000::3:0]) by snail.vger.email (Postfix) with ESMTP id 80EB280C0380; Fri, 8 Dec 2023 05:50:19 -0800 (PST) X-Virus-Status: Clean X-Virus-Scanned: clamav-milter 0.103.11 at snail.vger.email Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1573849AbjLHNuJ (ORCPT + 99 others); Fri, 8 Dec 2023 08:50:09 -0500 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:37238 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1573812AbjLHNuI (ORCPT ); Fri, 8 Dec 2023 08:50:08 -0500 Received: from helios.alatek.com.pl (helios.alatek.com.pl [85.14.123.227]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id A74881706; Fri, 8 Dec 2023 05:50:14 -0800 (PST) Received: from localhost (localhost [127.0.0.1]) by helios.alatek.com.pl (Postfix) with ESMTP id A8CD42D00F54; Fri, 8 Dec 2023 14:50:12 +0100 (CET) Received: from helios.alatek.com.pl ([127.0.0.1]) by localhost (helios.alatek.com.pl [127.0.0.1]) (amavis, port 10032) with ESMTP id JBQzyMXMEnKr; Fri, 8 Dec 2023 14:50:08 +0100 (CET) Received: from localhost (localhost [127.0.0.1]) by helios.alatek.com.pl (Postfix) with ESMTP id 442862D00F53; Fri, 8 Dec 2023 14:50:08 +0100 (CET) DKIM-Filter: OpenDKIM Filter v2.10.3 helios.alatek.com.pl 442862D00F53 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=alatek.krakow.pl; s=99EE5E86-D06A-11EC-BE24-DBCCD0A148D3; t=1702043408; bh=rjl10Q6vv79c/VjetazpETH5QmjolDY1PkqfCQ5TdI0=; h=From:To:Date:Message-Id:MIME-Version; b=qIfwW8Zq2rMbJovcgbhAbqJJlDriJFOLpZQktxxCg6SlU33Y4GEFA6lZ6nzPS1eCJ ojqsFF8dfRF4O5R0WBzJVP9CO84ZTrOjM+fEHX7v0re+vxN08gmb5OcSOP6HgLqn14 86C0TKpsML47mxm2jQo5YKWx3g1ZMMN9+AoxsYWMM0gHxozJzoqK7OfZD4of/UdY6A rKr0OyxP+aBeFwbyXIqxwMv5OujoUeQ392cXxb6EPd1OfTXbC3HwmBb8dCNxPGANAw ealn4irlEid8mEJPnuz7qQvMVh/PY96hO50I9YgA0x5DNs83xXCVvhHOdX6IHlMedA PR8n5QKqRIYbA== X-Virus-Scanned: amavis at alatek.com.pl Received: from helios.alatek.com.pl ([127.0.0.1]) by localhost (helios.alatek.com.pl [127.0.0.1]) (amavis, port 10026) with ESMTP id ITpTl4yrV2e8; Fri, 8 Dec 2023 14:50:08 +0100 (CET) Received: from localhost.localdomain (unknown [10.125.125.6]) by helios.alatek.com.pl (Postfix) with ESMTPSA id 9C6F42D00F4D; Fri, 8 Dec 2023 14:50:07 +0100 (CET) From: Jan Kuliga To: lizhi.hou@amd.com, brian.xu@amd.com, raj.kumar.rampelli@amd.com, vkoul@kernel.org, michal.simek@amd.com, dmaengine@vger.kernel.org, linux-kernel@vger.kernel.org, miquel.raynal@bootlin.com Cc: jankul@alatek.krakow.pl Subject: [PATCH v4 2/8] dmaengine: xilinx: xdma: Add necessary macro definitions Date: Fri, 8 Dec 2023 14:49:23 +0100 Message-Id: <20231208134929.49523-3-jankul@alatek.krakow.pl> X-Mailer: git-send-email 2.34.1 In-Reply-To: <20231208134838.49500-1-jankul@alatek.krakow.pl> References: <20231208134838.49500-1-jankul@alatek.krakow.pl> MIME-Version: 1.0 Content-Transfer-Encoding: quoted-printable X-Spam-Status: No, score=-2.0 required=5.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,RCVD_IN_DNSWL_BLOCKED,SPF_HELO_NONE,SPF_PASS, T_SCC_BODY_TEXT_LINE autolearn=ham autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on lindbergh.monkeyblade.net Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org X-Greylist: Sender passed SPF test, not delayed by milter-greylist-4.6.4 (snail.vger.email [0.0.0.0]); Fri, 08 Dec 2023 05:50:19 -0800 (PST) Complete lacking bits describing the status/control register values. Add macros describing the status/control registers. Signed-off-by: Jan Kuliga --- drivers/dma/xilinx/xdma-regs.h | 11 +++++++++++ 1 file changed, 11 insertions(+) diff --git a/drivers/dma/xilinx/xdma-regs.h b/drivers/dma/xilinx/xdma-reg= s.h index 0b17a931f583..b12dd60629f6 100644 --- a/drivers/dma/xilinx/xdma-regs.h +++ b/drivers/dma/xilinx/xdma-regs.h @@ -76,6 +76,7 @@ struct xdma_hw_desc { #define XDMA_CHAN_CONTROL_W1S 0x8 #define XDMA_CHAN_CONTROL_W1C 0xc #define XDMA_CHAN_STATUS 0x40 +#define XDMA_CHAN_STATUS_RC 0x44 #define XDMA_CHAN_COMPLETED_DESC 0x48 #define XDMA_CHAN_ALIGNMENTS 0x4c #define XDMA_CHAN_INTR_ENABLE 0x90 @@ -101,6 +102,7 @@ struct xdma_hw_desc { #define CHAN_CTRL_IE_MAGIC_STOPPED BIT(4) #define CHAN_CTRL_IE_IDLE_STOPPED BIT(6) #define CHAN_CTRL_IE_READ_ERROR GENMASK(13, 9) +#define CHAN_CTRL_IE_WRITE_ERROR GENMASK(18, 14) #define CHAN_CTRL_IE_DESC_ERROR GENMASK(23, 19) #define CHAN_CTRL_NON_INCR_ADDR BIT(25) #define CHAN_CTRL_POLL_MODE_WB BIT(26) @@ -111,8 +113,17 @@ struct xdma_hw_desc { CHAN_CTRL_IE_DESC_ALIGN_MISMATCH | \ CHAN_CTRL_IE_MAGIC_STOPPED | \ CHAN_CTRL_IE_READ_ERROR | \ + CHAN_CTRL_IE_WRITE_ERROR | \ CHAN_CTRL_IE_DESC_ERROR) +#define XDMA_CHAN_STATUS_MASK CHAN_CTRL_START + +#define XDMA_CHAN_ERROR_MASK (CHAN_CTRL_IE_DESC_ALIGN_MISMATCH | \ + CHAN_CTRL_IE_MAGIC_STOPPED | \ + CHAN_CTRL_IE_READ_ERROR | \ + CHAN_CTRL_IE_WRITE_ERROR | \ + CHAN_CTRL_IE_DESC_ERROR) + /* bits of the channel interrupt enable mask */ #define CHAN_IM_DESC_ERROR BIT(19) #define CHAN_IM_READ_ERROR BIT(9) -- 2.34.1