Received: by 2002:ac0:c50a:0:0:0:0:0 with SMTP id y10csp1066326imi; Fri, 1 Jul 2022 02:16:34 -0700 (PDT) X-Google-Smtp-Source: AGRyM1s5ZTqSaH4EhLzWeIqwwPQoWERQ+hWpvrfxAN/0iIuRQoXaej/PKPkkjc+CGNaz3RmZ55mU X-Received: by 2002:a17:903:2350:b0:16a:4246:f1b6 with SMTP id c16-20020a170903235000b0016a4246f1b6mr19576439plh.35.1656666993954; Fri, 01 Jul 2022 02:16:33 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1656666993; cv=none; d=google.com; s=arc-20160816; b=n9ojRp1r8tLraaHblDfE41To47W1ePZ/XW4c63kDTGAt4TsLJzdQL/mXRwY58jY+gD tJoZkBPU313z3glMaK71C8kYnBwAg0abu+XJ4EjkdiernerqJqQXrDypOZmL5HF40j1A 7JYyekHh8B/GXvPRIyG9WLaedO00ewqlclWRClVN/638YzUUDXK+eKJ+VB0dQz11o6XQ eB+27/i5oCweRkoH1MIKJ+mdq+QEkIgm9N1tQUHqPMp9v02Sj+GzwGbnYB24iVsyia88 YP0Mf5FHXspRikYNnxprFcQKeQwijGZTEi5t5ExjDFB2YHhP/Nez8Ud3NOz+Y8aUeG1r kf5w== 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=LCuIx00muqQirfVd6jOt5jbjUQnrAhAAImN1NyQ3ehw=; b=0blwMmbZJFEP06/Kp1zNKHNy8/cOivr3OY4kj2ZCFtwfJjdLSE41P7SvL63fQnVzn1 w7wpa1HcOdGGja0e+uWFI7AGX8i2Qrh6ObRDJ0uDmYqzf5P7IBOA1Mxb+AGAtNJ6FCOy zHsNojMUFFYbIbf4E9mFttlbUHd94NNokhvszdifGV2kg1lCxxQbZEXfn29Gqoqc62Fd Lo4KeJNVPObrVK28YC7MPB/30hBz0PEE84Oo7Igk0H2b54QRQ4v27+cqId2c2b/luJnE vwGFH7ome4+Y8tQnPZgQI2vQ8m05jkcbUs7rI6DZdKRck3aHwvTybwzwCo65UwgAoaRx nHdA== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@collabora.com header.s=mail header.b="g/ZoW+eX"; 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 e2-20020a63f542000000b003fccbc8a085si27940733pgk.782.2022.07.01.02.16.22; Fri, 01 Jul 2022 02:16:33 -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="g/ZoW+eX"; 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 S234056AbiGAJD6 (ORCPT + 99 others); Fri, 1 Jul 2022 05:03:58 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:47278 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S233719AbiGAJD5 (ORCPT ); Fri, 1 Jul 2022 05:03:57 -0400 Received: from madras.collabora.co.uk (madras.collabora.co.uk [IPv6:2a00:1098:0:82:1000:25:2eeb:e5ab]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 96E68B41; Fri, 1 Jul 2022 02:03:54 -0700 (PDT) Received: from dimapc.. (109-252-118-164.nat.spd-mgts.ru [109.252.118.164]) (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 4702766015B2; Fri, 1 Jul 2022 10:03:52 +0100 (BST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=collabora.com; s=mail; t=1656666233; bh=oOZf0LBfOP2Mrd3kKdfyQSfqWEThXNW2359k+fuby8k=; h=From:To:Cc:Subject:Date:From; b=g/ZoW+eXIu7Ti6gYKeb8pEQXflxFZnZtIgcDJCDmjroTBaTPeja2pKbeaIAjYymTd KILCpbkQSCCJXeFo58JBWy7iHoru61NtEyGNJ2bbKudDblMl7ZQ3o6ld1kTArsXvnc ukDXgP30Lea0adEDSIbT1mIAaj71TSffSXe6kNNPbumqNusmWLq84VCzKVf+fRvNE9 t3FqRFroAFay5VZ0jYDkAoQyEgI/7TXu7L4ob/oaSLlQN2ylLvojj33ljEkzIzP9DF 9YlSvXFkv2+VmP23itjJZgqQUsLsixQMR/XNII8UxlTU/Sanz/obTLqXGq84pk1tY0 KIpg5seL4xU5Q== From: Dmitry Osipenko To: David Airlie , Gerd Hoffmann , Gurchetan Singh , Chia-I Wu , Daniel Vetter , Maarten Lankhorst , Maxime Ripard , Thomas Zimmermann , Emil Velikov , =?UTF-8?q?Christian=20K=C3=B6nig?= , =?UTF-8?q?Thomas=20Hellstr=C3=B6m?= Cc: dri-devel@lists.freedesktop.org, linux-kernel@vger.kernel.org, Dmitry Osipenko , linux-tegra@vger.kernel.org, kernel@collabora.com, virtualization@lists.linux-foundation.org Subject: [PATCH v8 0/2] DRM GEM fixes Date: Fri, 1 Jul 2022 12:02:38 +0300 Message-Id: <20220701090240.1896131-1-dmitry.osipenko@collabora.com> X-Mailer: git-send-email 2.36.1 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 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, 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 patchset fixes two problems in the common GEM code. First fixed problem is the bogus lockdep splat that complicates debugging of DRM drivers. Second problem is the inconsistency in behaviour and improper handling of mapping the imported GEMs by some drivers, to fix it we will prohibit to map the imported GEMs like majority of drivers already do. Changelog: v8: - Dropped stable tag from the "Don't map imported GEMs" patch, like was suggested by Thomas Hellström in the review comment to v7. v7: - Factored out GEM patches from [1] since I'll be working on the dma-buf locking in a separate patchset now. [1] https://lore.kernel.org/all/20220526235040.678984-1-dmitry.osipenko@collabora.com/ - Improved commit message and added fixes tag to the "Properly annotate WW context" patch. - Replaced "Move mapping of imported dma-bufs to drm_gem_mmap_obj()" patch with "Don't map imported GEMs", like was suggested by Thomas Hellström. - Added r-b and suggested-by from Thomas Hellström. Dmitry Osipenko (2): drm/gem: Properly annotate WW context on drm_gem_lock_reservations() error drm/gem: Don't map imported GEMs drivers/gpu/drm/drm_gem.c | 8 ++++++-- drivers/gpu/drm/drm_gem_shmem_helper.c | 9 --------- 2 files changed, 6 insertions(+), 11 deletions(-) -- 2.36.1