Re: [PATCH v2] drm/i915/guc: Use context hints for GT freq

2024-02-28 Thread Belgaumkar, Vinay
On 2/28/2024 4:54 AM, Tvrtko Ursulin wrote: On 27/02/2024 23:51, Vinay Belgaumkar wrote: Allow user to provide a low latency context hint. When set, KMD sends a hint to GuC which results in special handling for this context. SLPC will ramp the GT frequency aggressively every time it switches

Re: [PATCH] drm/i915/guc: Add Compute context hint

2024-02-23 Thread Belgaumkar, Vinay
On 2/23/2024 12:51 AM, Tvrtko Ursulin wrote: On 22/02/2024 23:31, Belgaumkar, Vinay wrote: On 2/22/2024 7:32 AM, Tvrtko Ursulin wrote: On 21/02/2024 21:28, Rodrigo Vivi wrote: On Wed, Feb 21, 2024 at 09:42:34AM +, Tvrtko Ursulin wrote: On 21/02/2024 00:14, Vinay Belgaumkar wrote

Re: [PATCH] drm/i915/guc: Add Compute context hint

2024-02-22 Thread Belgaumkar, Vinay
On 2/22/2024 7:32 AM, Tvrtko Ursulin wrote: On 21/02/2024 21:28, Rodrigo Vivi wrote: On Wed, Feb 21, 2024 at 09:42:34AM +, Tvrtko Ursulin wrote: On 21/02/2024 00:14, Vinay Belgaumkar wrote: Allow user to provide a context hint. When this is set, KMD will send a hint to GuC which

Re: [PATCH] drm/i915/mtl: Wake GT before sending H2G message

2024-01-18 Thread Belgaumkar, Vinay
On 1/18/2024 3:50 PM, Matt Roper wrote: On Thu, Jan 18, 2024 at 03:17:28PM -0800, Vinay Belgaumkar wrote: Instead of waiting until the interrupt reaches GuC, we can grab a forcewake while triggering the H2G interrupt. GEN11_GUC_HOST_INTERRUPT is inside an "always on" domain with respect to

Re: [Intel-gfx] [PATCH v2 1/4] drm/i915: Enable Wa_16019325821

2023-12-13 Thread Belgaumkar, Vinay
On 10/27/2023 2:18 PM, john.c.harri...@intel.com wrote: From: John Harrison Some platforms require holding RCS context switches until CCS is idle (the reverse w/a of Wa_14014475959). Some platforms require both versions. Signed-off-by: John Harrison ---

Re: [Intel-gfx] [PATCH v2 3/4] drm/i915/guc: Enable Wa_14019159160

2023-12-13 Thread Belgaumkar, Vinay
On 10/27/2023 2:18 PM, john.c.harri...@intel.com wrote: From: John Harrison Use the new w/a KLV support to enable a MTL w/a. Note, this w/a is a super-set of Wa_16019325821, so requires turning that one as well as setting the new flag for Wa_14019159160 itself. Signed-off-by: John Harrison

Re: [Intel-gfx] [PATCH v2 2/4] drm/i915/guc: Add support for w/a KLVs

2023-12-13 Thread Belgaumkar, Vinay
On 10/27/2023 2:18 PM, john.c.harri...@intel.com wrote: From: John Harrison To prevent running out of bits, new w/a enable flags are being added via a KLV system instead of a 32 bit flags word. Signed-off-by: John Harrison --- .../gpu/drm/i915/gt/uc/abi/guc_errors_abi.h | 1 +

Re: [Intel-gfx] [PATCH] drm/i915: Read a shadowed mmio register for ggtt flush

2023-11-09 Thread Belgaumkar, Vinay
On 11/9/2023 12:35 PM, Ville Syrjälä wrote: On Thu, Nov 09, 2023 at 12:01:26PM -0800, Belgaumkar, Vinay wrote: On 11/9/2023 11:30 AM, Ville Syrjälä wrote: On Thu, Nov 09, 2023 at 11:21:48AM -0800, Vinay Belgaumkar wrote: We read RENDER_HEAD as a part of the flush. If GT is in deeper sleep

Re: [Intel-gfx] [PATCH] drm/i915: Read a shadowed mmio register for ggtt flush

2023-11-09 Thread Belgaumkar, Vinay
On 11/9/2023 11:30 AM, Ville Syrjälä wrote: On Thu, Nov 09, 2023 at 11:21:48AM -0800, Vinay Belgaumkar wrote: We read RENDER_HEAD as a part of the flush. If GT is in deeper sleep states, this could lead to read errors since we are not using a forcewake. Safer to read a shadowed register

Re: [Intel-gfx] [PATCH] drm/i915/mtl: Don't set PIPE_CONTROL_FLUSH_L3

2023-10-16 Thread Belgaumkar, Vinay
On 10/16/2023 4:24 PM, John Harrison wrote: On 10/16/2023 15:55, Vinay Belgaumkar wrote: This bit does not cause an explicit L3 flush. We already use At all? Or only on newer hardware? And as a genuine spec change or as a bug / workaround? If the hardware has re-purposed the bit then it is

Re: [Intel-gfx] [PATCH 3/4] drm/i915/guc: Add support for w/a KLVs

2023-10-06 Thread Belgaumkar, Vinay
On 9/15/2023 2:55 PM, john.c.harri...@intel.com wrote: From: John Harrison To prevent running out of bits, new w/a enable flags are being added via a KLV system instead of a 32 bit flags word. Signed-off-by: John Harrison --- .../gpu/drm/i915/gt/uc/abi/guc_errors_abi.h | 1 +

Re: [Intel-gfx] [PATCH 2/4] drm/i915: Enable Wa_16019325821

2023-10-06 Thread Belgaumkar, Vinay
On 9/15/2023 2:55 PM, john.c.harri...@intel.com wrote: From: John Harrison Some platforms require holding RCS context switches until CCS is idle (the reverse w/a of Wa_14014475959). Some platforms require both versions. Signed-off-by: John Harrison ---

Re: [Intel-gfx] [PATCH 2/2] drm/i915/guc: Enable WA 14018913170

2023-10-05 Thread Belgaumkar, Vinay
On 9/14/2023 3:28 PM, john.c.harri...@intel.com wrote: From: Daniele Ceraolo Spurio The GuC handles the WA, the KMD just needs to set the flag to enable it on the appropriate platforms. Signed-off-by: John Harrison Signed-off-by: Daniele Ceraolo Spurio ---

Re: [Intel-gfx] [PATCH] drm/i915/gem: Allow users to disable waitboost

2023-09-27 Thread Belgaumkar, Vinay
On 9/21/2023 3:41 AM, Tvrtko Ursulin wrote: On 20/09/2023 22:56, Vinay Belgaumkar wrote: Provide a bit to disable waitboost while waiting on a gem object. Waitboost results in increased power consumption by requesting RP0 while waiting for the request to complete. Add a bit in the gem_wait()

Re: [Intel-gfx] [PATCH] drm/i915/guc/slpc: Restore efficient freq earlier

2023-07-21 Thread Belgaumkar, Vinay
On 7/21/2023 3:08 PM, Belgaumkar, Vinay wrote: On 7/21/2023 2:23 PM, Rodrigo Vivi wrote: On Fri, Jul 21, 2023 at 01:44:34PM -0700, Belgaumkar, Vinay wrote: On 7/21/2023 1:41 PM, Rodrigo Vivi wrote: On Fri, Jul 21, 2023 at 11:03:49AM -0700, Vinay Belgaumkar wrote: This should be done

Re: [Intel-gfx] [PATCH] drm/i915/guc/slpc: Restore efficient freq earlier

2023-07-21 Thread Belgaumkar, Vinay
On 7/21/2023 2:23 PM, Rodrigo Vivi wrote: On Fri, Jul 21, 2023 at 01:44:34PM -0700, Belgaumkar, Vinay wrote: On 7/21/2023 1:41 PM, Rodrigo Vivi wrote: On Fri, Jul 21, 2023 at 11:03:49AM -0700, Vinay Belgaumkar wrote: This should be done before the soft min/max frequencies are restored. When

Re: [PATCH] drm/i915/guc/slpc: Restore efficient freq earlier

2023-07-21 Thread Belgaumkar, Vinay
On 7/21/2023 1:41 PM, Rodrigo Vivi wrote: On Fri, Jul 21, 2023 at 11:03:49AM -0700, Vinay Belgaumkar wrote: This should be done before the soft min/max frequencies are restored. When we disable the "Ignore efficient frequency" flag, GuC does not actually bring the requested freq down to RPn.

Re: [Intel-gfx] [PATCH] drm/i915/guc: Dump perf_limit_reasons for debug

2023-06-27 Thread Belgaumkar, Vinay
On 6/26/2023 11:43 PM, Dixit, Ashutosh wrote: On Mon, 26 Jun 2023 21:02:14 -0700, Belgaumkar, Vinay wrote: On 6/26/2023 8:17 PM, Dixit, Ashutosh wrote: On Mon, 26 Jun 2023 19:12:18 -0700, Vinay Belgaumkar wrote: GuC load takes longer sometimes due to GT frequency not ramping up. Add

Re: [Intel-gfx] [PATCH] drm/i915/guc: Dump perf_limit_reasons for debug

2023-06-26 Thread Belgaumkar, Vinay
On 6/26/2023 8:17 PM, Dixit, Ashutosh wrote: On Mon, 26 Jun 2023 19:12:18 -0700, Vinay Belgaumkar wrote: GuC load takes longer sometimes due to GT frequency not ramping up. Add perf_limit_reasons to the existing warn print to see if frequency is being throttled. Signed-off-by: Vinay

Re: [PATCH] drm/i915/guc/slpc: Apply min softlimit correctly

2023-06-14 Thread Belgaumkar, Vinay
On 6/13/2023 7:25 PM, Dixit, Ashutosh wrote: On Fri, 09 Jun 2023 15:02:52 -0700, Vinay Belgaumkar wrote: Hi Vinay, We were skipping when min_softlimit was equal to RPn. We need to apply it rergardless as efficient frequency will push the SLPC min to RPe. regardless This will break

Re: [Intel-gfx] [PATCH] drm/i915/pxp/mtl: intel_pxp_init_hw needs runtime-pm inside pm-complete

2023-06-13 Thread Belgaumkar, Vinay
On 6/1/2023 8:59 AM, Alan Previn wrote: In the case of failed suspend flow or cases where the kernel does not go into full suspend but goes from suspend_prepare back to resume_complete, we get called for a pm_complete but without runtime_pm guaranteed. Thus, ensure we take the runtime_pm when

Re: [Intel-gfx] [PATCH v2 2/2] drm/i915/guc: Dump error capture to dmesg on CTB error

2023-05-16 Thread Belgaumkar, Vinay
On 4/18/2023 11:17 AM, john.c.harri...@intel.com wrote: From: John Harrison In the past, There have been sporadic CTB failures which proved hard to reproduce manually. The most effective solution was to dump the GuC log at the point of failure and let the CI system do the repro. It is

Re: [Intel-gfx] [PATCH v2 1/2] drm/i915: Dump error capture to kernel log

2023-05-16 Thread Belgaumkar, Vinay
On 4/18/2023 11:17 AM, john.c.harri...@intel.com wrote: From: John Harrison This is useful for getting debug information out in certain situations, such as failing kernel selftests and CI runs that don't log error captures. It is especially useful for things like retrieving GuC logs as GuC

Re: [Intel-gfx] [PATCH v2 0/2] Add support for dumping error captures via kernel logging

2023-05-16 Thread Belgaumkar, Vinay
On 4/18/2023 11:17 AM, john.c.harri...@intel.com wrote: From: John Harrison Sometimes, the only effective way to debug an issue is to dump all the interesting information at the point of failure. So add support for doing that. v2: Extra CONFIG wrapping (review feedback from Rodrigo)

Re: [PATCH] drm/i915/guc/slpc: Disable rps_boost debugfs

2023-05-15 Thread Belgaumkar, Vinay
On 5/12/2023 5:39 PM, Dixit, Ashutosh wrote: On Fri, 12 May 2023 16:56:03 -0700, Vinay Belgaumkar wrote: Hi Vinay, rps_boost debugfs shows host turbo related info. This is not valid when SLPC is enabled. A couple of thoughts about this. It appears people are know only about rps_boost_info

Re: [Intel-gfx] [PATCH] drm/i915/guc/slpc: Provide sysfs for efficient freq

2023-04-18 Thread Belgaumkar, Vinay
On 4/17/2023 6:39 PM, Andi Shyti wrote: Hi Vinay, Looks good, just few minor comments below, [...] @@ -267,13 +267,11 @@ static int run_test(struct intel_gt *gt, int test_type) } /* -* Set min frequency to RPn so that we can test the whole -* range of

Re: [Intel-gfx] [PATCH v3] drm/i915/guc/slpc: Provide sysfs for efficient freq

2023-04-17 Thread Belgaumkar, Vinay
On 4/14/2023 4:49 PM, Dixit, Ashutosh wrote: On Fri, 14 Apr 2023 15:34:15 -0700, Vinay Belgaumkar wrote: @@ -457,6 +458,34 @@ int intel_guc_slpc_get_max_freq(struct intel_guc_slpc *slpc, u32 *val) return ret; } +int intel_guc_slpc_set_ignore_eff_freq(struct intel_guc_slpc *slpc,

Re: [PATCH] drm/i915/guc: Disable PL1 power limit when loading GuC firmware

2023-03-24 Thread Belgaumkar, Vinay
On 3/24/2023 4:31 PM, Dixit, Ashutosh wrote: On Fri, 24 Mar 2023 11:15:02 -0700, Belgaumkar, Vinay wrote: Hi Vinay, Thanks for the review. Comments inline below. Sorry about asking the same questions all over again :) Didn't look at previous versions. On 3/15/2023 8:59 PM, Ashutosh Dixit

Re: [PATCH] drm/i915/guc: Disable PL1 power limit when loading GuC firmware

2023-03-24 Thread Belgaumkar, Vinay
On 3/15/2023 8:59 PM, Ashutosh Dixit wrote: On dGfx, the PL1 power limit being enabled and set to a low value results in a low GPU operating freq. It also negates the freq raise operation which is done before GuC firmware load. As a result GuC firmware load can time out. Such timeouts were

Re: [PATCH 3/3] drm/i915/pmu: Use common freq functions with sysfs

2023-03-07 Thread Belgaumkar, Vinay
On 3/7/2023 9:33 PM, Ashutosh Dixit wrote: Using common freq functions with sysfs in PMU (but without taking forcewake) solves the following issues (a) missing support for MTL (b) For the requested_freq, we read it only if actual_freq is zero below (meaning, GT is in C6). So then what is

Re: [Intel-gfx] [PATCH] drm/i915/gsc: Fix the Driver-FLR completion

2023-02-22 Thread Belgaumkar, Vinay
On 2/22/2023 1:01 PM, Alan Previn wrote: The Driver-FLR flow may inadvertently exit early before the full completion of the re-init of the internal HW state if we only poll GU_DEBUG Bit31 (polling for it to toggle from 0 -> 1). Instead we need a two-step completion wait-for-completion flow

Re: [Intel-gfx] [PATCH] drm/i915/mtl: Connect root sysfs entries to GT0

2023-01-16 Thread Belgaumkar, Vinay
On 1/16/2023 10:58 AM, Andi Shyti wrote: Hi, On Thu, Jan 12, 2023 at 08:48:11PM -0800, Belgaumkar, Vinay wrote: On 1/12/2023 8:37 PM, Dixit, Ashutosh wrote: On Thu, 12 Jan 2023 20:26:34 -0800, Belgaumkar, Vinay wrote: I think the ABI was changed by the patch mentioned in the commit

Re: [Intel-gfx] [PATCH] drm/i915/mtl: Connect root sysfs entries to GT0

2023-01-12 Thread Belgaumkar, Vinay
On 1/12/2023 8:37 PM, Dixit, Ashutosh wrote: On Thu, 12 Jan 2023 20:26:34 -0800, Belgaumkar, Vinay wrote: I think the ABI was changed by the patch mentioned in the commit (a8a4f0467d70). The ABI was originally changed in 80cf8af17af04 and 56a709cf77468. Yes, you are right. @Andi, did we

Re: [Intel-gfx] [PATCH] drm/i915/mtl: Connect root sysfs entries to GT0

2023-01-12 Thread Belgaumkar, Vinay
On 1/12/2023 7:15 PM, Dixit, Ashutosh wrote: On Thu, 12 Jan 2023 18:27:52 -0800, Vinay Belgaumkar wrote: Reading current root sysfs entries gives a min/max of all GTs. Updating this so we return default (GT0) values when root level sysfs entries are accessed, instead of min/max for the card.

Re: [Intel-gfx] [PATCH v3 1/1] drm/i915/pxp: Use drm_dbg if arb session failed due to fw version

2023-01-11 Thread Belgaumkar, Vinay
On 12/21/2022 9:49 AM, Alan Previn wrote: If PXP arb-session is being attempted on older hardware SKUs or on hardware with older, unsupported, firmware versions, then don't report the failure with a drm_error. Instead, look specifically for the API-version error reply and drm_dbg that reply.

Re: [PATCH 1/1] drm/i915/mtl: Enable Idle Messaging for GSC CS

2022-11-16 Thread Belgaumkar, Vinay
On 11/15/2022 5:44 AM, Badal Nilawar wrote: From: Vinay Belgaumkar By defaut idle mesaging is disabled for GSC CS so to unblock RC6 entry on media tile idle messaging need to be enabled. v2: - Fix review comments (Vinay) - Set GSC idle hysterisis to 5 us (Badal) Bspec: 71496 Cc:

Re: [PATCH 2/2] drm/i915/mtl: Enable Idle Messaging for GSC CS

2022-11-04 Thread Belgaumkar, Vinay
On 10/31/2022 8:36 PM, Badal Nilawar wrote: From: Vinay Belgaumkar By defaut idle mesaging is disabled for GSC CS so to unblock RC6 entry on media tile idle messaging need to be enabled. C6 entry instead of RC6. Also *needs*. Bspec: 71496 Cc: Daniele Ceraolo Spurio Signed-off-by: Vinay

Re: [Intel-gfx] [PATCH v3] drm/i915/slpc: Use platform limits for min/max frequency

2022-10-24 Thread Belgaumkar, Vinay
On 10/21/2022 10:26 PM, Dixit, Ashutosh wrote: On Fri, 21 Oct 2022 18:38:57 -0700, Belgaumkar, Vinay wrote: On 10/20/2022 3:57 PM, Dixit, Ashutosh wrote: On Tue, 18 Oct 2022 11:30:31 -0700, Vinay Belgaumkar wrote: Hi Vinay, diff --git a/drivers/gpu/drm/i915/gt/selftest_slpc.c b/drivers

Re: [Intel-gfx] [PATCH v4] drm/i915/slpc: Optmize waitboost for SLPC

2022-10-24 Thread Belgaumkar, Vinay
On 10/22/2022 12:22 PM, Dixit, Ashutosh wrote: On Sat, 22 Oct 2022 10:56:03 -0700, Belgaumkar, Vinay wrote: Hi Vinay, diff --git a/drivers/gpu/drm/i915/gt/intel_rps.c b/drivers/gpu/drm/i915/gt/intel_rps.c index fc23c562d9b2..32e1f5dde5bb 100644 --- a/drivers/gpu/drm/i915/gt/intel_rps.c

Re: [Intel-gfx] [PATCH v4] drm/i915/slpc: Optmize waitboost for SLPC

2022-10-22 Thread Belgaumkar, Vinay
On 10/21/2022 7:11 PM, Dixit, Ashutosh wrote: On Fri, 21 Oct 2022 17:24:52 -0700, Vinay Belgaumkar wrote: Hi Vinay, Waitboost (when SLPC is enabled) results in a H2G message. This can result in thousands of messages during a stress test and fill up an already full CTB. There is no need to

Re: [Intel-gfx] [PATCH v3] drm/i915/slpc: Use platform limits for min/max frequency

2022-10-21 Thread Belgaumkar, Vinay
On 10/20/2022 3:57 PM, Dixit, Ashutosh wrote: On Tue, 18 Oct 2022 11:30:31 -0700, Vinay Belgaumkar wrote: Hi Vinay, diff --git a/drivers/gpu/drm/i915/gt/selftest_slpc.c b/drivers/gpu/drm/i915/gt/selftest_slpc.c index 4c6e9257e593..e42bc215e54d 100644 ---

Re: [Intel-gfx] [PATCH v3] drm/i915/slpc: Optmize waitboost for SLPC

2022-10-21 Thread Belgaumkar, Vinay
On 10/21/2022 11:40 AM, Dixit, Ashutosh wrote: On Fri, 21 Oct 2022 11:24:42 -0700, Belgaumkar, Vinay wrote: On 10/20/2022 4:36 PM, Dixit, Ashutosh wrote: On Thu, 20 Oct 2022 13:16:00 -0700, Belgaumkar, Vinay wrote: On 10/20/2022 11:33 AM, Dixit, Ashutosh wrote: On Wed, 19 Oct 2022 17:29

Re: [Intel-gfx] [PATCH v3] drm/i915/slpc: Optmize waitboost for SLPC

2022-10-21 Thread Belgaumkar, Vinay
On 10/20/2022 4:36 PM, Dixit, Ashutosh wrote: On Thu, 20 Oct 2022 13:16:00 -0700, Belgaumkar, Vinay wrote: On 10/20/2022 11:33 AM, Dixit, Ashutosh wrote: On Wed, 19 Oct 2022 17:29:44 -0700, Vinay Belgaumkar wrote: Hi Vinay, Waitboost (when SLPC is enabled) results in a H2G message

Re: [Intel-gfx] [PATCH v3] drm/i915/slpc: Optmize waitboost for SLPC

2022-10-20 Thread Belgaumkar, Vinay
On 10/20/2022 11:33 AM, Dixit, Ashutosh wrote: On Wed, 19 Oct 2022 17:29:44 -0700, Vinay Belgaumkar wrote: Hi Vinay, Waitboost (when SLPC is enabled) results in a H2G message. This can result in thousands of messages during a stress test and fill up an already full CTB. There is no need to

Re: [PATCH v2] drm/i915/slpc: Optmize waitboost for SLPC

2022-10-19 Thread Belgaumkar, Vinay
On 10/19/2022 4:05 PM, Vinay Belgaumkar wrote: Waitboost (when SLPC is enabled) results in a H2G message. This can result in thousands of messages during a stress test and fill up an already full CTB. There is no need to request for RP0 if GuC is already requesting the same. v2: Add the

Re: [Intel-gfx] [PATCH] drm/i915/slpc: Optmize waitboost for SLPC

2022-10-19 Thread Belgaumkar, Vinay
On 10/19/2022 2:12 PM, Belgaumkar, Vinay wrote: On 10/19/2022 12:40 AM, Tvrtko Ursulin wrote: On 18/10/2022 23:15, Vinay Belgaumkar wrote: Waitboost (when SLPC is enabled) results in a H2G message. This can result in thousands of messages during a stress test and fill up an already full

Re: [Intel-gfx] [PATCH] drm/i915/slpc: Optmize waitboost for SLPC

2022-10-19 Thread Belgaumkar, Vinay
On 10/19/2022 12:40 AM, Tvrtko Ursulin wrote: On 18/10/2022 23:15, Vinay Belgaumkar wrote: Waitboost (when SLPC is enabled) results in a H2G message. This can result in thousands of messages during a stress test and fill up an already full CTB. There is no need to request for RP0 if GuC is

Re: [PATCH v2] drm/i915/slpc: Use platform limits for min/max frequency

2022-10-13 Thread Belgaumkar, Vinay
On 10/13/2022 3:28 PM, Dixit, Ashutosh wrote: On Thu, 13 Oct 2022 08:55:24 -0700, Vinay Belgaumkar wrote: Hi Vinay, GuC will set the min/max frequencies to theoretical max on ATS-M. This will break kernel ABI, so limit min/max frequency to RP0(platform max) instead. Isn't what we are

Re: [PATCH] drm/i915/slpc: Use platform limits for min/max frequency

2022-10-13 Thread Belgaumkar, Vinay
On 10/13/2022 8:14 AM, Das, Nirmoy wrote: On 10/12/2022 8:26 PM, Vinay Belgaumkar wrote: GuC will set the min/max frequencies to theoretical max on ATS-M. This will break kernel ABI, so limit min/max frequency to RP0(platform max) instead. Also modify the SLPC selftest to update the min

Re: [Intel-gfx] [PATCH] drm/i915/slpc: Use platform limits for min/max frequency

2022-10-13 Thread Belgaumkar, Vinay
On 10/13/2022 4:34 AM, Tauro, Riana wrote: On 10/12/2022 11:56 PM, Vinay Belgaumkar wrote: GuC will set the min/max frequencies to theoretical max on ATS-M. This will break kernel ABI, so limit min/max frequency to RP0(platform max) instead. Also modify the SLPC selftest to update the min

Re: [PATCH 1/2] drm/i915: Add a wrapper for frequency debugfs

2022-10-04 Thread Belgaumkar, Vinay
On 10/4/2022 12:36 AM, Jani Nikula wrote: On Mon, 03 Oct 2022, Vinay Belgaumkar wrote: Move it to the RPS source file. The idea was that the 1st patch would be non-functional code movement. This is still a functional change. Or you can do the functional changes first, and then move code,

Re: [PATCH] drm/i915/guc/slpc: Allow SLPC to use efficient frequency

2022-08-24 Thread Belgaumkar, Vinay
On 8/15/2022 10:32 AM, Rodrigo Vivi wrote: On Sun, Aug 14, 2022 at 04:46:54PM -0700, Vinay Belgaumkar wrote: Host Turbo operates at efficient frequency when GT is not idle unless the user or workload has forced it to a higher level. Replicate the same behavior in SLPC by allowing the

Re: [Intel-gfx] [PATCH] drm/i915/guc/slpc: Allow SLPC to use efficient frequency

2022-08-15 Thread Belgaumkar, Vinay
On 8/15/2022 9:51 AM, Rodrigo Vivi wrote: On Tue, Aug 09, 2022 at 05:03:06PM -0700, Vinay Belgaumkar wrote: Host Turbo operates at efficient frequency when GT is not idle unless the user or workload has forced it to a higher level. Replicate the same behavior in SLPC by allowing the algorithm

Re: [PATCH] drm/i915/guc/slpc: Allow SLPC to use efficient frequency

2022-08-14 Thread Belgaumkar, Vinay
On 8/14/2022 4:46 PM, Vinay Belgaumkar wrote: Host Turbo operates at efficient frequency when GT is not idle unless the user or workload has forced it to a higher level. Replicate the same behavior in SLPC by allowing the algorithm to use efficient frequency. We had disabled it during boot due

Re: [PATCH] drm/i915/guc/slpc: Add a new SLPC selftest

2022-06-27 Thread Belgaumkar, Vinay
On 6/24/2022 8:59 PM, Dixit, Ashutosh wrote: On Thu, 23 Jun 2022 16:33:20 -0700, Vinay Belgaumkar wrote: +static int max_granted_freq(struct intel_guc_slpc *slpc, struct intel_rps *rps, u32 *max_act_freq) +{ + struct intel_gt *gt = rps_to_gt(rps); + u32 perf_limit_reasons; +

Re: [Intel-gfx] [PATCH] drm/i915/guc/slpc: Add a new SLPC selftest

2022-06-27 Thread Belgaumkar, Vinay
On 6/24/2022 8:59 PM, Dixit, Ashutosh wrote: On Thu, 23 Jun 2022 16:21:46 -0700, Belgaumkar, Vinay wrote: On 6/22/2022 1:32 PM, Dixit, Ashutosh wrote: On Fri, 10 Jun 2022 16:47:12 -0700, Vinay Belgaumkar wrote: This test will validate we can achieve actual frequency of RP0. Pcode grants

Re: [PATCH] drm/i915/guc/slpc: Add a new SLPC selftest

2022-06-27 Thread Belgaumkar, Vinay
On 6/24/2022 8:59 PM, Dixit, Ashutosh wrote: On Thu, 23 Jun 2022 16:33:20 -0700, Vinay Belgaumkar wrote: +static int max_granted_freq(struct intel_guc_slpc *slpc, struct intel_rps *rps, u32 *max_act_freq) +{ + struct intel_gt *gt = rps_to_gt(rps); + u32 perf_limit_reasons; +

Re: [Intel-gfx] [PATCH] drm/i915/guc/slpc: Add a new SLPC selftest

2022-06-23 Thread Belgaumkar, Vinay
On 6/22/2022 1:32 PM, Dixit, Ashutosh wrote: On Fri, 10 Jun 2022 16:47:12 -0700, Vinay Belgaumkar wrote: This test will validate we can achieve actual frequency of RP0. Pcode grants frequencies based on what GuC is requesting. However, thermal throttling can limit what is being granted. Add a

Re: [PATCH] drm/i915/guc/slpc: Use non-blocking H2G for waitboost

2022-06-22 Thread Belgaumkar, Vinay
On 6/21/2022 5:26 PM, Dixit, Ashutosh wrote: On Sat, 14 May 2022 23:05:06 -0700, Vinay Belgaumkar wrote: SLPC min/max frequency updates require H2G calls. We are seeing timeouts when GuC channel is backed up and it is unable to respond in a timely fashion causing warnings and affecting CI.

Re: [PATCH] drm/i915: Add global forcewake status to drpc

2022-06-17 Thread Belgaumkar, Vinay
On 6/17/2022 1:53 PM, Dixit, Ashutosh wrote: On Fri, 17 Jun 2022 13:25:34 -0700, Vinay Belgaumkar wrote: We have seen multiple RC6 issues where it is useful to know which global forcewake bits are set. Add this to the 'drpc' debugfs output. A couple of optional nits below to look at but

Re: [Intel-gfx] [PATCH] drm/i915/guc/slpc: Use non-blocking H2G for waitboost

2022-05-14 Thread Belgaumkar, Vinay
On 5/6/2022 9:43 AM, John Harrison wrote: On 5/6/2022 00:18, Tvrtko Ursulin wrote: On 05/05/2022 19:36, John Harrison wrote: On 5/5/2022 10:21, Belgaumkar, Vinay wrote: On 5/5/2022 5:13 AM, Tvrtko Ursulin wrote: On 05/05/2022 06:40, Vinay Belgaumkar wrote: SLPC min/max frequency updates

Re: [Intel-gfx] [PATCH] drm/i915/guc/slpc: Use non-blocking H2G for waitboost

2022-05-06 Thread Belgaumkar, Vinay
On 5/6/2022 12:18 AM, Tvrtko Ursulin wrote: On 05/05/2022 19:36, John Harrison wrote: On 5/5/2022 10:21, Belgaumkar, Vinay wrote: On 5/5/2022 5:13 AM, Tvrtko Ursulin wrote: On 05/05/2022 06:40, Vinay Belgaumkar wrote: SLPC min/max frequency updates require H2G calls. We are seeing

Re: [Intel-gfx] [PATCH] drm/i915/guc/slpc: Use non-blocking H2G for waitboost

2022-05-05 Thread Belgaumkar, Vinay
On 5/5/2022 5:13 AM, Tvrtko Ursulin wrote: On 05/05/2022 06:40, Vinay Belgaumkar wrote: SLPC min/max frequency updates require H2G calls. We are seeing timeouts when GuC channel is backed up and it is unable to respond in a timely fashion causing warnings and affecting CI. Is it the

Re: [Intel-gfx] [PATCH] drm/i915/guc/slpc: Use i915_probe_error instead of drm_err

2022-04-14 Thread Belgaumkar, Vinay
On 4/13/2022 11:41 PM, Anshuman Gupta wrote: On 2022-04-13 at 04:18:52 +0530, Vinay Belgaumkar wrote: This will ensure we don't have false positives when we run error injection tests. Signed-off-by: Vinay Belgaumkar --- drivers/gpu/drm/i915/gt/uc/intel_guc_slpc.c | 42

Re: [Intel-gfx] [PATCH] drm/i915/guc/slpc: Correct the param count for unset param

2022-02-17 Thread Belgaumkar, Vinay
On 2/17/2022 1:41 AM, Tvrtko Ursulin wrote: On 16/02/2022 18:15, Vinay Belgaumkar wrote: SLPC unset param H2G only needs one parameter - the id of the param. Fixes: 025cb07bebfa ("drm/i915/guc/slpc: Cache platform frequency limits") How serious is this? Does it need backporting? If so:

Re: [PATCH] drm/i915/guc: Update guc shim control programming on newer platforms

2022-01-25 Thread Belgaumkar, Vinay
On 1/20/2022 2:24 PM, Daniele Ceraolo Spurio wrote: Starting from xehpsdv, bit 0 of of the GuC shim control register has been repurposed, while bit 2 is now reserved, so we need to avoid setting those for their old meaning on newer platforms. Cc: Vinay Belgaumkar Cc: Stuart Summers

Re: [PATCH 3/3] drm/i915/gt: Improve "race-to-idle" at low frequencies

2021-11-23 Thread Belgaumkar, Vinay
On 11/17/2021 2:49 PM, Vinay Belgaumkar wrote: From: Chris Wilson While the power consumption is proportional to the frequency, there is also a static draw for active gates. The longer we are able to powergate (rc6), the lower the static draw. Thus there is a sweetspot in the

Re: [PATCH 2/3] drm/i915/gt: Compare average group occupancy for RPS evaluation

2021-11-23 Thread Belgaumkar, Vinay
On 11/17/2021 2:49 PM, Vinay Belgaumkar wrote: From: Chris Wilson Currently, we inspect each engine individually and measure the occupancy of that engine over the last evaluation interval. If that exceeds our busyness thresholds, we decide to increase the GPU frequency. However, under a

Re: [PATCH 1/3] drm/i915/guc/slpc: Define and initialize boost frequency

2021-11-01 Thread Belgaumkar, Vinay
On 11/1/2021 1:26 PM, Dixit, Ashutosh wrote: On Sun, 31 Oct 2021 21:39:35 -0700, Belgaumkar, Vinay wrote: Define helpers and struct members required to record boost info. Boost frequency is initialized to RP0 at SLPC init. Also define num_waiters which can track the pending boost requests

Re: [PATCH 2/3] drm/i915/guc/slpc: Add waitboost functionality for SLPC

2021-11-01 Thread Belgaumkar, Vinay
On 11/1/2021 1:28 PM, Dixit, Ashutosh wrote: On Sun, 31 Oct 2021 21:39:36 -0700, Belgaumkar, Vinay wrote: @@ -945,6 +960,17 @@ void intel_rps_boost(struct i915_request *rq) if (!test_and_set_bit(I915_FENCE_FLAG_BOOST, >fence.flags)) { struct intel_rps *rps = _ONCE

Re: [PATCH v2 0/3] drm/i915/guc/slpc: Implement waitboost for SLPC

2021-11-01 Thread Belgaumkar, Vinay
On 11/1/2021 1:24 PM, Dixit, Ashutosh wrote: On Sun, 31 Oct 2021 21:39:34 -0700, Belgaumkar, Vinay wrote: Waitboost is a legacy feature implemented in the Host Turbo algorithm. This patch set implements it for the SLPC path. A "boost" happens when user calls gem_wait ioctl on a

Re: [PATCH] drm/i915/guc/slpc: remove unneeded clflush calls

2021-09-15 Thread Belgaumkar, Vinay
On 9/14/2021 12:51 PM, Lucas De Marchi wrote: The clflush calls here aren't doing anything since we are not writting something and flushing the cache lines to be visible to GuC. Here the intention seems to be to make sure whatever GuC has written is visible to the CPU before we read them.

Re: [Intel-gfx] [PATCH 13/14] drm/i915/guc/slpc: Add SLPC selftest

2021-07-29 Thread Belgaumkar, Vinay
On 7/29/2021 4:40 PM, Matthew Brost wrote: On Wed, Jul 28, 2021 at 02:11:43PM -0700, Vinay Belgaumkar wrote: Tests that exercise the SLPC get/set frequency interfaces. Clamp_max will set max frequency to multiple levels and check that SLPC requests frequency lower than or equal to it.

Re: [Intel-gfx] [PATCH 11/14] drm/i915/guc/slpc: Cache platform frequency limits

2021-07-29 Thread Belgaumkar, Vinay
On 7/29/2021 9:21 AM, Michal Wajdeczko wrote: On 28.07.2021 23:11, Vinay Belgaumkar wrote: Cache rp0, rp1 and rpn platform limits into SLPC structure for range checking while setting min/max frequencies. Also add "soft" limits which keep track of frequency changes made from userland.

Re: [PATCH 13/15] drm/i915/guc/slpc: Sysfs hooks for SLPC

2021-07-28 Thread Belgaumkar, Vinay
On 7/27/2021 9:59 AM, Michal Wajdeczko wrote: On 26.07.2021 21:07, Vinay Belgaumkar wrote: Update the get/set min/max freq hooks to work for SLPC case as well. Consolidate helpers for requested/min/max frequency get/set to intel_rps where the proper action can be taken depending on whether

Re: [Intel-gfx] [PATCH 08/15] drm/i915/guc/slpc: Add methods to set min/max frequency

2021-07-27 Thread Belgaumkar, Vinay
On 7/27/2021 8:24 AM, Michal Wajdeczko wrote: On 26.07.2021 21:07, Vinay Belgaumkar wrote: Add param set h2g helpers to set the min and max frequencies s/h2g/H2G for use by SLPC. v2: Address review comments (Michal W) v3: Check for positive error code (Michal W) Signed-off-by:

Re: [PATCH 12/15] drm/i915/guc/slpc: Cache platform frequency limits

2021-07-27 Thread Belgaumkar, Vinay
On 7/27/2021 9:00 AM, Michal Wajdeczko wrote: On 26.07.2021 21:07, Vinay Belgaumkar wrote: Cache rp0, rp1 and rpn platform limits into SLPC structure for range checking while setting min/max frequencies. Also add "soft" limits which keep track of frequency changes made from userland.

Re: [PATCH 07/15] drm/i915/guc/slpc: Remove BUG_ON in guc_submission_disable

2021-07-27 Thread Belgaumkar, Vinay
On 7/27/2021 5:20 PM, Matthew Brost wrote: On Mon, Jul 26, 2021 at 12:07:52PM -0700, Vinay Belgaumkar wrote: The assumption when it was added was there would be no wakerefs held. However, if we fail to enable SLPC, we will still be holding a wakeref. So this is if intel_guc_slpc_enable()

Re: [PATCH 11/15] drm/i915/guc/slpc: Enable ARAT timer interrupt

2021-07-27 Thread Belgaumkar, Vinay
On 7/27/2021 8:40 AM, Matthew Brost wrote: On Mon, Jul 26, 2021 at 12:07:56PM -0700, Vinay Belgaumkar wrote: This interrupt is enabled during RPS initialization, and now needs to be done by SLPC code. It allows ARAT timer expiry interrupts to get forwarded to GuC. Signed-off-by: Vinay

Re: [PATCH 10/15] drm/i915/guc/slpc: Add debugfs for SLPC info

2021-07-27 Thread Belgaumkar, Vinay
On 7/27/2021 8:37 AM, Michal Wajdeczko wrote: On 26.07.2021 21:07, Vinay Belgaumkar wrote: This prints out relevant SLPC info from the SLPC shared structure. We will send a h2g message which forces SLPC to update the s/h2g/H2G ok. shared data structure with latest information

Re: [Intel-gfx] [PATCH 09/15] drm/i915/guc/slpc: Add get max/min freq hooks

2021-07-27 Thread Belgaumkar, Vinay
On 7/27/2021 8:32 AM, Michal Wajdeczko wrote: On 26.07.2021 21:07, Vinay Belgaumkar wrote: Add helpers to read the min/max frequency being used by SLPC. This is done by send a H2G command which forces SLPC to update the shared data struct which can then be read. These helpers will be used

Re: [PATCH 03/15] drm/i915/guc/slpc: Gate Host RPS when SLPC is enabled

2021-07-27 Thread Belgaumkar, Vinay
On 7/27/2021 3:44 PM, Matthew Brost wrote: On Mon, Jul 26, 2021 at 12:07:48PM -0700, Vinay Belgaumkar wrote: Also ensure uc_init is called before we initialize RPS so that we can check for SLPC support. We do not need to enable up/down interrupts when SLPC is enabled. However, we still need

Re: [Intel-gfx] [PATCH 08/15] drm/i915/guc/slpc: Add methods to set min/max frequency

2021-07-27 Thread Belgaumkar, Vinay
On 7/27/2021 8:24 AM, Michal Wajdeczko wrote: On 26.07.2021 21:07, Vinay Belgaumkar wrote: Add param set h2g helpers to set the min and max frequencies s/h2g/H2G for use by SLPC. v2: Address review comments (Michal W) v3: Check for positive error code (Michal W) Signed-off-by:

Re: [PATCH 14/15] drm/i915/guc/slpc: Add SLPC selftest

2021-07-27 Thread Belgaumkar, Vinay
On 7/27/2021 12:16 PM, Matthew Brost wrote: On Mon, Jul 26, 2021 at 12:07:59PM -0700, Vinay Belgaumkar wrote: Tests that exercise the SLPC get/set frequency interfaces. Clamp_max will set max frequency to multiple levels and check that SLPC requests frequency lower than or equal to it.

Re: [Intel-gfx] [PATCH 06/15] drm/i915/guc/slpc: Enable SLPC and add related H2G events

2021-07-27 Thread Belgaumkar, Vinay
On 7/27/2021 1:19 PM, Michal Wajdeczko wrote: On 27.07.2021 22:00, Belgaumkar, Vinay wrote: On 7/27/2021 8:12 AM, Michal Wajdeczko wrote: On 26.07.2021 21:07, Vinay Belgaumkar wrote: Add methods for interacting with GuC for enabling SLPC. Enable SLPC after GuC submission has been

Re: [Intel-gfx] [PATCH 06/15] drm/i915/guc/slpc: Enable SLPC and add related H2G events

2021-07-27 Thread Belgaumkar, Vinay
On 7/27/2021 8:12 AM, Michal Wajdeczko wrote: On 26.07.2021 21:07, Vinay Belgaumkar wrote: Add methods for interacting with GuC for enabling SLPC. Enable SLPC after GuC submission has been established. GuC load will fail if SLPC cannot be successfully initialized. Add various helper

Re: [PATCH 04/15] drm/i915/guc/slpc: Adding SLPC communication interfaces

2021-07-27 Thread Belgaumkar, Vinay
On 7/27/2021 6:59 AM, Michal Wajdeczko wrote: On 26.07.2021 21:07, Vinay Belgaumkar wrote: Add constants and params that are needed to configure SLPC. v2: Add a new abi header for SLPC. Replace bitfields with genmasks. Address other comments from Michal W. v3: Add slpc H2G format in abi,

Re: [PATCH 02/15] drm/i915/guc/slpc: Initial definitions for SLPC

2021-07-27 Thread Belgaumkar, Vinay
On 7/27/2021 6:43 AM, Michal Wajdeczko wrote: On 26.07.2021 21:07, Vinay Belgaumkar wrote: Add macros to check for SLPC support. This feature is currently supported for Gen12+ and enabled whenever GuC submission is enabled/selected. Include templates for SLPC init/fini and enable. v2:

Re: [PATCH 15/15] drm/i915/guc/rc: Setup and enable GUCRC feature

2021-07-27 Thread Belgaumkar, Vinay
On 7/27/2021 8:37 AM, Matt Roper wrote: On Mon, Jul 26, 2021 at 12:08:00PM -0700, Vinay Belgaumkar wrote: This feature hands over the control of HW RC6 to the GuC. GuC decides when to put HW into RC6 based on it's internal busyness algorithms. GUCRC needs GuC submission to be enabled, and

Re: [PATCH 14/14] drm/i915/guc/rc: Setup and enable GUCRC feature

2021-07-23 Thread Belgaumkar, Vinay
On 7/21/2021 11:21 AM, Michal Wajdeczko wrote: On 21.07.2021 18:11, Vinay Belgaumkar wrote: This feature hands over the control of HW RC6 to the GuC. GuC decides when to put HW into RC6 based on it's internal busyness algorithms. GUCRC needs GuC submission to be enabled, and only

Re: [PATCH 12/14] drm/i915/guc/slpc: Sysfs hooks for SLPC

2021-07-23 Thread Belgaumkar, Vinay
On 7/21/2021 11:13 AM, Michal Wajdeczko wrote: On 21.07.2021 18:11, Vinay Belgaumkar wrote: Update the get/set min/max freq hooks to work for SLPC case as well. Consolidate helpers for requested/min/max frequency get/set to intel_rps where the proper action can be taken depending on

Re: [PATCH 11/14] drm/i915/guc/slpc: Cache platform frequency limits

2021-07-23 Thread Belgaumkar, Vinay
On 7/21/2021 11:09 AM, Michal Wajdeczko wrote: On 21.07.2021 18:11, Vinay Belgaumkar wrote: Cache rp0, rp1 and rpn platform limits into SLPC structure for range checking while setting min/max frequencies. Also add "soft" limits which keep track of frequency changes made from userland.

Re: [PATCH 09/14] drm/i915/guc/slpc: Add debugfs for SLPC info

2021-07-23 Thread Belgaumkar, Vinay
On 7/21/2021 11:05 AM, Michal Wajdeczko wrote: On 21.07.2021 18:11, Vinay Belgaumkar wrote: This prints out relevant SLPC info from the SLPC shared structure. We will send a h2g message which forces SLPC to update the shared data structure with latest information before reading it. v2:

Re: [PATCH 08/14] drm/i915/guc/slpc: Add get max/min freq hooks

2021-07-23 Thread Belgaumkar, Vinay
On 7/21/2021 11:00 AM, Michal Wajdeczko wrote: On 21.07.2021 18:11, Vinay Belgaumkar wrote: Add helpers to read the min/max frequency being used by SLPC. This is done by send a H2G command which forces SLPC to update the shared data struct which can then be read. add note that functions

Re: [PATCH 07/14] drm/i915/guc/slpc: Add methods to set min/max frequency

2021-07-23 Thread Belgaumkar, Vinay
On 7/21/2021 10:42 AM, Michal Wajdeczko wrote: On 21.07.2021 18:11, Vinay Belgaumkar wrote: Add param set h2g helpers to set the min and max frequencies for use by SLPC. v2: Address review comments (Michal W) Signed-off-by: Sundaresan Sujaritha Signed-off-by: Vinay Belgaumkar ---

Re: [Intel-gfx] [PATCH 05/14] drm/i915/guc/slpc: Allocate, initialize and release SLPC

2021-07-23 Thread Belgaumkar, Vinay
On 7/21/2021 10:26 AM, Michal Wajdeczko wrote: On 21.07.2021 18:11, Vinay Belgaumkar wrote: Allocate data structures for SLPC and functions for initializing on host side. v2: Address review comments (Michal W) Signed-off-by: Vinay Belgaumkar Signed-off-by: Sundaresan Sujaritha ---

Re: [PATCH 06/14] drm/i915/guc/slpc: Enable SLPC and add related H2G events

2021-07-23 Thread Belgaumkar, Vinay
On 7/21/2021 10:38 AM, Michal Wajdeczko wrote: On 21.07.2021 18:11, Vinay Belgaumkar wrote: Add methods for interacting with GuC for enabling SLPC. Enable SLPC after GuC submission has been established. GuC load will fail if SLPC cannot be successfully initialized. Add various helper

Re: [PATCH 04/14] drm/i915/guc/slpc: Adding SLPC communication interfaces

2021-07-23 Thread Belgaumkar, Vinay
On 7/21/2021 10:25 AM, Michal Wajdeczko wrote: On 21.07.2021 18:11, Vinay Belgaumkar wrote: Add constants and params that are needed to configure SLPC. v2: Add a new abi header for SLPC. Replace bitfields with genmasks. Address other comments from Michal W. Signed-off-by: Vinay

Re: [PATCH 02/14] drm/i915/guc/slpc: Initial definitions for SLPC

2021-07-21 Thread Belgaumkar, Vinay
On 7/21/2021 10:24 AM, Michal Wajdeczko wrote: On 21.07.2021 18:11, Vinay Belgaumkar wrote: Add macros to check for SLPC support. This feature is currently supported for Gen12+ and enabled whenever GuC submission is enabled/selected. Include templates for SLPC init/fini and enable. v2:

Re: [Intel-gfx] [PATCH 16/16] drm/i915/guc/rc: Setup and enable GUCRC feature

2021-07-20 Thread Belgaumkar, Vinay
On 7/10/2021 11:41 AM, Michal Wajdeczko wrote: On 10.07.2021 03:20, Vinay Belgaumkar wrote: This feature hands over the control of HW RC6 to the GUC. GUC decides when to put HW into RC6 based on it's internal busyness algorithms. GUCRC needs GUC submission to be enabled, and only

  1   2   >