From: "Souza, Jose" <jose.souza@intel.com>
To: "jason@jlekstrand.net" <jason@jlekstrand.net>,
"daniel.vetter@ffwll.ch" <daniel.vetter@ffwll.ch>
Cc: "Vetter, Daniel" <daniel.vetter@intel.com>,
"kenneth@whitecape.org" <kenneth@whitecape.org>,
"De Marchi, Lucas" <lucas.demarchi@intel.com>,
"intel-gfx@lists.freedesktop.org"
<intel-gfx@lists.freedesktop.org>,
"Auld, Matthew" <matthew.auld@intel.com>
Subject: Re: [PATCH] drm/i915: disable set/get_tiling ioctl on gen12+
Date: Wed, 28 Aug 2019 20:11:53 +0000 [thread overview]
Message-ID: <e01a7b6890346444f3fa3f78cca1a2315412a37a.camel@intel.com> (raw)
In-Reply-To: <CAOFGe97==LTH0pUh2idtA0SqQLf=+Tq90h0cBVwhv4gkHLq-7Q@mail.gmail.com>
Reviewed-by: José Roberto de Souza <jose.souza@intel.com>
Pushing this one in a few minutes.
On Thu, 2019-08-22 at 14:25 -0500, Jason Ekstrand wrote:
> Acked-by: Jason Ekstrand <jason@jlekstrand.net>
>
> On Wed, Aug 21, 2019 at 10:20 AM Daniel Vetter <
> daniel.vetter@ffwll.ch> wrote:
> > On Wed, Aug 21, 2019 at 3:55 PM Ville Syrjälä
> > <ville.syrjala@linux.intel.com> wrote:
> > >
> > > On Tue, Aug 20, 2019 at 01:57:44PM -0700, Daniele Ceraolo Spurio
> > wrote:
> > > >
> > > >
> > > > On 8/20/19 12:54 PM, Daniel Vetter wrote:
> > > > > The cpu (de)tiler hw is gone, this stopped being useful. Plus
> > it never
> > > > > supported any of the fancy new tiling formats, which means
> > userspace
> > > > > also stopped using the magic side-channel this provides.
> > > > >
> > > > > This would totally break a lot of the igts, but they're
> > already broken
> > > > > for the same reasons as userspace on gen12 would be.
> > > > >
> > > > > v2: Look at ggtt->num_fences instead, that also avoids the
> > need for a
> > > > > comment (Chris). This also means that gen12 support really
> > needs to
> > > > > make sure num_fences is set to 0. There is a patch for that,
> > but it
> > > > > checks for HAS_MAPPABLE_APERTURE, which I'm not sure is the
> > right
> > > > > thing really. Adding relevant people.
> > > > >
> > > >
> > > > We'd obviously need to make that setting for all gen12+,
> > because TGL
> > > > does have mappable aperture.
> > > >
> > > > Apart from the tiling ioctl, the only place I see where we set
> > tiling is
> > > > intel_alloc_initial_plane_obj(), can the users of that object
> > handle the
> > > > lack of fences gracefully?
> > >
> > > Gen4+ display engine has its own tiling controls and doesn't care
> > about
> > > fences. So we should be able to leave the obj tiling set to NONE.
> > >
> > > Hmm. Actually I think we should reject tiled framebuffers in the
> > BIOS
> > > fb takeover because fbdev needs a linear view for the memory. No
> > can
> > > do without the fence.
> >
> > Yeah I think this is just more fallout from "no more fences in the
> > hw".
> > -Daniel
> >
> > >
> > > > When I wrote the num_fences=0 patch I was
> > > > expecting display to be unavailable, so I didn't really look at
> > that
> > > > part of the code.
> > > >
> > > > It'd also be nice to be more explicit with fencing since we
> > seem to
> > > > often call i915_vma_pin_iomap, which implicitly applies a fence
> > if
> > > > needed, on objects that can't be tiled or have had a fence
> > assigned a
> > > > few lines before. This is more a nice to have tough, possibly
> > together
> > > > with a split of the "mappable" and "fenceable" attributes of
> > the vma.
> > > >
> > > > Daniele
> > > >
> > > > > Cc: Daniele Ceraolo Spurio <daniele.ceraolospurio@intel.com>
> > > > > Cc: Stuart Summers <stuart.summers@intel.com>
> > > > > Cc: Matthew Auld <matthew.auld@intel.com>
> > > > > Cc: Kenneth Graunke <kenneth@whitecape.org>
> > > > > Cc: Jason Ekstrand <jason@jlekstrand.net>
> > > > > Cc: Chris Wilson <chris@chris-wilson.co.uk>
> > > > > Cc: Lucas De Marchi <lucas.demarchi@intel.com>
> > > > > Signed-off-by: Daniel Vetter <daniel.vetter@intel.com>
> > > > > ---
> > > > > drivers/gpu/drm/i915/gem/i915_gem_tiling.c | 7 +++++++
> > > > > 1 file changed, 7 insertions(+)
> > > > >
> > > > > diff --git a/drivers/gpu/drm/i915/gem/i915_gem_tiling.c
> > b/drivers/gpu/drm/i915/gem/i915_gem_tiling.c
> > > > > index ca0c2f451742..e5d1ae8d4dba 100644
> > > > > --- a/drivers/gpu/drm/i915/gem/i915_gem_tiling.c
> > > > > +++ b/drivers/gpu/drm/i915/gem/i915_gem_tiling.c
> > > > > @@ -313,10 +313,14 @@ int
> > > > > i915_gem_set_tiling_ioctl(struct drm_device *dev, void
> > *data,
> > > > > struct drm_file *file)
> > > > > {
> > > > > + struct drm_i915_private *dev_priv = to_i915(dev);
> > > > > struct drm_i915_gem_set_tiling *args = data;
> > > > > struct drm_i915_gem_object *obj;
> > > > > int err;
> > > > >
> > > > > + if (!dev_priv->ggtt.num_fences)
> > > > > + return -EOPNOTSUPP;
> > > > > +
> > > > > obj = i915_gem_object_lookup(file, args->handle);
> > > > > if (!obj)
> > > > > return -ENOENT;
> > > > > @@ -402,6 +406,9 @@ i915_gem_get_tiling_ioctl(struct
> > drm_device *dev, void *data,
> > > > > struct drm_i915_gem_object *obj;
> > > > > int err = -ENOENT;
> > > > >
> > > > > + if (!dev_priv->ggtt.num_fences)
> > > > > + return -EOPNOTSUPP;
> > > > > +
> > > > > rcu_read_lock();
> > > > > obj = i915_gem_object_lookup_rcu(file, args->handle);
> > > > > if (obj) {
> > > > >
> > > > _______________________________________________
> > > > Intel-gfx mailing list
> > > > Intel-gfx@lists.freedesktop.org
> > > > https://lists.freedesktop.org/mailman/listinfo/intel-gfx
> > >
> > > --
> > > Ville Syrjälä
> > > Intel
> >
> >
> >
> > _______________________________________________
> > Intel-gfx mailing list
> > Intel-gfx@lists.freedesktop.org
> > https://lists.freedesktop.org/mailman/listinfo/intel-gfx
_______________________________________________
Intel-gfx mailing list
Intel-gfx@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/intel-gfx
next prev parent reply other threads:[~2019-08-28 20:11 UTC|newest]
Thread overview: 31+ messages / expand[flat|nested] mbox.gz Atom feed top
2019-08-20 17:06 [PATCH] drm/i915: disable set/get_tiling ioctl on gen12+ Daniel Vetter
2019-08-20 18:55 ` Chris Wilson
2019-08-20 19:06 ` Daniel Vetter
2019-08-20 19:25 ` Chris Wilson
2019-08-20 19:25 ` ✗ Fi.CI.CHECKPATCH: warning for " Patchwork
2019-08-20 19:46 ` ✗ Fi.CI.BAT: failure " Patchwork
2019-08-20 19:54 ` [PATCH] " Daniel Vetter
2019-08-20 20:57 ` Daniele Ceraolo Spurio
2019-08-21 13:55 ` Ville Syrjälä
2019-08-21 15:20 ` Daniel Vetter
2019-08-22 19:25 ` Jason Ekstrand
2019-08-28 20:11 ` Souza, Jose [this message]
2019-08-28 20:13 ` Chris Wilson
2019-08-28 20:31 ` Souza, Jose
2019-08-29 6:50 ` Daniel Vetter
2019-09-03 19:21 ` Souza, Jose
2019-09-04 14:29 ` Daniel Vetter
2019-09-04 14:31 ` Daniel Vetter
2019-09-04 19:05 ` Souza, Jose
2019-11-07 23:07 ` Brian Welty
2019-11-07 23:07 ` [Intel-gfx] " Brian Welty
2019-11-08 17:35 ` Daniel Vetter
2019-11-08 17:35 ` [Intel-gfx] " Daniel Vetter
2019-09-19 20:57 ` Daniele Ceraolo Spurio
2019-08-20 20:46 ` ✗ Fi.CI.CHECKPATCH: warning for drm/i915: disable set/get_tiling ioctl on gen12+ (rev2) Patchwork
2019-08-20 21:16 ` ✓ Fi.CI.BAT: success " Patchwork
2019-08-21 12:19 ` ✗ Fi.CI.IGT: failure " Patchwork
2019-08-29 14:18 ` ✓ Fi.CI.IGT: success " Patchwork
2019-09-04 19:56 ` Souza, Jose
2019-10-30 19:30 ` [PATCH] drm/i915: disable set/get_tiling ioctl on gen12+ Jason Ekstrand
2019-10-30 19:30 ` [Intel-gfx] " Jason Ekstrand
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=e01a7b6890346444f3fa3f78cca1a2315412a37a.camel@intel.com \
--to=jose.souza@intel.com \
--cc=daniel.vetter@ffwll.ch \
--cc=daniel.vetter@intel.com \
--cc=intel-gfx@lists.freedesktop.org \
--cc=jason@jlekstrand.net \
--cc=kenneth@whitecape.org \
--cc=lucas.demarchi@intel.com \
--cc=matthew.auld@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