Igt-dev Archive on lore.kernel.org
 help / color / mirror / Atom feed
From: "Dixit, Ashutosh" <ashutosh.dixit@intel.com>
To: Petri Latvala <petri.latvala@intel.com>
Cc: igt-dev@lists.freedesktop.org, hariom.pandey@intel.com
Subject: Re: [igt-dev] [PATCH] [i-g-t] tests/i915: Remove I915_CACHING_NONE
Date: Mon, 17 May 2021 11:34:26 -0700	[thread overview]
Message-ID: <8735ulryz1.wl-ashutosh.dixit@intel.com> (raw)
In-Reply-To: <YKIzQtcWRBBqOqva@platvala-desk.ger.corp.intel.com>

On Mon, 17 May 2021 02:11:30 -0700, Petri Latvala wrote:
>
> On Wed, May 12, 2021 at 06:46:30PM -0700, Dixit, Ashutosh wrote:
> > On Sun, 18 Apr 2021 23:42:54 -0700, Dixit, Ashutosh wrote:
> > >
> > > On Sun, 18 Apr 2021 23:09:28 -0700, <viswax.krishna.raveendra.talabattula@intel.com> wrote:
> > > >
> > > > From: Viswa Krishna Raveendra Talabattula <viswax.krishna.raveendra.talabattula@intel.com>
> > > >
> > > > The userptr memory does not support I915_CACHING_NONE(no caching) level
> > > > as per the below commit related to i915 in the kernel
> > > >
> > > > drm/i915: Reject more ioctls for userptr, v2.
> > > >
> > > > Hence removing the cache level of I915_CACHING_NONE from the test case
> > >
> > > Instead of dropping the test should we check for -ENXIO return?
> >
> > Because setting I915_CACHING_NONE on a userptr is not an unreasonable
> > operation, if it is not supported IMO IGT should check for an -ENXIO return
> > if someone tries to set I915_CACHING_NONE.
> >
> > The only complication here is that this is a ABI change. So if IGT runs on
> > an older kernel set_caching() will return 0 whereas it will return -ENXIO
> > with a new kernel. There seems to be no way of determining a priori what
> > the expected return is.
> >
> > I am copying Petri too. Checking for both 0 and -ENXIO would sort of defeat
> > the purpose. Also, having the IGT fail on older kernels is also probably
> > unacceptable.
>
> There is some value in making sure the operation doesn't fail with
> something funky like ECONNREFUSED. How much value, that depends, up to
> you.
>
> Is it an option to have this mapping:
>
> ENXIO - pass
> 0 - warn, with something like "kernel behaves in a deprecated way"
> anything else - fail

Thanks, I think that's a good idea. So for now let's have the test pass on
both -ENXIO and 0 return code, but if the return code is 0 let's do an
igt_warn("Deprecated return code 0 from __gem_set_caching").
_______________________________________________
igt-dev mailing list
igt-dev@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/igt-dev

  reply	other threads:[~2021-05-17 18:34 UTC|newest]

Thread overview: 8+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2021-04-19  6:09 [igt-dev] [PATCH] [i-g-t] tests/i915: Remove I915_CACHING_NONE viswax.krishna.raveendra.talabattula
2021-04-19  6:35 ` [igt-dev] ✓ Fi.CI.BAT: success for " Patchwork
2021-04-19  6:42 ` [igt-dev] [PATCH] [i-g-t] " Dixit, Ashutosh
2021-04-19  7:10   ` Surendrakumar Upadhyay, TejaskumarX
2021-05-13  1:46   ` Dixit, Ashutosh
2021-05-17  9:11     ` Petri Latvala
2021-05-17 18:34       ` Dixit, Ashutosh [this message]
2021-04-19  7:34 ` [igt-dev] ✓ Fi.CI.IGT: success for " 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=8735ulryz1.wl-ashutosh.dixit@intel.com \
    --to=ashutosh.dixit@intel.com \
    --cc=hariom.pandey@intel.com \
    --cc=igt-dev@lists.freedesktop.org \
    --cc=petri.latvala@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