From: Daniel Vetter <daniel@ffwll.ch>
To: "Noralf Trønnes" <noralf@tronnes.org>
Cc: sam@ravnborg.org, david@lechnology.com, dri-devel@lists.freedesktop.org
Subject: Re: [PATCH v4 0/4] drm: Add shmem GEM library
Date: Mon, 1 Oct 2018 09:48:08 +0200 [thread overview]
Message-ID: <20181001074808.GP11082@phenom.ffwll.local> (raw)
In-Reply-To: <20180926145933.22034-1-noralf@tronnes.org>
On Wed, Sep 26, 2018 at 04:59:29PM +0200, Noralf Trønnes wrote:
> This patchset adds a library for shmem backed GEM objects and makes use
> of it in tinydrm.
>
> Thomas gave me some feedback that made me realise that the cachemodes
> pattern I had picked up from some other drivers didn't apply to shmem
> buffers in the way I though it did. So it's removed.
>
> I recently did an RFC to see if it made sense to add a vtable to GEM
> objects. Daniel welcomed that so I've included it here.
I like this. Made some tiny comments, but proof's in the pudding so I'll
leave review to someone who knows tinydrm better. Or other driver
maintainers, if you extend the scope a bit. From a high level I think it's
ready, looks all reasonable (except maybe the prime_mmap stuff, that seems
like it can be improved a bit more still).
-Daniel
>
> Noralf.
>
> Changes since version 3:
> - Drop cache modes (Thomas Hellstrom)
> - Add a GEM object attached vtable
>
> Changes since version 2:
> - Grammar (Sam Ravnborg)
> - s/drm_gem_shmem_put_pages_unlocked/drm_gem_shmem_put_pages_locked/
> (Sam Ravnborg)
> - Add debug ouput in error path (Sam Ravnborg)
>
> Changes since version 1:
> - Fix missing argument in docs (kbuild test robot)
> - Fix: sparse: expression using sizeof(void) (kbuild test robot)
> - Rebasing gave a new checkpatch warning, so I changed to bitfields:
> CHECK: Avoid using bool structure members because of possible alignment
> issues - see: https://lkml.org/lkml/2017/11/21/384
> #834: FILE: include/drm/drm_gem_shmem_helper.h:84:
> + bool pages_mark_dirty_on_put;
> #841: FILE: include/drm/drm_gem_shmem_helper.h:91:
> + bool pages_mark_accessed_on_put;
>
> Noralf Trønnes (4):
> drm/driver: Add defaults for .gem_prime_export/import callbacks
> drm/gem: Add drm_gem_object_funcs
> drm: Add library for shmem backed GEM objects
> drm/tinydrm: Switch from CMA to shmem buffers
>
> Documentation/gpu/drm-kms-helpers.rst | 12 +
> Documentation/gpu/todo.rst | 7 +
> drivers/gpu/drm/Kconfig | 6 +
> drivers/gpu/drm/Makefile | 1 +
> drivers/gpu/drm/drm_client.c | 12 +-
> drivers/gpu/drm/drm_fb_helper.c | 8 +-
> drivers/gpu/drm/drm_gem.c | 109 ++++-
> drivers/gpu/drm/drm_gem_shmem_helper.c | 586 +++++++++++++++++++++++++
> drivers/gpu/drm/drm_prime.c | 50 ++-
> drivers/gpu/drm/tinydrm/Kconfig | 2 +-
> drivers/gpu/drm/tinydrm/core/tinydrm-core.c | 92 ++--
> drivers/gpu/drm/tinydrm/core/tinydrm-helpers.c | 5 +
> drivers/gpu/drm/tinydrm/ili9225.c | 14 +-
> drivers/gpu/drm/tinydrm/ili9341.c | 6 +-
> drivers/gpu/drm/tinydrm/mi0283qt.c | 6 +-
> drivers/gpu/drm/tinydrm/mipi-dbi.c | 38 +-
> drivers/gpu/drm/tinydrm/repaper.c | 24 +-
> drivers/gpu/drm/tinydrm/st7586.c | 15 +-
> drivers/gpu/drm/tinydrm/st7735r.c | 6 +-
> include/drm/drm_drv.h | 4 +
> include/drm/drm_gem.h | 140 ++++++
> include/drm/drm_gem_shmem_helper.h | 153 +++++++
> include/drm/tinydrm/tinydrm.h | 36 +-
> 23 files changed, 1139 insertions(+), 193 deletions(-)
> create mode 100644 drivers/gpu/drm/drm_gem_shmem_helper.c
> create mode 100644 include/drm/drm_gem_shmem_helper.h
>
> --
> 2.15.1
>
> _______________________________________________
> dri-devel mailing list
> dri-devel@lists.freedesktop.org
> https://lists.freedesktop.org/mailman/listinfo/dri-devel
--
Daniel Vetter
Software Engineer, Intel Corporation
http://blog.ffwll.ch
_______________________________________________
dri-devel mailing list
dri-devel@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/dri-devel
prev parent reply other threads:[~2018-10-01 7:48 UTC|newest]
Thread overview: 10+ messages / expand[flat|nested] mbox.gz Atom feed top
2018-09-26 14:59 [PATCH v4 0/4] drm: Add shmem GEM library Noralf Trønnes
2018-09-26 14:59 ` [PATCH v4 1/4] drm/driver: Add defaults for .gem_prime_export/import callbacks Noralf Trønnes
2018-09-26 14:59 ` [PATCH v4 2/4] drm/gem: Add drm_gem_object_funcs Noralf Trønnes
2018-10-01 7:44 ` Daniel Vetter
2018-09-26 14:59 ` [PATCH v4 3/4] drm: Add library for shmem backed GEM objects Noralf Trønnes
2018-10-01 7:46 ` Daniel Vetter
2018-10-10 19:14 ` Noralf Trønnes
2018-10-11 8:24 ` Daniel Vetter
2018-09-26 14:59 ` [PATCH v4 4/4] drm/tinydrm: Switch from CMA to shmem buffers Noralf Trønnes
2018-10-01 7:48 ` Daniel Vetter [this message]
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=20181001074808.GP11082@phenom.ffwll.local \
--to=daniel@ffwll.ch \
--cc=david@lechnology.com \
--cc=dri-devel@lists.freedesktop.org \
--cc=noralf@tronnes.org \
--cc=sam@ravnborg.org \
/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