Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > linux.kernel > #1539682

Re: [RFC PATCH 0/3] staging: remove fbdev drivers

From Benjamin Herrenschmidt <benh@kernel.crashing.org>
Newsgroups linux.kernel
Subject Re: [RFC PATCH 0/3] staging: remove fbdev drivers
Date 2016-12-09 22:20 +0100
Message-ID <sMAKe-8id-27@gated-at.bofh.it> (permalink)
References (6 earlier) <sMeTo-30n-17@gated-at.bofh.it> <sMoSJ-Zv-1@gated-at.bofh.it> <sMp2p-12O-3@gated-at.bofh.it> <sMrQC-2JA-9@gated-at.bofh.it> <sMtz4-3Rh-7@gated-at.bofh.it>
Organization linux.* mail to news gateway

Show all headers | View raw


On Fri, 2016-12-09 at 14:35 +0100, Daniel Vetter wrote:
> > As for multi userspace client, well, swapping an mmap between HW and
> > memory backing store is a somewhat solved problem already.
> 
> Hm, I didn't know that, but then all existing drm drivers have fairly
> simplistic fbdev mmap implementations.

Hrm, I though the TTM did it ... I remember talking with Thomas
Hellstrom about that back in the day... you use unmap_mapping_range
to unmap the existing mappings basically so you can take new faults
and route them to a different page, but I can't see a call in there
so maybe he ended up not doing it.

We used to do that on Cell to "context switch" the local memory of
the SPU engines between the real SPU and the backing store. It's not
very hard to do.
 
The main issue is that the mapping attributes change between cached
and non-cached under the hood, so users have to be careful not to do
things like use instructions that only work on one type of mapping
(or do things like misaligned accesses).

> > > whereas drm has a multi-master model and proper isolation. IIrc we've hacked up
> > > something once, and if there's indeed more interest into vram dumb buffer
> > > drivers I'm pretty sure we can grow some nice ttm fb helpers (like the cma
> > > fb helpers we have) to make it all pretty and nice and fast and
> > > essentially plug-in-and-forget from a driver authors pov.
> > 
> > That would be nice. I don't have the bandwidth to swap-in enough
> > understanding of TTM guts right now but I might look into it some time next 
> > year if nobody beats me to it.
> 
> Probably best would be to first extract some helpers for ttm based vram
> dumb buffer management, and then start to implement some of the
> improvements so that all drivers can benefit. Like you've said it's not
> rocket science, it just needs to be done ;-)

Right :-)

Though getting ones head around the infrastructure in the DRM does take
time :-) There's a lot of stuff in there, between TTM, GEM etc... and
not all of it completely "obvious" ...

Cheers,
Ben.

> -Daniel
> -- 

Back to linux.kernel | Previous | NextPrevious in thread | Next in thread | Find similar | Unroll thread


Thread

Re: [RFC PATCH 0/3] staging: remove fbdev drivers Benjamin Herrenschmidt <benh@kernel.crashing.org> - 2016-12-08 02:10 +0100
  Re: [RFC PATCH 0/3] staging: remove fbdev drivers Tomi Valkeinen <tomi.valkeinen@ti.com> - 2016-12-08 09:10 +0100
    Re: [RFC PATCH 0/3] staging: remove fbdev drivers Benjamin Herrenschmidt <benh@kernel.crashing.org> - 2016-12-08 22:30 +0100
      Re: [RFC PATCH 0/3] staging: remove fbdev drivers Benjamin Herrenschmidt <benh@kernel.crashing.org> - 2016-12-08 22:50 +0100
        Re: [RFC PATCH 0/3] staging: remove fbdev drivers Daniel Vetter <daniel@ffwll.ch> - 2016-12-09 09:20 +0100
      Re: [RFC PATCH 0/3] staging: remove fbdev drivers Gerd Hoffmann <kraxel@redhat.com> - 2016-12-13 10:00 +0100
  Re: [RFC PATCH 0/3] staging: remove fbdev drivers Daniel Vetter <daniel@ffwll.ch> - 2016-12-08 11:20 +0100
    Re: [RFC PATCH 0/3] staging: remove fbdev drivers Geert Uytterhoeven <geert@linux-m68k.org> - 2016-12-08 13:20 +0100
      Re: [RFC PATCH 0/3] staging: remove fbdev drivers Daniel Vetter <daniel@ffwll.ch> - 2016-12-08 15:20 +0100
        Re: [RFC PATCH 0/3] staging: remove fbdev drivers Geert Uytterhoeven <geert@linux-m68k.org> - 2016-12-08 15:30 +0100
          Re: [RFC PATCH 0/3] staging: remove fbdev drivers Thomas Petazzoni <thomas.petazzoni@free-electrons.com> - 2016-12-08 15:40 +0100
            Re: [RFC PATCH 0/3] staging: remove fbdev drivers Geert Uytterhoeven <geert@linux-m68k.org> - 2016-12-08 15:50 +0100
              Re: [RFC PATCH 0/3] staging: remove fbdev drivers Daniel Vetter <daniel@ffwll.ch> - 2016-12-08 16:30 +0100
                Re: [RFC PATCH 0/3] staging: remove fbdev drivers Benjamin Herrenschmidt <benh@kernel.crashing.org> - 2016-12-08 22:40 +0100
                Re: [RFC PATCH 0/3] staging: remove fbdev drivers Benjamin Herrenschmidt <benh@kernel.crashing.org> - 2016-12-08 23:00 +0100
                Re: [RFC PATCH 0/3] staging: remove fbdev drivers Daniel Vetter <daniel@ffwll.ch> - 2016-12-09 09:40 +0100
                Re: [RFC PATCH 0/3] staging: remove fbdev drivers Daniel Vetter <daniel@ffwll.ch> - 2016-12-09 09:50 +0100
                Re: [RFC PATCH 0/3] staging: remove fbdev drivers Benjamin Herrenschmidt <benh@kernel.crashing.org> - 2016-12-09 12:50 +0100
                Re: [RFC PATCH 0/3] staging: remove fbdev drivers Daniel Vetter <daniel@ffwll.ch> - 2016-12-09 14:40 +0100
                Re: [RFC PATCH 0/3] staging: remove fbdev drivers Benjamin Herrenschmidt <benh@kernel.crashing.org> - 2016-12-09 22:20 +0100
                Re: [RFC PATCH 0/3] staging: remove fbdev drivers Michel Dänzer <michel@daenzer.net> - 2016-12-13 08:20 +0100
                Re: [RFC PATCH 0/3] staging: remove fbdev drivers Benjamin Herrenschmidt <benh@kernel.crashing.org> - 2016-12-09 12:50 +0100
                Re: [RFC PATCH 0/3] staging: remove fbdev drivers Geert Uytterhoeven <geert@linux-m68k.org> - 2016-12-09 13:40 +0100
                Re: [RFC PATCH 0/3] staging: remove fbdev drivers Lucas Stach <l.stach@pengutronix.de> - 2016-12-09 14:20 +0100
                Re: [RFC PATCH 0/3] staging: remove fbdev drivers Daniel Vetter <daniel@ffwll.ch> - 2016-12-09 14:40 +0100
                Re: [RFC PATCH 0/3] staging: remove fbdev drivers David Herrmann <dh.herrmann@gmail.com> - 2016-12-09 15:00 +0100
                Re: [RFC PATCH 0/3] staging: remove fbdev drivers Daniel Vetter <daniel@ffwll.ch> - 2016-12-09 15:10 +0100
                Re: [RFC PATCH 0/3] staging: remove fbdev drivers Benjamin Herrenschmidt <benh@kernel.crashing.org> - 2016-12-09 21:40 +0100
                Re: [RFC PATCH 0/3] staging: remove fbdev drivers Daniel Vetter <daniel@ffwll.ch> - 2016-12-09 09:40 +0100
          Re: [RFC PATCH 0/3] staging: remove fbdev drivers Jani Nikula <jani.nikula@linux.intel.com> - 2016-12-08 16:10 +0100
        Re: [RFC PATCH 0/3] staging: remove fbdev drivers Daniel Vetter <daniel@ffwll.ch> - 2016-12-08 15:30 +0100
    Re: [RFC PATCH 0/3] staging: remove fbdev drivers Benjamin Herrenschmidt <benh@kernel.crashing.org> - 2016-12-08 23:40 +0100
      Re: [RFC PATCH 0/3] staging: remove fbdev drivers Dave Airlie <airlied@gmail.com> - 2016-12-09 01:10 +0100
        Re: [RFC PATCH 0/3] staging: remove fbdev drivers Geert Uytterhoeven <geert@linux-m68k.org> - 2016-12-09 09:10 +0100
        Re: [RFC PATCH 0/3] staging: remove fbdev drivers Benjamin Herrenschmidt <benh@kernel.crashing.org> - 2016-12-09 12:50 +0100
        Re: [RFC PATCH 0/3] staging: remove fbdev drivers Gerd Hoffmann <kraxel@redhat.com> - 2016-12-13 09:50 +0100
    Re: [RFC PATCH 0/3] staging: remove fbdev drivers Laurent Pinchart <laurent.pinchart@ideasonboard.com> - 2016-12-13 16:20 +0100

csiph-web