dri-devel Archive on lore.kernel.org
 help / color / mirror / Atom feed
From: Thierry Reding <thierry.reding@gmail.com>
To: dri-devel@lists.freedesktop.org
Subject: [RFC libdrm 0/6] Add NVIDIA Tegra support
Date: Wed, 19 Feb 2014 17:04:47 +0100	[thread overview]
Message-ID: <1392825893-7380-1-git-send-email-thierry.reding@gmail.com> (raw)

From: Thierry Reding <treding@nvidia.com>

Hi,

This series adds libdrm-tegra with a very lightweight API on top of the
kernel interfaces. Most of the functions provided here have been in use
in various driver efforts in different incarnations. This is an attempt
to consolidate, so I'm looking for review comments especially by Erik
to ensure it can be used by grate.

I've used these to implement basic EXA support in xf86-video-opentegra,
which I've pushed to a repository here[0]. The libdrm patches are also
available in a repository[1] for convenience.

Patch 1 adds support for symbol visibility if GCC supports it. This is
used by later patches to make only the public symbols visible in the
libdrm-tegra shared object.

Patch 2 adds support for managing a Tegra DRM object (which doesn't do
a whole lot more than wrap a file descriptor) and buffer objects.

A small test program is added in patch 3 to check that a Tegra DRM
object can be created on top of a DRM device.

Patch 4 adds functions to open a channel to an engine (gr2d or gr3d),
create and manage a job as well as compose command streams in a push
buffer and wait for a fence.

To make it easier to write further tests, patch 5 introduces some DRM
helpers to setup a screen and attach framebuffers to it. A very basic
interface is also provided for the gr2d unit, which can be used to do
a solid rectangle fill.

Finally patch 6 uses the helpers introduced in patch 5 to fill a sub-
region of the screen with a solid color.

Thierry

[0]: http://cgit.freedesktop.org/~tagr/xf86-video-opentegra/
[1]: http://cgit.freedesktop.org/~tagr/drm/

Thierry Reding (6):
  configure: Support symbol visibility when available
  libdrm: Add NVIDIA Tegra support
  tegra: Add simple test for drm_tegra_open()
  tegra: Add channel, job, pushbuf and fence APIs
  tegra: Add helper library for tests
  tegra: Add gr2d-fill test

 Makefile.am                  |   6 +-
 configure.ac                 |  36 +++++-
 include/drm/Makefile.am      |   1 +
 include/drm/tegra_drm.h      | 157 ++++++++++++++++++++++++++
 tegra/Makefile.am            |  24 ++++
 tegra/channel.c              | 127 +++++++++++++++++++++
 tegra/fence.c                |  72 ++++++++++++
 tegra/job.c                  | 167 +++++++++++++++++++++++++++
 tegra/libdrm_tegra.pc.in     |  11 ++
 tegra/private.h              | 117 +++++++++++++++++++
 tegra/pushbuf.c              | 137 +++++++++++++++++++++++
 tegra/tegra.c                | 253 +++++++++++++++++++++++++++++++++++++++++
 tegra/tegra.h                |  99 ++++++++++++++++
 tests/Makefile.am            |   4 +
 tests/modetest/modetest.c    |   2 +-
 tests/tegra/Makefile.am      |  29 +++++
 tests/tegra/drm-test-tegra.c | 132 ++++++++++++++++++++++
 tests/tegra/drm-test-tegra.h |  55 +++++++++
 tests/tegra/drm-test.c       | 261 +++++++++++++++++++++++++++++++++++++++++++
 tests/tegra/drm-test.h       |  73 ++++++++++++
 tests/tegra/gr2d-fill.c      | 145 ++++++++++++++++++++++++
 tests/tegra/openclose.c      |  63 +++++++++++
 tests/vbltest/vbltest.c      |   2 +-
 23 files changed, 1969 insertions(+), 4 deletions(-)
 create mode 100644 include/drm/tegra_drm.h
 create mode 100644 tegra/Makefile.am
 create mode 100644 tegra/channel.c
 create mode 100644 tegra/fence.c
 create mode 100644 tegra/job.c
 create mode 100644 tegra/libdrm_tegra.pc.in
 create mode 100644 tegra/private.h
 create mode 100644 tegra/pushbuf.c
 create mode 100644 tegra/tegra.c
 create mode 100644 tegra/tegra.h
 create mode 100644 tests/tegra/Makefile.am
 create mode 100644 tests/tegra/drm-test-tegra.c
 create mode 100644 tests/tegra/drm-test-tegra.h
 create mode 100644 tests/tegra/drm-test.c
 create mode 100644 tests/tegra/drm-test.h
 create mode 100644 tests/tegra/gr2d-fill.c
 create mode 100644 tests/tegra/openclose.c

-- 
1.8.4.2

             reply	other threads:[~2014-02-19 16:04 UTC|newest]

Thread overview: 24+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2014-02-19 16:04 Thierry Reding [this message]
2014-02-19 16:04 ` [RFC libdrm 1/6] configure: Support symbol visibility when available Thierry Reding
2014-02-19 21:05   ` Erik Faye-Lund
2014-02-19 21:50     ` Thierry Reding
2014-02-19 16:04 ` [RFC libdrm 2/6] libdrm: Add NVIDIA Tegra support Thierry Reding
2014-02-19 19:59   ` Rémi Cardona
2014-02-19 20:03   ` Erik Faye-Lund
2014-02-19 21:33     ` Thierry Reding
2014-02-19 20:13   ` Erik Faye-Lund
2014-02-19 21:32     ` Thierry Reding
2014-02-19 16:04 ` [RFC libdrm 3/6] tegra: Add simple test for drm_tegra_open() Thierry Reding
2014-02-19 20:19   ` Erik Faye-Lund
2014-02-19 20:50     ` Erik Faye-Lund
2014-02-19 21:34   ` Erik Faye-Lund
2014-02-19 16:04 ` [RFC libdrm 4/6] tegra: Add channel, job, pushbuf and fence APIs Thierry Reding
2014-02-19 19:57   ` Erik Faye-Lund
2014-02-19 21:11     ` Thierry Reding
2014-02-19 16:04 ` [RFC libdrm 5/6] tegra: Add helper library for tests Thierry Reding
2014-02-19 20:54   ` Erik Faye-Lund
2014-02-19 16:04 ` [RFC libdrm 6/6] tegra: Add gr2d-fill test Thierry Reding
2014-02-19 21:03   ` Erik Faye-Lund
2014-02-19 21:49     ` Thierry Reding
2014-03-20 15:23 ` [RFC libdrm 0/6] Add NVIDIA Tegra support Erik Faye-Lund
2014-04-08 12:58   ` Erik Faye-Lund

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=1392825893-7380-1-git-send-email-thierry.reding@gmail.com \
    --to=thierry.reding@gmail.com \
    --cc=dri-devel@lists.freedesktop.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