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 6D7FCD3901A for ; Wed, 14 Jan 2026 21:16:43 +0000 (UTC) Received: from gabe.freedesktop.org (localhost [127.0.0.1]) by gabe.freedesktop.org (Postfix) with ESMTP id 0983B10E69A; Wed, 14 Jan 2026 21:16:43 +0000 (UTC) Authentication-Results: gabe.freedesktop.org; dkim=pass (2048-bit key; unprotected) header.d=intel.com header.i=@intel.com header.b="ArbtJtZM"; dkim-atps=neutral Received: from mgamail.intel.com (mgamail.intel.com [192.198.163.15]) by gabe.freedesktop.org (Postfix) with ESMTPS id D669A10E69D for ; Wed, 14 Jan 2026 21:16:41 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=intel.com; i=@intel.com; q=dns/txt; s=Intel; t=1768425402; x=1799961402; h=date:message-id:from:to:cc:subject:in-reply-to: references:mime-version; bh=RtGxM/AHCRaREAMELWsrvawW7VDdHFV6DWbDKwHy8xI=; b=ArbtJtZMKxzyjGYYOyBNtw3XkDZxGg6+9Zgx9FNpICVbsrruvthifUNb o3/l84f4Yl9LjlRluc3zuxE2rgYbU0tuo5Zdxz52Q+KpLLiC5xuZS3BEN WRyXchj1LYQVSfqv/FKflAIGJNKyImX833hJiKYOq1ZMVN918mDfc0Mh0 JOAZ5Jy7MmvOpOPfWA5ZcBhC2OG16Okjs/RCtrsrSh2vGnmmgPR4EZ8LT j9AjWxIw00xF4ARcHu6ieYa9Ednf8JMROYI/q0VpvwkhIuBioOLGNrlkv qpV5OKy4KN9fZxyvDmt9uHkj90hT/gSNndKC74hnYdLkk7lRT5VwF62RZ w==; X-CSE-ConnectionGUID: G2ugIf0bRNyQ9KP1gJxzng== X-CSE-MsgGUID: xTRIqScSThO2bT3Ftj5AlA== X-IronPort-AV: E=McAfee;i="6800,10657,11671"; a="69818155" X-IronPort-AV: E=Sophos;i="6.21,226,1763452800"; d="scan'208";a="69818155" Received: from orviesa003.jf.intel.com ([10.64.159.143]) by fmvoesa109.fm.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 14 Jan 2026 13:16:41 -0800 X-CSE-ConnectionGUID: rfOOO5nSS9amoLIIPKCFNg== X-CSE-MsgGUID: LDicJtuvSt6MaKyb//34fA== X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="6.21,226,1763452800"; d="scan'208";a="208945405" Received: from unknown (HELO adixit-MOBL3.intel.com) ([10.125.41.191]) by ORVIESA003-auth.jf.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 14 Jan 2026 13:16:42 -0800 Date: Wed, 14 Jan 2026 13:16:40 -0800 Message-ID: <878qdzyjwn.wl-ashutosh.dixit@intel.com> From: "Dixit, Ashutosh" To: Shuicheng Lin Cc: igt-dev@lists.freedesktop.org Subject: Re: [PATCH] tests/intel/xe_exec_compute_mode: Fix tmpfile open mode In-Reply-To: <20260114211327.285279-1-shuicheng.lin@intel.com> References: <20260114211327.285279-1-shuicheng.lin@intel.com> User-Agent: Wanderlust/2.15.9 (Almost Unreal) SEMI-EPG/1.14.7 (Harue) FLIM-LB/1.14.9 (=?ISO-8859-4?Q?Goj=F2?=) APEL-LB/10.8 EasyPG/1.0.0 Emacs/30.2 (x86_64-pc-linux-gnu) MULE/6.0 (HANACHIRUSATO) MIME-Version: 1.0 (generated by SEMI-EPG 1.14.7 - "Harue") Content-Type: text/plain; charset=US-ASCII X-BeenThere: igt-dev@lists.freedesktop.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: Development mailing list for IGT GPU Tools List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: igt-dev-bounces@lists.freedesktop.org Sender: "igt-dev" On Wed, 14 Jan 2026 13:13:27 -0800, Shuicheng Lin wrote: > > replace the bogus 0x666 mode with 0666 when creating the tmpfile. > assert the tmpfile descriptor before writing to it. Reviewed-by: Ashutosh Dixit > > Signed-off-by: Shuicheng Lin > --- > tests/intel/xe_exec_compute_mode.c | 3 ++- > 1 file changed, 2 insertions(+), 1 deletion(-) > > diff --git a/tests/intel/xe_exec_compute_mode.c b/tests/intel/xe_exec_compute_mode.c > index cf68319be..438ea163f 100644 > --- a/tests/intel/xe_exec_compute_mode.c > +++ b/tests/intel/xe_exec_compute_mode.c > @@ -270,7 +270,8 @@ test_exec(int fd, struct drm_xe_engine_class_instance *eci, > > if (flags & RACE) { > map_fd = open("/tmp", O_TMPFILE | O_RDWR, > - 0x666); > + 0666); > + igt_assert_neq(map_fd, -1); > igt_assert_eq(write(map_fd, data, bo_size), > bo_size); > data = mmap((void *)MAP_ADDRESS, bo_size, > -- > 2.34.1 >