Commit Graph

175 Commits (104c895f650cac7741c12e10ee78bb2fca2cbd49)

Author SHA1 Message Date
Emil Velikov 104c895f65 drm: remove no longer needed VISIBILITY_CFLAGS
With earlier commits we've annotated the private symbols, thus
we no longer require the -fvisibility=hidden CFLAGS.

Cc: Ben Skeggs <bskeggs@redhat.com>
Cc: Damien Lespiau <damien.lespiau@intel.com>
Cc: Maarten Lankhorst <maarten.lankhorst@canonical.com>
Cc: Michel Dänzer <michel.daenzer@amd.com>
Cc: Rob Clark <robdclark@gmail.com>
Cc: Thierry Reding <treding@nvidia.com>
Signed-off-by: Emil Velikov <emil.l.velikov@gmail.com>
2015-04-28 11:19:15 +01:00
Emil Velikov 40902b9fa1 configure.ac: split -fvisibility and __attribute__((visibility)) checks
The former does not imply the latter and vice-versa. One such example is
the Sun compiler.

v2: Add missing closing brakets. (Alan)

Cc: Alan Coopersmith <alan.coopersmith@oracle.com>
Cc: Thierry Reding <treding@nvidia.com>
Signed-off-by: Emil Velikov <emil.l.velikov@gmail.com>
2015-04-28 11:18:43 +01:00
Damien Lespiau 5f7b6723e1 build: Bump version number to 2.4.60 before release
Signed-off-by: Damien Lespiau <damien.lespiau@intel.com>
2015-03-19 14:36:56 +00:00
Emil Velikov d20413a7ce configure.ac: error out if building freedreno_kgsl without freedreno
The former is a subset of the latter. Error out early so the user is
aware that they are doing something very wrong.

Cc: Rob Clark <robdclark@gmail.com>
Signed-off-by: Emil Velikov <emil.l.velikov@gmail.com>
Reviewed-by: Rob Clark <robdclark@gmail.com>
2015-03-17 22:37:05 +00:00
Emil Velikov 648508518e configure.ac: fix help string copy/pasta
The message "enabled on x86" was meant for the intel libdrm.
Take the opportunity to mention how libkms is autodetected.

Signed-off-by: Emil Velikov <emil.l.velikov@gmail.com>
2015-03-17 22:37:03 +00:00
Emil Velikov 0e4d5a3a46 configure.ac: fix host_cpu/atomics detection
Previous code was busted, as it wasn't checking directly for what it was
meant to, and at the end changing the user's selection if host_cpu
heuristics were involved.

Simplify things by adding a macro that does the long message printing
for us, and check for only what we need.

This fixes commit 36cff14bb03(configure: omap, freedreno and tegra
require atomics) which incorrectly assumed that the code was working
fine, and effectively made impossible to enable freedreno due to it's
host_cpu detection.

Cc: Rob Clark <robdclark@gmail.com>
Signed-off-by: Emil Velikov <emil.l.velikov@gmail.com>
2015-03-17 22:37:02 +00:00
Emil Velikov d8ea64d90b configure: Stop using AM_MAINTAINER_MODE
AM_MAINTAINER_MODE can be used to disable generation of rebuild rules.
This is not something we want to condone/support, considering it can
cause greater problems than the perceived benefits. Additionally the
Automake manual leans towards avoiding the use of AM_MAINTAINER_MODE.

http://www.gnu.org/software/automake/manual/html_node/maintainer_002dmode.html

Signed-off-by: Emil Velikov <emil.l.velikov@gmail.com>
2015-03-17 22:34:59 +00:00
Alan Coopersmith 0e1135de5c On Solaris, #include <sys/mkdev.h> in xf86drm.c
Needed on Solaris for the definitions of major() & minor() used in
drmGetNodeTypeFromFd() and makedev() used in drmOpenMinor()

Signed-off-by: Alan Coopersmith <alan.coopersmith@oracle.com>
Reviewed-by: Emil Velikov <emil.l.velikov@gmail.com>
2015-03-14 08:37:36 -07:00
Maarten Lankhorst 5ea6f1c326 nouveau: make nouveau importing global buffers completely thread-safe, with tests
While I've closed off most races in a previous patch, a small race still existed
where importing then unreffing cound cause an invalid bo. Add a test for this case.

Racing sequence fixed:

- thread 1 releases bo, refcount drops to zero, blocks on acquiring nvdev->lock.
- thread 2 increases refcount to 1.
- thread 2 decreases refcount to zero, blocks on acquiring nvdev->lock.

At this point the 2 threads will clean up the same bo.

Signed-off-by: Maarten Lankhorst <maarten.lankhorst@ubuntu.com>
Reviewed-By: Emil Velikov <emil.l.velikov@gmail.com>
2015-03-13 20:26:33 +01:00
Emil Velikov 9244d98136 configure: update help strings
Mention that freedreno and intel are both auto-detected (depending on
the presence of atomics), plus host_cpu "defined".

Signed-off-by: Emil Velikov <emil.l.velikov@gmail.com>
2015-03-10 18:10:52 +00:00
Emil Velikov 36cff14bb0 configure: omap, freedreno and tegra require atomics
They have used them since day one, but the check was never there.

v2:
 - Update the freedreno message (API is no longer experimental).
 - Move the freedreno host_cpu detection next to the intel one.

Cc: Rob Clark <robdclark@gmail.com>
Cc: Thierry Reding <treding@nvidia.com>
Signed-off-by: Emil Velikov <emil.l.velikov@gmail.com>
2015-03-10 18:09:18 +00:00
Maarten Lankhorst d2e0f55246 configure.ac: bump version to 2.4.59 for release 2015-01-21 11:52:33 +01:00
Maarten Lankhorst d5bfbdc62f only enable support for freedreno on arm automatically
Users can still override this by explicitly passing --enable-freedreno
to configure.

Signed-off-by: Maarten Lankhorst <maarten.lankhorst@ubuntu.com>
2015-01-21 11:47:13 +01:00
Rob Clark a5003c6f85 configure/freedreno: enable freedreno by default
Now that enabling freedreno doesn't automatically enable kgsl, lets
enable it by default.  The drm/msm driver has been upstream for a
while now, and it's ABI is locked.  So I don't think we need to keep
calling it experimental.

Signed-off-by: Rob Clark <robclark@freedesktop.org>
2015-01-18 13:18:33 -05:00
Rob Clark 28662b77ee configure/freedreno: make KGSL support optional
libdrm_freedreno currently supports two backends, 'msm' for the upstream
drm/msm driver, and 'kgsl' which supports (to some extent), the android/
downstream kgsl driver plus a sort of drm shim nonsense to get flink
names.

However, kgsl support is strictly on a best-effort basis.  Different
android devices with different versions of kgsl may have different
abi's.  And the existing kgsl interface (at least the parts of it that
we use) is completely broken for 64bit.  Lets disable it by default lest
anyone actually try to use it.

Signed-off-by: Rob Clark <robclark@freedesktop.org>
2015-01-18 13:18:33 -05:00
Thierry Reding 93035cfbeb tegra: Add simple test for drm_tegra_open()
This test opens a device, dumps the version information and checks that
a Tegra DRM context can be opened on it.

Signed-off-by: Thierry Reding <treding@nvidia.com>
2014-11-27 17:20:27 +01:00
Thierry Reding d6a4c2cbd1 libdrm: Add NVIDIA Tegra support
Add the libdrm_tegra helper library to encapsulate Tegra-specific
interfaces to the DRM.

Furthermore, Tegra is added to the list of supported chips in the
modetest and vbltest programs.

Signed-off-by: Thierry Reding <thierry.reding@avionic-design.de>
Signed-off-by: Erik Faye-Lund <kusmabite@gmail.com>
Signed-off-by: Thierry Reding <treding@nvidia.com>
2014-11-27 17:05:35 +01:00
Paulo Zanoni 8f66c98818 tests: add proptest
A small program that allows us to see and modify properties.

Signed-off-by: Paulo Zanoni <paulo.r.zanoni@intel.com>
Signed-off-by: Rob Clark <robclark@freedesktop.org>
2014-11-24 19:51:59 -05:00
Rob Clark 7068d987f4 configure.ac: bump version to 2.4.58 for release
Signed-off-by: Rob Clark <robclark@freedesktop.org>
2014-09-28 14:53:34 -04:00
Rob Clark a6cddb3410 configure.ac: bump version to 2.4.57 for release
Signed-off-by: Rob Clark <robclark@freedesktop.org>
2014-09-28 12:25:21 -04:00
Emil Velikov f3fd11beaa libkms: build the intel backend only when needed
Signed-off-by: Emil Velikov <emil.l.velikov@gmail.com>
Reviewed-by: Jakob Bornecrantz <jakob@vmware.com>
2014-09-28 17:09:34 +01:00
Emil Velikov be7d297172 configure: unconditionally check for atomic ops/primitives
Just have the check once, and let new drivers opt-in if they want
to use them. Move the block further up the script, to tie nicely
with the actual usage of $HW defines.

Move the final $HW users to be alongside their brethren.

Signed-off-by: Emil Velikov <emil.l.velikov@gmail.com>
Reviewed-by: Jakob Bornecrantz <jakob@vmware.com>
2014-09-28 17:09:34 +01:00
Emil Velikov 98ec08d836 automake: remove obsolete makefiles
Rather than having two extra makefiles in order to ship ~10 headers
just fold its 5 lines of code into the top one makefile.

Signed-off-by: Emil Velikov <emil.l.velikov@gmail.com>
Reviewed-by: Jakob Bornecrantz <jakob@vmware.com>
2014-09-28 17:09:33 +01:00
Thierry Reding 5d8357976a configure: Support symbol visibility when available
Checks whether or not the compiler supports the -fvisibility option. If
so it sets the VISIBILITY_CFLAGS variable which can be added to the per
directory AM_CFLAGS where appropriate.

By default all symbols will be hidden via the VISIBILITY_CFLAGS. The
drm_public macro can be used to mark symbols that should be exported.

Reviewed-by: Maarten Lankhorst <maarten.lankhorst@canonical.com>
Reviewed-by: Emil Velikov <emil.l.velikov@gmail.com>
Signed-off-by: Thierry Reding <treding@nvidia.com>
2014-07-30 16:58:14 +02:00
Marek Olšák d6861609b2 configure.ac: bump version to 2.4.56 for release 2014-07-29 18:54:33 +02:00
Maarten Lankhorst 6f15ca8081 bump to version 2.4.55 for release 2014-07-25 15:08:23 +02:00
Alex Deucher 5126fcb2b4 bump version to 2.4.54 for release
Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
2014-05-02 16:59:30 -04:00
Marek Olšák 504d606275 Bump version to 2.4.53 for release 2014-04-10 21:12:54 +02:00
François Tigeot 1d86869da6 Enable libkms by default on DragonFly
Signed-off-by: François Tigeot <ftigeot@wolfpond.org>
2014-03-02 22:15:12 -05:00
Robert Millan cbb31f2d6e drm: Implement drmCheckModesettingSupported() for FreeBSD
Add the missing implementation of drmCheckModesettingSupported()
to detect KMS support on FreeBSD (and GNU/kFreeBSD).

Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=72847
Signed-off-by: Konstantin Belousov <kib@freebsd.org>
Signed-off-by: Robert Millan <rmh@freebsd.org>
2014-01-24 17:52:14 -05:00
Kenneth Graunke 46d451c9a9 Bump the version to 2.4.52
Signed-off-by: Kenneth Graunke <kenneth@whitecape.org>
2014-01-20 10:58:15 -08:00
Rob Clark dc864c8dea Bump the version to 2.4.51
Signed-off-by: Rob Clark <robclark@freedesktop.org>
2014-01-08 15:36:29 -05:00
Marek Olšák 4c5de721c4 Bump the version to 2.4.50 2013-12-03 19:50:22 +01:00
Marek Olšák 7ddc98f92f Bump the version for release 2013-11-23 01:27:57 +01:00
Ian Romanick 71beb7b079 libdrm: bump to 2.4.48 2013-11-15 18:01:08 -08:00
Ben Widawsky 951ebe0081 libdrm: bump to 2.4.47 2013-10-11 09:47:45 -07:00
Emil Velikov bf4a7cd4b2 configure: add AC_LANG_SOURCE call within AC_COMPILE_IFELSE
Documentation states that AC_*_IFELSE has to use AC_LANG_SOURCE or
friends in order to generate the source code to compile.
AC_LINK_IFELSE already handles this, thus convert AC_COMPILE_IFELSE
to silence the final autoconf warnings.

Signed-off-by: Emil Velikov <emil.l.velikov@gmail.com>
Signed-off-by: Eric Anholt <eric@anholt.net>
Reviewed-by: Daniel Kurtz <djkurtz@chromium.org>
2013-09-24 08:52:47 -07:00
Dave Airlie c6d73cfeea libdrm: bump to 2.4.46 2013-07-02 09:24:53 +01:00
Marek Olšák 63aeae1238 configure.ac: bump version to 2.4.45 for release 2013-05-15 19:32:05 +02:00
Jerome Glisse 9768af201e libdrm 2.4.44 2013-04-18 15:01:19 -04:00
Maarten Lankhorst c005f043dc configure.ac: bump version to 2.4.43 for release
Signed-off-by: Maarten Lankhorst <maarten.lankhorst@canonical.com>
2013-03-27 10:42:20 +01:00
Benjamin Gaignard 62d8866021 tests: allow tests programs to be installed
Install test programs is useful in cross compilation case.  By default
the behavior is the same and test programs aren't installed in $bindir.
If --enable-install-test-programs is set then test programs are
installed in $bindir.

Signed-off-by: Benjamin Gaignard <benjamin.gaignard@linaro.org>
Signed-off-by: Rob Clark <robdclark@gmail.com>
2013-03-25 10:34:16 -04:00
Inki Dae bbf6e3dea3 libdrm/exynos: add test application for 2d gpu.
This patch adds library and test application for g2d gpu(fimg2d).

The fimg2d hardware is a 2D graphics accelerator(G2D) that
supports Bit Block Transfer(BitBLT).

The library includes the following primitive drawing operations:
.solid fill - This operation fills the given buffer with
	the given color data.
.copy - This operation copies contents in source buffer to
	destination buffer.
.copy_with_scale - This operation copies contents in source buffer
	to destination buffer scaling up or down properly.
.blend - This operation blends contents in source buffer with
	the ones in destination buffer.

And the above operations uses gem handle or user space address
allocated by malloc() as source or destination buffer.

And the test application includes just simple primitive drawing
tests with the above library.
And the guide to test is as the following,
	"#exynos_fimg2d_test -s connector_id@crtc_id:mode"

With this above simple command, four primitive drawing operations
would be called step by step and also rendered on the output device
to the given connector and crtc id.

Signed-off-by: Inki Dae <inki.dae@samsung.com>
Signed-off-by: Kyungmin Park <kyungmin.park@samsung.com>
Signed-off-by: Rob Clark <robdclark@gmail.com>
2013-03-08 11:49:42 -05:00
Rob Clark 41fc2cc8a9 freedreno: add freedreno DRM
The libdrm_freedreno helper layer for use by xf86-video-freedreno,
fdre (freedreno r/e library and tests for driving gpu), and eventual
gallium driver for the Adreno GPU.  This uses the msm gpu driver
from QCOM's android kernel tree.

Note that current msm kernel driver is a bit strange.  It provides a
DRM interface for GEM, which is basically sufficient to have DRI2
working.  But it does not provide KMS.  And interface to 2d and 3d
cores is via different other devices (/dev/kgsl-*).  This is not
quite how I'd write a DRM driver, but at this stage it is useful for
xf86-video-freedreno and fdre (and eventual gallium driver) to be
able to work on existing kernel driver from QCOM, to allow to
capture cmdstream dumps from the binary blob drivers without having
to reboot.  So libdrm_freedreno attempts to hide most of the crazy.
The intention is that when there is a proper kernel driver, it will
be mostly just changes in libdrm_freedreno to adapt the gallium
driver and xf86-video-freedreno (ignoring the fbdev->KMS changes).

So don't look at freedreno as an example of how to write a libdrm
module or a DRM driver.. it is just an attempt to paper over a non-
standard kernel driver architecture.

v1: original
v2: hold ref's to pending bo's (because qcom's kernel driver doesn't),
    various bug fixes, add ringbuffer markers so we can emit IB's to
    portion of ringbuffer (so that gallium driver can use a single
    ringbuffer for both tile cmds and draw cmds.

Signed-off-by: Rob Clark <robclark@freedesktop.org>
2013-02-14 12:13:15 -05:00
Maarten Lankhorst 183b5f20b5 configure.ac: bump version to 2.4.42 for release
Signed-off-by: Maarten Lankhorst <maarten.lankhorst@canonical.com>
2013-02-05 14:14:01 +01:00
David Herrmann 08cb5c1d02 man: fix manpage build instructions
This fixes all the out-of-tree build-failures with manpages and uses a
.man_fixup file to avoid overriding man-pages on every build.

Manpages are only built if xsltproc is found and the stylesheets are
available locally. You can disable building manpages with
--disable-manpages so the quite expensive xsltproc procedure can be
skipped.

Signed-off-by: David Herrmann <dh.herrmann@googlemail.com>
2013-01-16 10:59:14 -08:00
Maarten Lankhorst 007bff7a03 configure.ac: bump version to 2.4.41 for release 2013-01-16 13:06:52 +01:00
David Herrmann 6b7e45c751 man: convert manpages to XML instead of plain troff
If we want to use the manpages in external documentation other than normal
manpages, we should rather use XML. Furthermore, almost no-one knows troff
today, anyway, and XML allows others to easily add more pages without
having to learn troff.

Signed-off-by: David Herrmann <dh.herrmann@googlemail.com>
2013-01-09 16:17:03 -08:00
Marek Olšák e01d68f9f3 configure.ac: bump version to 2.4.40 for release 2012-11-06 01:23:53 +01:00
Daniel Stone 14db948127 configure.ac: Allow forcible disabling of Cairo support
We don't want to build libdrm tests with Cairo support under Poky, since
they're never used and also cause a build loop from libdrm -> cairo ->
mesa-dri -> libdrm.

To avoid variance in build results, introduce a --disable-cairo-tests
switch.

Signed-off-by: Daniel Stone <daniel@fooishbar.org>
Signed-off-by: Dave Airlie <airlied@redhat.com>
2012-10-08 15:49:23 +10:00