From mboxrd@z Thu Jan 1 00:00:00 1970 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 D0199606A32C for ; Thu, 3 Dec 2026 14:18:43 +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=er1/eArN Received: from gabe.freedesktop.org (localhost [127.0.0.1]) by gabe.freedesktop.org (Postfix) with ESMTP id 2F48210E739; Thu, 3 Dec 2026 14:18:38 +0000 (UTC) Received: from tor.source.kernel.org (tor.source.kernel.org [172.105.4.254]) by gabe.freedesktop.org (Postfix) with ESMTPS id BAD3410E76F for ; Thu, 3 Dec 2026 14:18:31 +0000 (UTC) Received: from smtp.kernel.org (quasi.space.kernel.org [100.103.45.18]) by tor.source.kernel.org (Postfix) with ESMTP id 02E0562997; Thu, 3 Dec 2026 14:18:31 +0000 (UTC) Received: by smtp.kernel.org (Postfix) with ESMTPSA id 4210A1F0089C; Thu, 3 Dec 2026 14:18:30 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=kernel.org; s=k20260515; t=1796307510; bh=o2wNjdOcCESDSBQeu6zFg8+76CLbyQ9Lt4yHuzkt5Oc=; h=From:Subject:Reply-To:To:In-Reply-To:References:Date; b=er1/eArNDsQB1/1zsNPMiXAIeKde004kZb2spEy50zMVan1pMpidCvYzCwDf0h3fW u5nMVUWgMuGW4FqVTVoKgdzpBMT6UmM5guuABFAr3ead9sewsUJ0IPX9sXtypOcHjw ct4706RyqB6aKjbIDOlNfn4Y5ItcSYmvHjGLKr6ng0cliAYkS0o9amNZnUsgluhzzB AmOoMT9pY20BgsjqDT7F/k/IOF6+FN8eBgmwDMvohY1P5GsuwoO8Wh+BLTwTSpTcfr OLcVZrwzMSrkGF858ycbBSOvawL8ZJVNl9Pwmu+i6V4iIPXzWDJT4kI8UWA25T9nsC vJvP0iXnGTdxQ== Message-ID: From: sashiko-bot@kernel.org Subject: Re: [PATCH v2 02/10] drm/etnaviv: Release context id on failure To: "Tvrtko Ursulin" , dri-devel@lists.freedesktop.org In-Reply-To: <20261203140128.6813-3-tvrtko.ursulin@igalia.com> References: <20261203140128.6813-1-tvrtko.ursulin@igalia.com> <20261203140128.6813-3-tvrtko.ursulin@igalia.com> Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable Date: Thu, 03 Dec 2026 14:18:29 +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_CR_TRAILER,MAILING_LIST_MULTI,SPF_HELO_NONE,SPF_PASS autolearn=ham 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/etnaviv: missing Fixes trailer for etnaviv_open() XArray leak fix -- commit 5c40c43dfcc5cb8de64c961ddd4b379057974735 Author: Tvrtko Ursulin > drm/etnaviv: Release context id on failure > > Cleanup on the etnaviv_open() failure path looks incomplete in that the > context id is left allocated. Fix it by adding proper onion unwind. > > Signed-off-by: Tvrtko Ursulin > Cc: Lucas Stach > Cc: Russell King > Cc: Christian Gmeiner > Cc: etnaviv@lists.freedesktop.org [Severity: Low] Even though the context ids are unused, leaving them in priv->active_contexts leaks XArray slots and xa_node slab memory (and a dangling ctx pointer) until etnaviv_unbind(). On IOMMUv2, etnaviv_iommuv2_context_alloc() fails once 512 contexts are open, so repeated failed opens can leak unbounded kernel memory without memory pressure. Since this fixes a memory leak introduced when xa_alloc_cyclic() was added to etnaviv_open(), should this include: Fixes: d306788b6e1b ("drm/etnaviv: allocate unique ID per drm_file") --=20 Sashiko AI review =C2=B7 https://sashiko.dev/#/patchset/20261203140128.6813= -1-tvrtko.ursulin@igalia.com?part=3D2