From mboxrd@z Thu Jan 1 00:00:00 1970 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 0EE33E7718C for ; Fri, 20 Dec 2024 18:24:47 +0000 (UTC) Received: from gabe.freedesktop.org (localhost [127.0.0.1]) by gabe.freedesktop.org (Postfix) with ESMTP id C577D10E0C3; Fri, 20 Dec 2024 18:24:46 +0000 (UTC) Authentication-Results: gabe.freedesktop.org; dkim=pass (2048-bit key; unprotected) header.d=intel.com header.i=@intel.com header.b="QXr0xu51"; dkim-atps=neutral Received: from mgamail.intel.com (mgamail.intel.com [198.175.65.11]) by gabe.freedesktop.org (Postfix) with ESMTPS id F014510E0C3 for ; Fri, 20 Dec 2024 18:24:45 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=intel.com; i=@intel.com; q=dns/txt; s=Intel; t=1734719086; x=1766255086; h=date:message-id:from:to:cc:subject:in-reply-to: references:mime-version; bh=njvRuhwGYLkG9GW9TDdg+WmpiA05nAzpjdsP62G7VXI=; b=QXr0xu51oNZjFvoKgrwWPa+Zt5tyipdj2pvCjXqf8cTN/ztX4lHjF2Qt tkN7+y1KshYU6fndiVUO2M0/AJLnx7q53vQp0ovKQ4qLxwQz1SG0oTwUj CUL4hEELVJQh4r+PPXRT9Gd1lc90P5kdnbmSsG4F5bTWDfk6XBP5jVUoT znk8CjjzxgVcssExHfmlqAKg6pGiFbJRc9h91RdR7GJ+hFF+MTiyv3GTt L1pOvfb+eAOdY7zZqyOoX5LDczwHhKFOxxEdIdY9+25B7GZgigVXOm3nL YR0IsS3nwmtkc1Fq/MTAfMvaiO/s/E0FuWWwbvcUzoTSVqrATJzSUx8Ts g==; X-CSE-ConnectionGUID: 3TzFlj8GSVKh74ugD/iHeg== X-CSE-MsgGUID: 75i9Yn7BTeW+R01kpZRXOw== X-IronPort-AV: E=McAfee;i="6700,10204,11292"; a="45767597" X-IronPort-AV: E=Sophos;i="6.12,251,1728975600"; d="scan'208";a="45767597" Received: from orviesa005.jf.intel.com ([10.64.159.145]) by orvoesa103.jf.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 20 Dec 2024 10:24:46 -0800 X-CSE-ConnectionGUID: BRjeYNMoQfOzrfEaDui1vA== X-CSE-MsgGUID: Gbr0Sh04Qq+1fI+APFUCWg== X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="6.12,224,1728975600"; d="scan'208";a="103570529" Received: from orsosgc001.jf.intel.com (HELO orsosgc001.intel.com) ([10.165.21.142]) by orviesa005-auth.jf.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 20 Dec 2024 10:24:46 -0800 Date: Fri, 20 Dec 2024 10:24:45 -0800 Message-ID: <85wmfu5i1e.wl-ashutosh.dixit@intel.com> From: "Dixit, Ashutosh" To: "Cavitt, Jonathan" Cc: "Nerlige Ramappa, Umesh" , "intel-xe@lists.freedesktop.org" , "Souza, Jose" Subject: Re: [PATCH v5 1/2] xe/oa: Fix query mode of operation for OAR/OAC In-Reply-To: References: <20241220171919.571528-1-umesh.nerlige.ramappa@intel.com> <20241220171919.571528-2-umesh.nerlige.ramappa@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/28.2 (x86_64-redhat-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: intel-xe@lists.freedesktop.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: Intel Xe graphics driver List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: intel-xe-bounces@lists.freedesktop.org Sender: "Intel-xe" On Fri, 20 Dec 2024 10:08:41 -0800, Cavitt, Jonathan wrote: > > > diff --git a/drivers/gpu/drm/xe/xe_ring_ops.c b/drivers/gpu/drm/xe/xe_ring_ops.c > > index 3a75a08b6be9..c8ab37fa0d19 100644 > > --- a/drivers/gpu/drm/xe/xe_ring_ops.c > > +++ b/drivers/gpu/drm/xe/xe_ring_ops.c > > @@ -223,7 +223,10 @@ static int emit_pipe_imm_ggtt(u32 addr, u32 value, bool stall_only, u32 *dw, > > > > static u32 get_ppgtt_flag(struct xe_sched_job *job) > > { > > - return job->q->vm ? BIT(8) : 0; > > + if (job->q->vm && !job->ggtt) > > + return BIT(8); > > Non-blocking question: > I'm assuming that xe_oa_submit_bb isn't the only function that can submit > jobs for get_ppgtt_flag to decode, because otherwise job->ggtt would always > return true? Look at callers of xe_sched_job_push.