Received: by 2002:a05:6358:3188:b0:123:57c1:9b43 with SMTP id q8csp1740703rwd; Sun, 21 May 2023 05:29:14 -0700 (PDT) X-Google-Smtp-Source: ACHHUZ7D7wQlB4EJJukj8PndBDy/XswEZ7UMhY3FXLEcaDGV1g6ddQTE0ZNa9/mbv1emXS1M8SC/ X-Received: by 2002:a05:6a20:4314:b0:10a:b812:bcc7 with SMTP id h20-20020a056a20431400b0010ab812bcc7mr3592540pzk.17.1684672154595; Sun, 21 May 2023 05:29:14 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1684672154; cv=none; d=google.com; s=arc-20160816; b=o+sZmDMl+fV5O3luSCXOeW06qp8yVLL9rEcH6EJqrIvyrDF9RPmWm7xqwJ2kJzRrmQ kmY7LPPiff0qF489ce3yjhGsSkEjRcx4ety2GwW1Xa+nAdwp5s6KDrYq5FSPvbc4Babi 7KEEs1zunFzH45Y94tg9smOCvpmntfhAh8MQk5PdQjSLLSlEpHRchElRYTUEuRv+IbAC 3tnKh7YVcyvNH5or2JUaAn4mPPP+Oh7RkxRzie0uDaxLQ5XD38PV5dZBhO6Z5GJgrYN/ Kr5bHiOxu7/+FCM41k5Ia/JI4SIpRllMi5Xqav0a1RtEDdo5itEOUpSw0Hwf+QYUL89W JH0Q== 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=Ff3UdYi3a4vi0uhAQbow/JpiqsVqHfWSFGm32O+IB+k=; b=PcxuN8C8jTtCkkALVG7SQvVb+MD2yHVwcYiyoXNh4xsQBqABnd+CFxP2F7tCKIeueq py0yTARVWGsaEbQUCA3NFsac2KO91AAbxuWxJxw5QCu/SP3nFUtINWRiHmrTxrEOv1i8 bWH3UcdTy2hAU4H2tTdxgpUJI53nT5yQ8XEhLIxV9lqyCPQtvvz/NI9uxO/TAVWEL2p3 n+P2WNpPMhioQ1NJilIOMa3l8B0sQxW2aijVP7a4w4dThj1rZIH383yHm6ywga3oPW+5 h72KjGAWnbJEdJWFtYmWqU1x8nHNmSh+OA6hVfpUuTtWkewPwpdlPUEo7lw7kAvrzHFu TLQA== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@kernel.org header.s=k20201202 header.b=onljlQhn; 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; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org Return-Path: Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id r15-20020aa7962f000000b0063d2b810fcbsi3159445pfg.208.2023.05.21.05.29.02; Sun, 21 May 2023 05:29:14 -0700 (PDT) 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=@kernel.org header.s=k20201202 header.b=onljlQhn; 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; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S230286AbjEULtW (ORCPT + 99 others); Sun, 21 May 2023 07:49:22 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:35682 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S230470AbjEUK1w (ORCPT ); Sun, 21 May 2023 06:27:52 -0400 Received: from dfw.source.kernel.org (dfw.source.kernel.org [139.178.84.217]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 1DEF910E6; Sun, 21 May 2023 03:23:33 -0700 (PDT) Received: from smtp.kernel.org (relay.kernel.org [52.25.139.140]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by dfw.source.kernel.org (Postfix) with ESMTPS id A85A760E74; Sun, 21 May 2023 10:23:32 +0000 (UTC) Received: by smtp.kernel.org (Postfix) with ESMTPSA id 3DB34C4339B; Sun, 21 May 2023 10:23:31 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=k20201202; t=1684664612; bh=+Tf439DcPyOhnrJYLUHMQ/cInIgZ19g0uwID2SQPxBs=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=onljlQhnGLnsMg8c1ByUgOfPf+pW4AQdNXQQfNkiVzxEmVJIqo1lCyYXS617e7stn SLs3YAiTnhWULSS0eEE1vuuZLP9FuwgB/MMv488p0Bql484cf/ntGD45TRB4KlDzQ6 pXt4ZUYZMo3SKUsI9BOE5PGrVSw1r55lVhpXyIMirQEzAb/fC9SvEVQwN0inkwp0Nt xWe6V7FF9wzKr12vR0+o2jNptP86lAmi+U8XUuLnEdgH8BJlyfr4TrZmWkPipBrq5L Px0JE2bkVCUzf9+H6BKb3NQocHi0nnR2/TtPOTrq+JxT61sntQD/Ou112+Sz2qS9HL b9fhqCoe1CunQ== From: Jisheng Zhang To: Eugeniy Paltsev , Vinod Koul Cc: dmaengine@vger.kernel.org, linux-kernel@vger.kernel.org Subject: [PATCH v3 05/11] dmaengine: dw-axi-dmac: delay irq getting until request_irq Date: Sun, 21 May 2023 18:12:10 +0800 Message-Id: <20230521101216.4084-6-jszhang@kernel.org> X-Mailer: git-send-email 2.40.0 In-Reply-To: <20230521101216.4084-1-jszhang@kernel.org> References: <20230521101216.4084-1-jszhang@kernel.org> MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Spam-Status: No, score=-7.1 required=5.0 tests=BAYES_00,DKIMWL_WL_HIGH, DKIM_SIGNED,DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,RCVD_IN_DNSWL_HI, 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 This is to prepare for per-channel irq support in next patch. In per-channel irq case, we need to parse dt firstly to know whether the platform is per-channel irq or not. Signed-off-by: Jisheng Zhang --- drivers/dma/dw-axi-dmac/dw-axi-dmac-platform.c | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/drivers/dma/dw-axi-dmac/dw-axi-dmac-platform.c b/drivers/dma/dw-axi-dmac/dw-axi-dmac-platform.c index e596910e9f84..64b4ee2d618b 100644 --- a/drivers/dma/dw-axi-dmac/dw-axi-dmac-platform.c +++ b/drivers/dma/dw-axi-dmac/dw-axi-dmac-platform.c @@ -1403,10 +1403,6 @@ static int dw_probe(struct platform_device *pdev) chip->dev = &pdev->dev; chip->dw->hdata = hdata; - chip->irq = platform_get_irq(pdev, 0); - if (chip->irq < 0) - return chip->irq; - chip->regs = devm_platform_ioremap_resource(pdev, 0); if (IS_ERR(chip->regs)) return PTR_ERR(chip->regs); @@ -1447,6 +1443,10 @@ static int dw_probe(struct platform_device *pdev) if (!dw->chan) return -ENOMEM; + chip->irq = platform_get_irq(pdev, 0); + if (chip->irq < 0) + return chip->irq; + ret = devm_request_irq(chip->dev, chip->irq, dw_axi_dma_interrupt, IRQF_SHARED, KBUILD_MODNAME, chip); if (ret) -- 2.40.0