From patchwork Thu Jan 2 20:38:14 2025 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: =?utf-8?q?Adri=C3=A1n_Mart=C3=ADnez_Larumbe?= X-Patchwork-Id: 13924922 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from gabe.freedesktop.org (gabe.freedesktop.org [131.252.210.177]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.lore.kernel.org (Postfix) with ESMTPS id 3C3D1E77188 for ; Thu, 2 Jan 2025 20:38:49 +0000 (UTC) Received: from gabe.freedesktop.org (localhost [127.0.0.1]) by gabe.freedesktop.org (Postfix) with ESMTP id AF53210E26F; Thu, 2 Jan 2025 20:38:48 +0000 (UTC) Authentication-Results: gabe.freedesktop.org; dkim=pass (1024-bit key; unprotected) header.d=collabora.com header.i=adrian.larumbe@collabora.com header.b="K4Fg5s6R"; dkim-atps=neutral Received: from sender4-pp-f112.zoho.com (sender4-pp-f112.zoho.com [136.143.188.112]) by gabe.freedesktop.org (Postfix) with ESMTPS id 04BB710E25B for ; Thu, 2 Jan 2025 20:38:47 +0000 (UTC) ARC-Seal: i=1; a=rsa-sha256; t=1735850316; cv=none; d=zohomail.com; s=zohoarc; b=acv3p5sgEGSYTRQU61dVIU6V8teRrxagCUXle0/KAibsiaPXtLcOoFgfTzQfDEPyvGdKFdNylUW+c/RdN4aSnx8E3pql5NdRv0MO0qXtCuJdzibVKm2PjIyRQtqx0UNyUHpsZZ3OEEKhVodMQKJaXFRXxZLWEn7YeVv8HBLFvXE= ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=zohomail.com; s=zohoarc; t=1735850316; h=Content-Type:Content-Transfer-Encoding:Cc:Cc:Date:Date:From:From:In-Reply-To:MIME-Version:Message-ID:References:Subject:Subject:To:To:Message-Id:Reply-To; bh=0UeNwoUaq+YbHbez8CqameKDfwyStQr+9FdgNR4PpwU=; b=ZI6tRLTVWFBwYW4ha6G+hOzrwHDSy9cU/bLIDcqFG49qyWkE8DIiHLkpeEc6Ln1AHHn/9aDv+CGCwZark7v39TUwIRGXI94hd/ZQYx7MfBP0uhK/gO5riEULWKlzEmdVOm5bxisdBrbEQTAjEMSCCU4IoVk5b3hTALO7CzCzQ/g= ARC-Authentication-Results: i=1; mx.zohomail.com; dkim=pass header.i=collabora.com; spf=pass smtp.mailfrom=adrian.larumbe@collabora.com; dmarc=pass header.from= DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; t=1735850315; s=zohomail; d=collabora.com; i=adrian.larumbe@collabora.com; h=From:From:To:To:Cc:Cc:Subject:Subject:Date:Date:Message-ID:In-Reply-To:References:MIME-Version:Content-Type:Content-Transfer-Encoding:Message-Id:Reply-To; bh=0UeNwoUaq+YbHbez8CqameKDfwyStQr+9FdgNR4PpwU=; b=K4Fg5s6R32vDDjjignfJ6wmkWAswz2/YAr5vJIk3tqB8y7XnXk6taiCx0P5Wnvio Xzd+AI1QhSdDgZ/ayf+oFHR5y2dCzBrp1Sg3m2TFyIj1U8mJxlYNhyAW4p6XITzrAzj lUwk7sh0lUpboyoGNNBlpXs6z+RJAvaBNKoP9OC0= Received: by mx.zohomail.com with SMTPS id 1735850315208358.2078159642475; Thu, 2 Jan 2025 12:38:35 -0800 (PST) From: =?utf-8?q?Adri=C3=A1n_Larumbe?= To: Boris Brezillon , Steven Price , Liviu Dudau , Maarten Lankhorst , Maxime Ripard , Thomas Zimmermann , David Airlie , Simona Vetter Cc: kernel@collabora.com, =?utf-8?q?Adri=C3=A1n_Larumbe?= , Mihail Atanassov , dri-devel@lists.freedesktop.org, linux-kernel@vger.kernel.org Subject: [PATCH v6 2/2] Documentation/gpu: Add fdinfo meanings of drm-*-internal memory tags Date: Thu, 2 Jan 2025 20:38:14 +0000 Message-ID: <20250102203817.956790-3-adrian.larumbe@collabora.com> X-Mailer: git-send-email 2.47.0 In-Reply-To: <20250102203817.956790-1-adrian.larumbe@collabora.com> References: <20250102203817.956790-1-adrian.larumbe@collabora.com> MIME-Version: 1.0 X-BeenThere: dri-devel@lists.freedesktop.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: Direct Rendering Infrastructure - Development List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: dri-devel-bounces@lists.freedesktop.org Sender: "dri-devel" A previous commit enabled display of driver-internal kernel BO sizes through the device file's fdinfo interface. Expand the description of the relevant driver-specific key:value pairs with the definitions of the new drm-*-internal ones. Reviewed-by: Mihail Atanassov Reviewed-by: Liviu Dudau Reviewed-by: Steven Price Signed-off-by: Adrián Larumbe --- Documentation/gpu/panthor.rst | 14 ++++++++++++++ 1 file changed, 14 insertions(+) diff --git a/Documentation/gpu/panthor.rst b/Documentation/gpu/panthor.rst index 3f8979fa2b86..23aa3d67c9d2 100644 --- a/Documentation/gpu/panthor.rst +++ b/Documentation/gpu/panthor.rst @@ -26,6 +26,10 @@ the currently possible format options: drm-cycles-panthor: 94439687187 drm-maxfreq-panthor: 1000000000 Hz drm-curfreq-panthor: 1000000000 Hz + drm-total-internal: 10396 KiB + drm-shared-internal: 0 + drm-active-internal: 10396 KiB + drm-resident-internal: 10396 KiB drm-total-memory: 16480 KiB drm-shared-memory: 0 drm-active-memory: 16200 KiB @@ -44,3 +48,13 @@ driver by writing into the appropriate sysfs node:: Where `N` is a bit mask where cycle and timestamp sampling are respectively enabled by the first and second bits. + +Possible `drm-*-internal` keys are: `total`, `active`, `resident` and `shared`. +These values convey the sizes of the internal driver-owned shmem BO's that +aren't exposed to user-space through a DRM handle, like queue ring buffers, +sync object arrays and heap chunks. Because they are all allocated and pinned +at creation time, `drm-resident-internal` and `drm-total-internal` should always +be equal. `drm-active-internal` shows the size of kernel BO's associated with +VM's and groups currently being scheduled for execution by the GPU. +`drm-shared-internal` is unused at present, but in the future it might stand for +the size of executable FW regions, since they do not belong to an open file context.