Igt-dev Archive on lore.kernel.org
 help / color / mirror / Atom feed
From: Michal Wajdeczko <michal.wajdeczko@intel.com>
To: Francois Dugast <francois.dugast@intel.com>,
	Satyanarayana K V P <satyanarayana.k.v.p@intel.com>
Cc: igt-dev@lists.freedesktop.org
Subject: Re: [PATCH i-g-t 4/4] tests/intel/xe_fault_injection: Inject errors during xe_guc_ct_send_recv & xe_guc_mmio_send_recv.
Date: Tue, 18 Feb 2025 15:06:27 +0100	[thread overview]
Message-ID: <d1ee88cd-bcbe-4840-9e0a-4d9c71b8fe1e@intel.com> (raw)
In-Reply-To: <Z7SPn9Kstq7TKErm@fdugast-desk>



On 18.02.2025 14:48, Francois Dugast wrote:
> On Fri, Feb 07, 2025 at 12:59:02PM +0530, Satyanarayana K V P wrote:

>> +
>> +	/* Get the iteration count from environment */
>> +	iter = get_fault_inject_iter();
>> +	iter_start = iter ? : 0;
>> +	iter_end = iter ? iter + 1 : INJECT_ITERATIONS;
>> +	for (int i = iter_start; i < iter_end; i++) {
>> +		fault_params->space = i;
>> +		setup_injection_fault(fault_params);
>> +		inject_fault_probe(fd, pci_slot, function_name);
>> +	}
> 
> This loop is specific to the guc test, it is not present for other tests.
> What is different about this test, why do we need to inject a fault at a
> given iteration?
> 
> In case IGT_FAULT_INJECT_ITERATION is not set, why running
> inject_fault_probe() 100 times instead of just once like with existing
> tests during probe?
> 

Because all xe_init() kind of functions are called just once during
driver probe, so it is sufficient to fail first/all calls to them.

OTOH driver communicates with the GuC multiple times, and the real
failure can happen at different call, hence the need to inject failure
in GuC communication functions, like guc_mmio_send() or guc_ct_send(),
but it can't be just first call or all calls, but we need to be able to
select specific iteration to fail.

Only with that approach we can provide sufficient coverage of the driver
probe related to GuC.

Michal

  reply	other threads:[~2025-02-18 14:06 UTC|newest]

Thread overview: 15+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2025-02-07  7:28 [PATCH i-g-t 0/4] tests/intel/xe_fault_injection: Inject errors during xe_guc_ct_send_recv() xe_guc_mmio_send_recv() Satyanarayana K V P
2025-02-07  7:28 ` [PATCH i-g-t 1/4] lib/igt_sysfs: Add support for device unbinding Satyanarayana K V P
2025-02-18 12:19   ` Francois Dugast
2025-02-07  7:29 ` [PATCH i-g-t 2/4] tests/intel/xe_fault_injection: Make setup_injection_fault() programmable Satyanarayana K V P
2025-02-18 12:46   ` Francois Dugast
2025-02-07  7:29 ` [PATCH i-g-t 3/4] tests/intel/xe_fault_injection: Add helper functions to inject fault with specific budget parameter Satyanarayana K V P
2025-02-18 13:04   ` Francois Dugast
2025-02-07  7:29 ` [PATCH i-g-t 4/4] tests/intel/xe_fault_injection: Inject errors during xe_guc_ct_send_recv & xe_guc_mmio_send_recv Satyanarayana K V P
2025-02-18 13:48   ` Francois Dugast
2025-02-18 14:06     ` Michal Wajdeczko [this message]
2025-02-18 16:40       ` Francois Dugast
2025-02-08  0:01 ` ✓ i915.CI.BAT: success for tests/intel/xe_fault_injection: Inject errors during xe_guc_ct_send_recv() xe_guc_mmio_send_recv() Patchwork
2025-02-08  0:42 ` ✓ Xe.CI.BAT: " Patchwork
2025-02-08 15:59 ` ✗ i915.CI.Full: failure " Patchwork
2025-02-08 17:21 ` ✗ Xe.CI.Full: " Patchwork

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=d1ee88cd-bcbe-4840-9e0a-4d9c71b8fe1e@intel.com \
    --to=michal.wajdeczko@intel.com \
    --cc=francois.dugast@intel.com \
    --cc=igt-dev@lists.freedesktop.org \
    --cc=satyanarayana.k.v.p@intel.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox