From patchwork Wed Oct 19 13:23:23 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: =?utf-8?q?Martin_Povi=C5=A1er?= X-Patchwork-Id: 5481 Return-Path: Delivered-To: ouuuleilei@gmail.com Received: by 2002:a5d:4ac7:0:0:0:0:0 with SMTP id y7csp333287wrs; Wed, 19 Oct 2022 06:40:36 -0700 (PDT) X-Google-Smtp-Source: AMsMyM5O7E3QZK5Qf4pG9+t36X+sGYumTbBumCDWADuMO2oj6obzQnbkk9Xq28vtDLtb5ERo04HD X-Received: by 2002:a05:6402:278c:b0:45c:da8e:837d with SMTP id b12-20020a056402278c00b0045cda8e837dmr7678850ede.18.1666186825769; Wed, 19 Oct 2022 06:40:25 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1666186825; cv=none; d=google.com; s=arc-20160816; b=wKGXLXRAYytSQ/GWO3qwmhrOlg/vbfjkbsbgTNNGb58/FO55NJnifUAJeSItvscl5w QBgrMQjD2S9i/GRg8L/lpiR8xuXsnGHdtgTGD6W9YpON2qu6tQCs70IzDFiMKowj8/nm MwsV3FnFSIUJPQgPLFAS9w2RSO3QtaGY9hX5KoRxmUtdwrFdBUAQtBkEmoawYxFgEab4 nASWlsz4toPoofXSyNcfz73dwLHJzDX5Ot4g6iYV6CvPATJLWYwgScVxrbPLOorNopLo zt8FHROmtwgUaOOCyzU+NOYdPtyX11I2Q24PXDgT5r2N2PxyZv2AZyGrd2QMQO02FW5j I4PQ== 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 :message-id:date:subject:cc:to:dkim-signature:from; bh=00XpFFUQMJvRxGis99g6ozE8OJO2nXC2MC4LveWM/4k=; b=Id8GiZVz0w52GMMcHcbvAMF2EM+N5AXKoEcKwVoAAxeqS5gin1b7Y7wMUy1/B17wmV 1+WycEktgKojFeHsgCFJEFljAJsmUvl5t7gOMq/ThQtN1d/2lSyahlmh0JwHYDWAfGR1 NywNFtBVC6D1JgyTb7N9TtRukXg6XEMZQsnLkBpuUM6rzJmjIz/P5DtWUXVD/aAC9IY1 GqLaXQn3KxkXVGlQw66sQImCgATnL4EIOV4q50zsRovqGcA01r5QEr85fyCfJXa8/Epf iG1G3PFKgM3uKRIV7vtl0aM/8eApi3PmOxmfGwXK3ujsDWiQRIzQVhjHhGYEvuNTvFYT lSzw== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@cutebit.org header.s=mail header.b=qgn+em+f; 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=cutebit.org Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id xg14-20020a170907320e00b00780805b99ccsi15964752ejb.648.2022.10.19.06.39.58; Wed, 19 Oct 2022 06:40:25 -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=@cutebit.org header.s=mail header.b=qgn+em+f; 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=cutebit.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S231670AbiJSNgo (ORCPT + 99 others); Wed, 19 Oct 2022 09:36:44 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:60714 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S230010AbiJSNgG (ORCPT ); Wed, 19 Oct 2022 09:36:06 -0400 Received: from hutie.ust.cz (hutie.ust.cz [185.8.165.127]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id E708D11E47E; Wed, 19 Oct 2022 06:24:53 -0700 (PDT) From: =?utf-8?q?Martin_Povi=C5=A1er?= DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=cutebit.org; s=mail; t=1666185808; bh=00XpFFUQMJvRxGis99g6ozE8OJO2nXC2MC4LveWM/4k=; h=From:To:Cc:Subject:Date; b=qgn+em+fUXd9c0OqunKrr0HB3TkgnoqpJfVxHZFO6AbzjzhRilDuwHSOmsTGrMKB8 ogODkpAq9wKcMnmPLRGOEqhmsf4aQVj72qARmqJ25hsLxLDdBgJ2QpQ8x36gbgRa1c x1beH56jVvPOmCxtHvIwJh9YqCbaXOSc7c4TIHis= To: Vinod Koul Cc: =?utf-8?q?Martin_Povi=C5=A1er?= , asahi@lists.linux.dev, dmaengine@vger.kernel.org, linux-kernel@vger.kernel.org Subject: [PATCH v2 1/2] dmaengine: apple-admac: Fix grabbing of channels in of_xlate Date: Wed, 19 Oct 2022 15:23:23 +0200 Message-Id: <20221019132324.8585-1-povik+lin@cutebit.org> MIME-Version: 1.0 X-Spam-Status: No, score=-2.1 required=5.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,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 X-getmail-retrieved-from-mailbox: =?utf-8?q?INBOX?= X-GMAIL-THRID: =?utf-8?q?1747123517098281928?= X-GMAIL-MSGID: =?utf-8?q?1747123517098281928?= The of_xlate callback is supposed to return the channel after already having 'grabbed' it for private use, so fill that in. Fixes: b127315d9a78 ("dmaengine: apple-admac: Add Apple ADMAC driver") Signed-off-by: Martin PoviĊĦer --- drivers/dma/apple-admac.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/dma/apple-admac.c b/drivers/dma/apple-admac.c index 317ca76ccafd..a2cc520225d3 100644 --- a/drivers/dma/apple-admac.c +++ b/drivers/dma/apple-admac.c @@ -493,7 +493,7 @@ static struct dma_chan *admac_dma_of_xlate(struct of_phandle_args *dma_spec, return NULL; } - return &ad->channels[index].chan; + return dma_get_slave_channel(&ad->channels[index].chan); } static int admac_drain_reports(struct admac_data *ad, int channo)