Received: by 2002:a05:6358:1087:b0:cb:c9d3:cd90 with SMTP id j7csp6545569rwi; Mon, 24 Oct 2022 02:56:17 -0700 (PDT) X-Google-Smtp-Source: AMsMyM4kJ7/L0abM3vqYNv6JuLQyK6j6yxs11ZWmQB3Ie8utdWwkwkJWdMczW8Zbodz+axmsmXTo X-Received: by 2002:aa7:cd92:0:b0:456:cbb5:2027 with SMTP id x18-20020aa7cd92000000b00456cbb52027mr29716110edv.384.1666605377578; Mon, 24 Oct 2022 02:56:17 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1666605377; cv=none; d=google.com; s=arc-20160816; b=xPkFwEtFp59IEwN+YUmAXalJ6lTsCnCGpDv4V9jSS6AGXD0VvMEWUyQJLzwFgKZgwA 9kSkdNZS4OcZ2gwtKFc9922klOtojNl2fX76zjo/ZDSzOWE169XSa3Pscx2IVExQ9JBS 2mgNjU73pMmpsuYsER3CQLJbBw4LW++7WTAX1dBKG8M43LrCu4gL+0YaFx8C8oXa5c/q Mv0cCvrSfJszmR8kTY0axMNsj0EDPmVL38SCN1lrYidTCzoJkZj2P5AKABiunSimOgeG swogOOU54WWZlv+hcZOuQvtyhTMfqy5lEgHnd90Cza6pNvY27rQDskHc13B75booBIPF 1clA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:in-reply-to:from :references:cc:to:content-language:subject:user-agent:mime-version :date:message-id; bh=5p4kIdVbAChAOQ0q71SU2GaZ2d2CY9flYm4TwdIOLAs=; b=tdCE8zVZfT6yXBsD+PCqs5KKqMceZ7PqdwudMdxckcO72ZxW1K1s52Ruxmj4TDZ6nE s1QK/GWBAK3KpVWC8QrmLteI4ScWPDJSiDZCKR8iIF4AdPAzMagQ9zzMGy8tZLEAIior sLtcgVqW2n7uIPLQgLDcQ1Rxt7lbKCkJqBwus+/FFrb7BzqBS2Y04vbNsLfGoONsulLl gfG7aFBN1hl5sngd4YDzCSv/sbhy4DGwWhPqVwkfCyfckyPkWkB8q2oM0N3wADugeljB sG2XIjVZqmpvlry3WeVpjsguZx/RszwifPlEovwUKpcLhP264+6nvLJbIfVhTlHoGG5c Jzew== ARC-Authentication-Results: i=1; mx.google.com; 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=fail (p=NONE sp=NONE dis=NONE) header.from=xs4all.nl Return-Path: Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id a26-20020a17090682da00b0078d9d67841fsi22059818ejy.400.2022.10.24.02.55.52; Mon, 24 Oct 2022 02:56:17 -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; 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=fail (p=NONE sp=NONE dis=NONE) header.from=xs4all.nl Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S229940AbiJXJTR (ORCPT + 99 others); Mon, 24 Oct 2022 05:19:17 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:52802 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S230232AbiJXJSl (ORCPT ); Mon, 24 Oct 2022 05:18:41 -0400 Received: from dfw.source.kernel.org (dfw.source.kernel.org [IPv6:2604:1380:4641:c500::1]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 2083B30567; Mon, 24 Oct 2022 02:18:10 -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 1AF256112A; Mon, 24 Oct 2022 09:18:10 +0000 (UTC) Received: by smtp.kernel.org (Postfix) with ESMTPSA id 9E91FC433D6; Mon, 24 Oct 2022 09:18:00 +0000 (UTC) Message-ID: <9781200b-2d6e-b401-abc5-559410b1a435@xs4all.nl> Date: Mon, 24 Oct 2022 11:17:58 +0200 MIME-Version: 1.0 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:102.0) Gecko/20100101 Thunderbird/102.3.2 Subject: Re: [PATCH v7 14/21] media: tegra-vde: Prepare to dynamic dma-buf locking specification Content-Language: en-US To: Dmitry Osipenko , David Airlie , Gerd Hoffmann , Gurchetan Singh , Chia-I Wu , Daniel Vetter , Daniel Almeida , Gert Wollny , Gustavo Padovan , Daniel Stone , Tomeu Vizoso , Maarten Lankhorst , Maxime Ripard , Thomas Zimmermann , Rob Clark , Sumit Semwal , =?UTF-8?Q?Christian_K=c3=b6nig?= , "Pan, Xinhui" , Thierry Reding , Tomasz Figa , Marek Szyprowski , Mauro Carvalho Chehab , Alex Deucher , Jani Nikula , Joonas Lahtinen , Rodrigo Vivi , Tvrtko Ursulin , =?UTF-8?Q?Thomas_Hellstr=c3=b6m?= , Qiang Yu , Srinivas Kandagatla , Amol Maheshwari , Jason Gunthorpe , Leon Romanovsky , Juergen Gross , Stefano Stabellini , Oleksandr Tyshchenko , Tomi Valkeinen , Russell King , Lucas Stach , Christian Gmeiner , Ruhl Michael J Cc: dri-devel@lists.freedesktop.org, linux-kernel@vger.kernel.org, Dmitry Osipenko , linux-media@vger.kernel.org, linaro-mm-sig@lists.linaro.org, amd-gfx@lists.freedesktop.org, intel-gfx@lists.freedesktop.org, kernel@collabora.com, virtualization@lists.linux-foundation.org, linux-rdma@vger.kernel.org, linux-arm-msm@vger.kernel.org References: <20221017172229.42269-1-dmitry.osipenko@collabora.com> <20221017172229.42269-15-dmitry.osipenko@collabora.com> From: Hans Verkuil In-Reply-To: <20221017172229.42269-15-dmitry.osipenko@collabora.com> Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-Spam-Status: No, score=-6.7 required=5.0 tests=BAYES_00, HEADER_FROM_DIFFERENT_DOMAINS,NICE_REPLY_A,RCVD_IN_DNSWL_HI, 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 On 10/17/22 19:22, Dmitry Osipenko wrote: > Prepare Tegra video decoder driver to the common dynamic dma-buf > locking convention by starting to use the unlocked versions of dma-buf > API functions. > > Acked-by: Christian König Acked-by: Hans Verkuil Thanks! Hans > Signed-off-by: Dmitry Osipenko > --- > drivers/media/platform/nvidia/tegra-vde/dmabuf-cache.c | 6 +++--- > 1 file changed, 3 insertions(+), 3 deletions(-) > > diff --git a/drivers/media/platform/nvidia/tegra-vde/dmabuf-cache.c b/drivers/media/platform/nvidia/tegra-vde/dmabuf-cache.c > index 69c346148070..1c5b94989aec 100644 > --- a/drivers/media/platform/nvidia/tegra-vde/dmabuf-cache.c > +++ b/drivers/media/platform/nvidia/tegra-vde/dmabuf-cache.c > @@ -38,7 +38,7 @@ static void tegra_vde_release_entry(struct tegra_vde_cache_entry *entry) > if (entry->vde->domain) > tegra_vde_iommu_unmap(entry->vde, entry->iova); > > - dma_buf_unmap_attachment(entry->a, entry->sgt, entry->dma_dir); > + dma_buf_unmap_attachment_unlocked(entry->a, entry->sgt, entry->dma_dir); > dma_buf_detach(dmabuf, entry->a); > dma_buf_put(dmabuf); > > @@ -102,7 +102,7 @@ int tegra_vde_dmabuf_cache_map(struct tegra_vde *vde, > goto err_unlock; > } > > - sgt = dma_buf_map_attachment(attachment, dma_dir); > + sgt = dma_buf_map_attachment_unlocked(attachment, dma_dir); > if (IS_ERR(sgt)) { > dev_err(dev, "Failed to get dmabufs sg_table\n"); > err = PTR_ERR(sgt); > @@ -152,7 +152,7 @@ int tegra_vde_dmabuf_cache_map(struct tegra_vde *vde, > err_free: > kfree(entry); > err_unmap: > - dma_buf_unmap_attachment(attachment, sgt, dma_dir); > + dma_buf_unmap_attachment_unlocked(attachment, sgt, dma_dir); > err_detach: > dma_buf_detach(dmabuf, attachment); > err_unlock: