Received: by 2002:a05:6358:1087:b0:cb:c9d3:cd90 with SMTP id j7csp1603748rwi; Thu, 20 Oct 2022 14:55:22 -0700 (PDT) X-Google-Smtp-Source: AMsMyM74jrr5E8HhyYqfVL5XIXn+1XBmr8P3MKru3LH5nD0GbRMkHFc8q7T5s7kJP0jLjKd6xJp7 X-Received: by 2002:a17:90b:1d0d:b0:20d:5c1c:5fbb with SMTP id on13-20020a17090b1d0d00b0020d5c1c5fbbmr53990463pjb.196.1666302922140; Thu, 20 Oct 2022 14:55:22 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1666302922; cv=none; d=google.com; s=arc-20160816; b=zRtCPz5IY7ZElkMNdl/3HJWiIWawSKGOOfWoCD/idrCNrorNmKgOgT8KYKqAZMjx2s U6T/pDCsWH6W1BCHi71h1xomWKIQr5OXlaYndXQwN+/wcSa27yFFDJvEU8d4JCniols2 YHgAYAPXGjY0zG5QiR5VmNckwuGPFPCIUR923bCKOrL0O1zvcSpUpU0O3sGEUk+IvUsd dhIeyOUVXT7SrRCdn5U3VIW2HPU4fKUEyMcidzQqrLVyGQQcEerYsXRVmqCvKDkXyz1T /VbZDESyXSWA70O2byem6ktrvOLy0XIl45lexj1iQt0a3iHypK3wUoQlsjSTrj2sK+/a xCZQ== 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:from:dkim-signature; bh=PGYiMuF1g45MgAi5zevV1eaA28VDOvDPEM8ocuKmMmo=; b=FLHpslN+9e6H/ZNaw83OQ9A1ROid7807BQgAeaS40iB0ZbeA3t1sjwwH+uBuAu76SN TzsAEsce71vLO9JYzA4q+gvAh84ztbqFvoc4NYsK7es+pgFetgAxBCVNNwocxOm3heRV dbUjcVTUGC2XIZ/iQzn3xTWpucCpU50k+15+OJubtIRdZfHz4WfIvIBRzWUH3AdEpIUD 33L5iBg4emFtMCBPMaxxHZYoy6EjQVPp0SkG846c8Rjme0Ix/kYARLyBxnwSl0YSMYro u8MV4iGm5YV62Q4ZUCiyYHqsyFKEeg0/4rbPKNoqY1Ph4Sm0Egj6YMw3hqA28ib9g6VL zYsQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@collabora.com header.s=mail header.b=DZg3T6V0; 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=collabora.com Return-Path: Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id ja12-20020a170902efcc00b0016ce3d67e7csi4253197plb.387.2022.10.20.14.55.10; Thu, 20 Oct 2022 14:55:22 -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=@collabora.com header.s=mail header.b=DZg3T6V0; 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=collabora.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S229925AbiJTVeL (ORCPT + 99 others); Thu, 20 Oct 2022 17:34:11 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:60402 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S230035AbiJTVeD (ORCPT ); Thu, 20 Oct 2022 17:34:03 -0400 Received: from madras.collabora.co.uk (madras.collabora.co.uk [46.235.227.172]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 2121722659D for ; Thu, 20 Oct 2022 14:34:02 -0700 (PDT) Received: from dimapc.. (109-252-119-114.nat.spd-mgts.ru [109.252.119.114]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (No client certificate requested) (Authenticated sender: dmitry.osipenko) by madras.collabora.co.uk (Postfix) with ESMTPSA id B47256602482; Thu, 20 Oct 2022 22:33:59 +0100 (BST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=collabora.com; s=mail; t=1666301640; bh=W/n3zjR0a0jDhmMKl2jfwwXY/Ev21PtBnp6TxNf3TdM=; h=From:To:Cc:Subject:Date:From; b=DZg3T6V0kTVvs1FEuwfZdP0wxeYg6Jw4gcj36RvqnQAGIrYbmX6YMQ2Be8h3il2z7 ZELjQq0HaZGNlHaiI0ddU3aSafRy5u72PmmAzU9oQ3DLBdxyRHU4bNg3UwcB69W266 Q9uhHKOT3iT0SJAJjOEbZ/RhwiS5NJF+riGVEjXZOm3ei8adf2BRjQCvgs0y7RI17j xOg7iTDGHxLUaPzFCPesyG02WzHdYbYnM0BEtuksQ39pPH6eikTTk7j+6o1quI36bE ESw500SPsXaglHsuCn0ZDHMC9aqNyLwr+oyBr5CiD2WutBhv0vtf4paolNaXuPmuU7 THricDcNFDM7w== From: Dmitry Osipenko To: Maarten Lankhorst , Maxime Ripard , Thomas Zimmermann , =?UTF-8?q?Christian=20K=C3=B6nig?= , David Airlie , Daniel Vetter Cc: dri-devel@lists.freedesktop.org, linux-kernel@vger.kernel.org Subject: [PATCH v1] drm: Switch drm_client_buffer_delete() to unlocked drm_gem_vunmap Date: Fri, 21 Oct 2022 00:33:35 +0300 Message-Id: <20221020213335.309092-1-dmitry.osipenko@collabora.com> X-Mailer: git-send-email 2.37.3 MIME-Version: 1.0 Content-Transfer-Encoding: 8bit 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, URIBL_BLOCKED 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 drm_client_buffer_delete() wasn't switched to unlocked GEM vunmapping by accident when rest of drm_client code transitioned to the unlocked variants of the vmapping functions. Make drm_client_buffer_delete() use the unlocked variant. This fixes lockdep warning splat about missing reservation lock when framebuffer is released. Reported-by: kernel test robot Link: https://lore.kernel.org/dri-devel/890f70db-68b0-8456-ca3c-c5496ef90517@collabora.com/T/ Fixes: 79e2cf2e7a19 ("drm/gem: Take reservation lock for vmap/vunmap operations") Signed-off-by: Dmitry Osipenko --- drivers/gpu/drm/drm_client.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/gpu/drm/drm_client.c b/drivers/gpu/drm/drm_client.c index fbcb1e995384..38e1be991caa 100644 --- a/drivers/gpu/drm/drm_client.c +++ b/drivers/gpu/drm/drm_client.c @@ -235,7 +235,7 @@ static void drm_client_buffer_delete(struct drm_client_buffer *buffer) { struct drm_device *dev = buffer->client->dev; - drm_gem_vunmap(buffer->gem, &buffer->map); + drm_gem_vunmap_unlocked(buffer->gem, &buffer->map); if (buffer->gem) drm_gem_object_put(buffer->gem); -- 2.37.3