lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <20240801000834.3930818-67-sashal@kernel.org>
Date: Wed, 31 Jul 2024 20:00:05 -0400
From: Sasha Levin <sashal@...nel.org>
To: linux-kernel@...r.kernel.org,
	stable@...r.kernel.org
Cc: Himal Prasad Ghimiray <himal.prasad.ghimiray@...el.com>,
	Michal Wajdeczko <michal.wajdeczko@...el.com>,
	Rodrigo Vivi <rodrigo.vivi@...el.com>,
	Lucas De Marchi <lucas.demarchi@...el.com>,
	Badal Nilawar <badal.nilawar@...el.com>,
	Sasha Levin <sashal@...nel.org>,
	thomas.hellstrom@...ux.intel.com,
	maarten.lankhorst@...ux.intel.com,
	mripard@...nel.org,
	tzimmermann@...e.de,
	airlied@...il.com,
	daniel@...ll.ch,
	intel-xe@...ts.freedesktop.org,
	dri-devel@...ts.freedesktop.org
Subject: [PATCH AUTOSEL 6.10 067/121] drm/xe: Check valid domain is passed in xe_force_wake_ref

From: Himal Prasad Ghimiray <himal.prasad.ghimiray@...el.com>

[ Upstream commit 35feb8dbbca627d118ccc1f2111841788c142703 ]

Assert domain is not XE_FORCEWAKE_ALL.

v2
- use domain != XE_FORCEWAKE_ALL (Michal)

v3
- Fix commit description.

Cc: Michal Wajdeczko <michal.wajdeczko@...el.com>
Cc: Rodrigo Vivi <rodrigo.vivi@...el.com>
Cc: Lucas De Marchi <lucas.demarchi@...el.com>
Cc: Badal Nilawar <badal.nilawar@...el.com>
Signed-off-by: Himal Prasad Ghimiray <himal.prasad.ghimiray@...el.com>
Reviewed-by: Michal Wajdeczko <michal.wajdeczko@...el.com>
Link: https://patchwork.freedesktop.org/patch/msgid/20240607125741.1407331-2-himal.prasad.ghimiray@intel.com
Signed-off-by: Rodrigo Vivi <rodrigo.vivi@...el.com>
Signed-off-by: Sasha Levin <sashal@...nel.org>
---
 drivers/gpu/drm/xe/xe_force_wake.h | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/drivers/gpu/drm/xe/xe_force_wake.h b/drivers/gpu/drm/xe/xe_force_wake.h
index 83cb157da7cc6..23b36d13f18a6 100644
--- a/drivers/gpu/drm/xe/xe_force_wake.h
+++ b/drivers/gpu/drm/xe/xe_force_wake.h
@@ -24,7 +24,7 @@ static inline int
 xe_force_wake_ref(struct xe_force_wake *fw,
 		  enum xe_force_wake_domains domain)
 {
-	xe_gt_assert(fw->gt, domain);
+	xe_gt_assert(fw->gt, domain != XE_FORCEWAKE_ALL);
 	return fw->domains[ffs(domain) - 1].ref;
 }
 
-- 
2.43.0


Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ