Received: by 2002:a05:6358:f14:b0:e5:3b68:ec04 with SMTP id b20csp984001rwj; Thu, 22 Dec 2022 18:38:30 -0800 (PST) X-Google-Smtp-Source: AMrXdXuCaKnVDg0sLEBHr9+sWUcvHyuAHiZTpgEHS31iL7BhxrrG899V3/rR3skw2hBkABVP6Jd6 X-Received: by 2002:a17:906:a186:b0:7c0:efbd:70a2 with SMTP id s6-20020a170906a18600b007c0efbd70a2mr6994047ejy.42.1671763109872; Thu, 22 Dec 2022 18:38:29 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1671763109; cv=none; d=google.com; s=arc-20160816; b=N2q+410G2UEF3CYO47zo4XqHhV8IebqsFszQkmYb0n/LhV1j0Ft12Fw2+Wx+Qe+9sF YSTMG9jllsBFP9cYT0s5y6s3rvXJDdtY4/nDNvFKhWLZMqTFj8uMsaUL5rT4n3LMvr+y p8WcyuPtHP0fILQ7OfEsViJbCXN76cjlPRJae4hzx/NoVHvwMmBz0nWaOoIT5Il38ssi SSouDnTlVhbQ5NdanITEwVz9P/2DwfXVBBHv6uXIk7veTS02+4EV2l5U3FH8mXQG16k5 I+pUTd309gt8g9rOF5jUYRmCiZ+U/OtEB1wXWt0i96tG6/QKkvCUEM82qDOFDpQ0xRbJ m0vg== 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; bh=+PgePphIkJvS7Okl9Cj+x1SpvHHCufOw282m7NhoD9k=; b=PZQcIKiAjh5rvMxhnP7YzZ9f6rvAnaBb4jR3OwypMgls9keIZ6HUxA9aXK7e0wF8cX kak3lzttdoEfaJvYK8hMFkXFrH4NqEux8Q1xtSIi/ZkKOfVR56QJnVdkNG1khgqx4TN+ 6hRJJloaKvSjr3XvcNZNe4F8UUQRcGRUQOf2dTS28tDAtukr7cBVHscDGsnsb2LzIDtU KAkMuvzxjJCeLTszh5lBBH3qVlzP+ntjK/Bi1JX9IdVnmVjuQ2wXR7gdbht2PRdD8czL +pknsg4fBzTplUSEZ6kt39LMenDf9BZk/QB4JMW8VVg1QOgOLFSVW/kc/4+L6x4aUGle CS6g== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@igel-co-jp.20210112.gappssmtp.com header.s=20210112 header.b=GSlGi50L; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id qa33-20020a17090786a100b007c4fb1332c0si1845371ejc.174.2022.12.22.18.38.14; Thu, 22 Dec 2022 18:38:29 -0800 (PST) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) client-ip=2620:137:e000::1:20; Authentication-Results: mx.google.com; dkim=pass header.i=@igel-co-jp.20210112.gappssmtp.com header.s=20210112 header.b=GSlGi50L; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S230062AbiLWC0e (ORCPT + 67 others); Thu, 22 Dec 2022 21:26:34 -0500 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:38266 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S230034AbiLWC0b (ORCPT ); Thu, 22 Dec 2022 21:26:31 -0500 Received: from mail-pf1-x429.google.com (mail-pf1-x429.google.com [IPv6:2607:f8b0:4864:20::429]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 4972A6308 for ; Thu, 22 Dec 2022 18:26:30 -0800 (PST) Received: by mail-pf1-x429.google.com with SMTP id 130so2445489pfu.8 for ; Thu, 22 Dec 2022 18:26:30 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=igel-co-jp.20210112.gappssmtp.com; s=20210112; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:from:to:cc:subject:date :message-id:reply-to; bh=+PgePphIkJvS7Okl9Cj+x1SpvHHCufOw282m7NhoD9k=; b=GSlGi50L9w6iFdONQ34C/l/widp+H4tgsoFT87eYgfxSPJfOJAzdqdlwclCf+xEWJ7 hYus1zP3Q84bDBIyh4xRW6Eo9kRqSVygNeYgw9pNXbmNpA3YWhpH2BWPFpObE1jO7wfF 0AAOEvGuPboZm+NrS7bED9U+0k2v49wrFexhx3pGBJm1jDsx+oeD/aQVmG73Ae9Bnxc5 XnLOZUFlSN5ddedKnB+S0BxWnlcZlmofiLz1comF57iHEAaOr7tRZs9MznAGan9r3Mjp c2tXVXLvfFmqDeXJf8AcMt6sruNgItBH1HjH+b8oM00EySJaK3JGk8R1BYxtN7CzH5Cf Irtw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=+PgePphIkJvS7Okl9Cj+x1SpvHHCufOw282m7NhoD9k=; b=aWjt/Zd/3qnsFHJHDalZzrMjIAMGlGAdUoB+BGgXqcFFO21f2Em8MOpvpO1j40wA1r +Tlh996rJpynypY727vSsRL6HUjW2SObjYcaSBRc1GBM7fr+XW4rIzcleNd9cyB2xeMV LmqSJIh1cYvt1COom9BT+wREjedqwgs4EWrNyYLkAYM+MJA7uclCxp8uKnO2YfbR1XXe F6ER9iN4hk/KjfP1DW/RWjT5lYdfXSaQRkCBed82O+trwWQWiWK/gyTO9JT/ReMpkjfh +sX5U+NwYh129KzhzCjjy6Zze3JsGnZO0efnKCi1xow6XfSLXPYgwBPI213DjewOTTbN Obzg== X-Gm-Message-State: AFqh2kpKGGjgu02I8pi3kkNNagS+ADMruHh9TwRS3hHpXj3nBP7H4h8g U2la5x6qP1Gr7kBm2DCItZeWag== X-Received: by 2002:aa7:97ba:0:b0:576:d2cc:1ad2 with SMTP id d26-20020aa797ba000000b00576d2cc1ad2mr7689262pfq.6.1671762389794; Thu, 22 Dec 2022 18:26:29 -0800 (PST) Received: from tyrell.hq.igel.co.jp (napt.igel.co.jp. [219.106.231.132]) by smtp.gmail.com with ESMTPSA id w186-20020a6262c3000000b005772f762e43sm1418471pfb.13.2022.12.22.18.26.28 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Thu, 22 Dec 2022 18:26:29 -0800 (PST) From: Shunsuke Mie To: Gustavo Pimentel Cc: Vinod Koul , dmaengine@vger.kernel.org, linux-kernel@vger.kernel.org, Shunsuke Mie Subject: [PATCH 2/2] dmaengine: dw-edma: Fix to enable to issue dma request on DMA processing Date: Fri, 23 Dec 2022 11:26:08 +0900 Message-Id: <20221223022608.550697-2-mie@igel.co.jp> X-Mailer: git-send-email 2.25.1 In-Reply-To: <20221223022608.550697-1-mie@igel.co.jp> References: <20221223022608.550697-1-mie@igel.co.jp> MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Spam-Status: No, score=-1.9 required=5.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,RCVD_IN_DNSWL_NONE,SPF_HELO_NONE,SPF_PASS 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 The issue_pending request is ignored while driver is processing a DMA request. Fix to issue the pending requests on any dma channel status. Fixes: e63d79d1ffcd ("dmaengine: Add Synopsys eDMA IP core driver") Signed-off-by: Shunsuke Mie --- drivers/dma/dw-edma/dw-edma-core.c | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/drivers/dma/dw-edma/dw-edma-core.c b/drivers/dma/dw-edma/dw-edma-core.c index 669b97313911..80323b7a8bce 100644 --- a/drivers/dma/dw-edma/dw-edma-core.c +++ b/drivers/dma/dw-edma/dw-edma-core.c @@ -279,9 +279,12 @@ static void dw_edma_device_issue_pending(struct dma_chan *dchan) struct dw_edma_chan *chan = dchan2dw_edma_chan(dchan); unsigned long flags; + if (!chan->configured) + return; + spin_lock_irqsave(&chan->vc.lock, flags); - if (chan->configured && chan->request == EDMA_REQ_NONE && - chan->status == EDMA_ST_IDLE && vchan_issue_pending(&chan->vc)) { + if (vchan_issue_pending(&chan->vc) && chan->request == EDMA_REQ_NONE && + chan->status == EDMA_ST_IDLE) { chan->status = EDMA_ST_BUSY; dw_edma_start_transfer(chan); } -- 2.25.1