Received: by 2002:a05:6358:7058:b0:131:369:b2a3 with SMTP id 24csp6861136rwp; Tue, 18 Jul 2023 06:57:34 -0700 (PDT) X-Google-Smtp-Source: APBJJlGwlqFYwKCOMCHW3yTDWHRyFtxG2JnZIEFrGEUfm7U6IGsWq0gDjWLYkVPqQ502yIqwo4hC X-Received: by 2002:a2e:908d:0:b0:2b5:7dd9:74f5 with SMTP id l13-20020a2e908d000000b002b57dd974f5mr11200404ljg.21.1689688653922; Tue, 18 Jul 2023 06:57:33 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1689688653; cv=none; d=google.com; s=arc-20160816; b=w5WBzhXjc7FSYgqIGGEMTawmiuskej7fGJxb5g+1JzH+4isfCjVQWEoV4m4gHQbFQp bkSACpMoXfiVDXaT+RbD2DyDeKScrpBF9LYAIec++5uHBkGe8VbjDzpSTz0ZvZmr/FE0 so+LmL+JV9GlMRllO1wDfO0Dh9aACqP20puKwqjicM8ugaheraPCkPwGj0jAIJZM/uzy PS+5pCe7KZtpsDP6M9lVyIz/A8zuCPqHjTF7YbSdauijyJOY/KeOsGt4sSyIzH7i6q14 luvcQrHUbBZgyXh5U+3WvFd3CbZHOPgi8+5VH9aFJUWAO4b60VIIxnL9FoiQEqJABx2f jWdA== 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 :organization:from:references:cc:to:content-language:subject :user-agent:mime-version:date:message-id:dkim-signature; bh=cEu1yb4Zgq1SLELJ8rlpOHBQWwE2NJnVWaDiK7u0B4Q=; fh=Tk/ZuiI/I5YL5OqeSVb8MxSQJh9IKWE34wMck2Jfzvs=; b=QIFaFf/B15cIK69ohsrD+Q4i4bB9ZF4o5M7VVmjOTtGGARdFoLm/GsTT1VmRfAhiXG HC5fZtaYQCc3nsk5CxzQ6Alvdt1K5LQWWGP+cGPhTGGxV0scw0wliMc1scM2oh+p/X4P v4EA5+o9lqriF79Q/zDDtwprzklb6Lhr/OAnQQHyvisIKilcH+uFLpF/NtnLYGqV4Nhk F2FWgjOIXW+QzLek4LHD5qczrnuJ4wPOLIFNIEUTyKyzKSPzotjI0OGJ9+EaOh2Lplr3 JAesOjV9dZq3EN+cabA9ithG5oxW4AW3h2rrJXyThIMg+RdX/ZGe/uPLh3pisexXrd34 jjqA== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@redhat.com header.s=mimecast20190719 header.b=G7h3ahF7; 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=redhat.com Return-Path: Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id gl23-20020a170906e0d700b0099453f837easi1203796ejb.616.2023.07.18.06.57.09; Tue, 18 Jul 2023 06:57: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=@redhat.com header.s=mimecast20190719 header.b=G7h3ahF7; 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=redhat.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S231305AbjGRNgS (ORCPT + 99 others); Tue, 18 Jul 2023 09:36:18 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:38460 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S231325AbjGRNgQ (ORCPT ); Tue, 18 Jul 2023 09:36:16 -0400 Received: from us-smtp-delivery-124.mimecast.com (us-smtp-delivery-124.mimecast.com [170.10.129.124]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 112D6115 for ; Tue, 18 Jul 2023 06:35:27 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=redhat.com; s=mimecast20190719; t=1689687327; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=cEu1yb4Zgq1SLELJ8rlpOHBQWwE2NJnVWaDiK7u0B4Q=; b=G7h3ahF7YZIu7wF/bCeYmvQ2knQ7V0soXbpPHE1MRYjb9Ixn0sxVgW9ODMZ6vXWAYBdUAp S+vRPC4yg6s886n4dWD9bhxdZoQqCjIz2TSdEhqk2WMrLTtlUzcpnlHd9NdW4KRXu8eemt 1C4yAd78NWRFWSNFUTpxvDTzigwiF9w= Received: from mail-ej1-f71.google.com (mail-ej1-f71.google.com [209.85.218.71]) by relay.mimecast.com with ESMTP with STARTTLS (version=TLSv1.3, cipher=TLS_AES_256_GCM_SHA384) id us-mta-29-1DY-lJquM-uOXvJN7Kdbkg-1; Tue, 18 Jul 2023 09:35:25 -0400 X-MC-Unique: 1DY-lJquM-uOXvJN7Kdbkg-1 Received: by mail-ej1-f71.google.com with SMTP id a640c23a62f3a-98843cc8980so354738766b.1 for ; Tue, 18 Jul 2023 06:35:25 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20221208; t=1689687325; x=1692279325; h=content-transfer-encoding:in-reply-to:organization:from:references :cc:to:content-language:subject:user-agent:mime-version:date :message-id:x-gm-message-state:from:to:cc:subject:date:message-id :reply-to; bh=cEu1yb4Zgq1SLELJ8rlpOHBQWwE2NJnVWaDiK7u0B4Q=; b=JT1MvLu+9FIoRDofbFsoXaMOGRxTBSGrl3vukdZrBOkPggR8QlbYaIiJOHLYz/QjP1 5GyDuG+OgCyuv2U85osxj0SNsoM2n1gXbDy90bP9BVZsRyv3zFNaX/toIdgY1vfgu0D0 tr6ruw4Mw0MyzYlQUL8Sfs6W67WHnRhM6HAHg0tRJhYo1e9YCOaXcJRqK1zr9zQZCqfm HsAyKFC1Xm7t7VIkse3lBPfqTsueDaj/0vYFAItgtbM+tvT+JR+lpVOEcIzycZB4aQYR 1qNmTWtKvDlezJfG0+5aQ+SgIR76hFb6e0Fz0o+UDXCx0Pw45Wk8EnEvCYGG1AOcsyoo 7rVA== X-Gm-Message-State: ABy/qLaUmJ5218W+KiGz4AdwLNsq0odunFCuEcxMozfDXmU9YMTb/tAL suCgaXp0534cZLCH9lbEcXX3lU6PRsVayGET8rspgxCTve6kvbT355uo0eRkG2Td0fg2cokrid9 Qd9Hq3z19rjWDVrUh8qMKswkg X-Received: by 2002:a17:906:eb82:b0:991:f7cb:cc3d with SMTP id mh2-20020a170906eb8200b00991f7cbcc3dmr13327528ejb.65.1689687324861; Tue, 18 Jul 2023 06:35:24 -0700 (PDT) X-Received: by 2002:a17:906:eb82:b0:991:f7cb:cc3d with SMTP id mh2-20020a170906eb8200b00991f7cbcc3dmr13327514ejb.65.1689687324521; Tue, 18 Jul 2023 06:35:24 -0700 (PDT) Received: from ?IPV6:2a02:810d:4b3f:de9c:642:1aff:fe31:a15c? ([2a02:810d:4b3f:de9c:642:1aff:fe31:a15c]) by smtp.gmail.com with ESMTPSA id d1-20020a056402516100b00521a3d8474csm1244859ede.57.2023.07.18.06.35.23 (version=TLS1_3 cipher=TLS_AES_128_GCM_SHA256 bits=128/128); Tue, 18 Jul 2023 06:35:24 -0700 (PDT) Message-ID: <51968407-c87a-e565-28f7-868a1b923d5c@redhat.com> Date: Tue, 18 Jul 2023 13:38:48 +0200 MIME-Version: 1.0 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:102.0) Gecko/20100101 Thunderbird/102.12.0 Subject: Re: [PATCH drm-next v7 02/13] drm: manager to keep track of GPUs VA mappings Content-Language: en-US To: Donald Robson , "corbet@lwn.net" , "jason@jlekstrand.net" , "willy@infradead.org" , "christian.koenig@amd.com" , "tzimmermann@suse.de" , "bagasdotme@gmail.com" , "mripard@kernel.org" , "matthew.brost@intel.com" , "bskeggs@redhat.com" , "ogabbay@kernel.org" , "boris.brezillon@collabora.com" , "Liam.Howlett@oracle.com" , "daniel@ffwll.ch" , "alexdeucher@gmail.com" , "airlied@gmail.com" Cc: "dri-devel@lists.freedesktop.org" , "nouveau@lists.freedesktop.org" , "airlied@redhat.com" , "linux-doc@vger.kernel.org" , "linux-kernel@vger.kernel.org" , "thomas.hellstrom@linux.intel.com" References: <20230713170429.2964-1-dakr@redhat.com> <20230713170429.2964-3-dakr@redhat.com> From: Danilo Krummrich Organization: RedHat In-Reply-To: Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 7bit X-Spam-Status: No, score=-2.2 required=5.0 tests=BAYES_00,DKIMWL_WL_HIGH, DKIM_SIGNED,DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,NICE_REPLY_A, RCVD_IN_DNSWL_NONE,RCVD_IN_MSPIKE_H4,RCVD_IN_MSPIKE_WL,SPF_HELO_NONE, SPF_NONE,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 On 7/17/23 12:00, Donald Robson wrote: > Hi Danilo, > The below part of the documentation is out of date now. > Thanks, > Donald Thanks Donald for pointing this out. If there aren't any further objections in general I will fix up the comment and then push the GPUVA Manager parts of the series to drm-misc-next. - Danilo > > On Thu, 2023-07-13 at 19:03 +0200, Danilo Krummrich wrote: >> >> + >> +/** >> + * DOC: Locking >> + * >> + * Generally, the GPU VA manager does not take care of locking itself, it is >> + * the drivers responsibility to take care about locking. Drivers might want to >> + * protect the following operations: inserting, removing and iterating >> + * &drm_gpuva objects as well as generating all kinds of operations, such as >> + * split / merge or prefetch. >> + * >> + * The GPU VA manager also does not take care of the locking of the backing >> + * &drm_gem_object buffers GPU VA lists by itself; drivers are responsible to >> + * enforce mutual exclusion using either the GEMs dma_resv lock or alternatively >> + * a driver specific external lock by setting the @DRM_GPUVA_MANAGER_LOCK_EXTERN >> + * flag. >> + * >> + * For the latter, functions such as drm_gpuva_link() or drm_gpuva_unlink() >> + * contain lockdep checks to indicate locking issues. For this to work drivers >> + * must provide (in case the @DRM_GPUVA_MANAGER_LOCK_EXTERN flag is set) their >> + * external lock with drm_gpuva_manager_set_ext_lock() after initialization. >> + */ >>