Received: from gabe.freedesktop.org (gabe.freedesktop.org [131.252.210.177]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature ECDSA (prime256v1) server-digest SHA256) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id B9A08606A322 for ; Wed, 2 Dec 2026 00:00:04 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=kernel.org header.i=@kernel.org header.a=rsa-sha256 header.s=k20260515 header.b=fsCiLT4O Received: from gabe.freedesktop.org (localhost [127.0.0.1]) by gabe.freedesktop.org (Postfix) with ESMTP id 2A0E410E475; Tue, 1 Dec 2026 23:59:59 +0000 (UTC) Received: from tor.source.kernel.org (tor.source.kernel.org [172.105.4.254]) by gabe.freedesktop.org (Postfix) with ESMTPS id 0D98A10E473; Tue, 1 Dec 2026 23:59:53 +0000 (UTC) Received: from smtp.kernel.org (quasi.space.kernel.org [100.103.45.18]) by tor.source.kernel.org (Postfix) with ESMTP id 1828660D97; Tue, 1 Dec 2026 23:59:52 +0000 (UTC) Received: by smtp.kernel.org (Postfix) with ESMTPSA id A7C6E1F000C1; Tue, 1 Dec 2026 23:59:51 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=kernel.org; s=k20260515; t=1796169591; bh=9caVK73yQdkgHMH6coo5bglG1SKhQ2l202EXIwYf9fQ=; h=From:Subject:Reply-To:To:In-Reply-To:References:Date; b=fsCiLT4O//nkbJNy/AtA2ZBY9HvF/SNR4AGPdS6EbdeQ/wKkV6nqCX0DtbJg2V58j 0TM1HL1BD+km3R0o+h8ZtgeqeMFgxqSUN6TXZqN/gynsk8df+iDKOElSlqfw9lHJEz y9b5cWdnJNQDTs+ZHCwHzV2Z5p55V9cuvVrXi07BqgGrCh87uDBFmU2yCuB/hH9Uqd IndkADPcHIj7Pc19v0Oyz9gE7BiNxuvImXb7zTDFHb8kamkV/iQmBXC/gNyVpMvR2A VzbKY1VXrNSYrakACYh/ynpsITkh2+1LAlM6wezRLk4aL++dQUbowPn0IEcBDRlhMA 2ygknEZZjCcaA== Message-ID: From: sashiko-bot@kernel.org Subject: Re: [PATCH v4 04/33] drm/ttm: Introduce ttm_pool_alloc_iter for __ttm_pool_alloc() To: "Matthew Brost" , intel-xe@lists.freedesktop.org, dri-devel@lists.freedesktop.org In-Reply-To: <20261201234915.3305331-5-matthew.brost@intel.com> References: <20261201234915.3305331-1-matthew.brost@intel.com> <20261201234915.3305331-5-matthew.brost@intel.com> Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable Date: Tue, 01 Dec 2026 23:59:51 +0000 X-BeenThere: dri-devel@lists.freedesktop.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: Direct Rendering Infrastructure - Development List-Archive: List-Post: List-Help: List-Subscribe: , Reply-To: sashiko-reviews@lists.linux.dev Sender: "dri-devel" X-Spam-Status: No, score=-10.8 required=3.0 tests=BAYES_00,DKIMWL_WL_HIGH, DKIM_SIGNED,DKIM_VALID,DKIM_VALID_AU,HEADER_FROM_DIFFERENT_DOMAINS, INCLUDES_PATCH,MAILING_LIST_MULTI,SPF_HELO_NONE,SPF_PASS autolearn=unavailable autolearn_force=no version=4.0.1 X-Spam-Checker-Version: SpamAssassin 4.0.1 (2024-03-26) on aws-us-west-2-korg-listserv-alma10-1 X-Archived-By: Thank you for your contribution! Sashiko AI review found 1 potential issue to consider: - [Low] drm/ttm: undocumented members in struct ttm_pool_alloc_iter kernel-doc -- commit 55191542c8efeda1b184b4e3fe2cf25c45f7fe3d Author: Matthew Brost drm/ttm: Introduce ttm_pool_alloc_iter for __ttm_pool_alloc() This commit factors the working state of the allocation loop in __ttm_pool_alloc() into struct ttm_pool_alloc_iter and splits page acquisition and order fallback into helper functions. > diff --git a/drivers/gpu/drm/ttm/ttm_pool.c b/drivers/gpu/drm/ttm/ttm_poo= l.c > index e06bd3cf68553..5b0a21a1f0c22 100644 > --- a/drivers/gpu/drm/ttm/ttm_pool.c > +++ b/drivers/gpu/drm/ttm/ttm_pool.c > @@ -807,18 +807,100 @@ static unsigned int ttm_pool_alloc_find_order(unsi= gned int highest, > return min_t(unsigned int, highest, __fls(alloc->remaining_pages)); > } > =20 > +/** > + * struct ttm_pool_alloc_iter - Working state for the __ttm_pool_alloc()= loop > + * > + * Bundles the immutable inputs and the mutable per-order state that the > + * allocation phase helpers share, so the main loop reads as a short seq= uence > + * of named phases rather than one deeply nested block. > + */ > +struct ttm_pool_alloc_iter { > + /* Immutable for the duration of the allocation. */ > + struct ttm_pool *pool; > + struct ttm_tt *tt; > + const struct ttm_operation_ctx *ctx; > + struct ttm_pool_alloc_state *alloc; > + unsigned int beneficial_order; > + gfp_t gfp_flags; > + > + /* Mutated as the loop walks the orders. */ > + unsigned int order; > + enum ttm_caching page_caching; > + bool allow_pools; > + struct page *p; > +}; [Severity: Low] The comment above struct ttm_pool_alloc_iter uses the /** kernel-doc marker without describing its struct members, causing W=3D1 and documentation builds (via Documentation/gpu/drm-mm.rst) to emit kernel-doc warnings for each field. Should the members be documented or the comment changed to start with /*? --=20 Sashiko AI review =C2=B7 https://sashiko.dev/#/patchset/20261201234915.3305= 331-1-matthew.brost@intel.com?part=3D4