Commit Graph

5534 Commits (fc8c3e23fb990efd620ef9d9bf3b91686aecc934)

Author SHA1 Message Date
Jakob Bornecrantz 3e48613b48 Bring dirty code from old branch 2009-11-26 16:47:54 +01:00
Robert Noland 6f66de982a Correctly set DRM_MAX_MINOR for all platforms.
DRM_MAJOR is platform specific, but not used outside of xf86drm.c
that I can find.
2009-11-25 15:09:24 -06:00
Alex Deucher 9558f6377f Add missing DRM_MAX_MINOR define
lost in 500f5b5240

Signed-off-by: Alex Deucher <alexdeucher@gmail.com>
2009-11-24 15:03:32 -05:00
Robert Noland 82bf52fbcd More fixups to allow mesa to build 2009-11-24 10:31:41 -06:00
Robert Noland 170674a606 Finish fixing the build on FreeBSD 2009-11-24 09:27:29 -06:00
Kristian Høgsberg 22d4666904 Add drmGetDeviceNameFromFd function
Determines the /dev filename of the drm fd argument.
2009-11-23 20:51:34 -05:00
Kristian Høgsberg 500f5b5240 Fix build on *BSD
This adds a minimal #ifdef clause to drm.h that we'll push upstream.
Once that goes in we can share drm.h between linux, libdrm, and
the bsd's.
2009-11-23 18:25:11 -05:00
Kristian Høgsberg 863e39b56e Don't hardcore 'yes', use in configure.ac output
Oops, I assumed intel was always enable, but it just defaults to on.
2009-11-23 12:42:36 -05:00
Kristian Høgsberg 696fdb11f4 Output summary of enabled features at the end of configure.ac 2009-11-23 11:41:27 -05:00
Kristian Høgsberg dd6cbe7acb Drop duplicated radeon_*.h files in include/drm
These files are userspace headers and live in radeon/
2009-11-23 11:26:26 -05:00
Kristian Høgsberg 6b3cbe7655 Put mach64_drm.h back in to avoid breaking mesa build
We may want to drop mach64 from mesa instead, but that's a different
discussion.
2009-11-20 20:17:26 -05:00
Kristian Høgsberg 4f070d593c Install kernel headers in ${includedir}/drm 2009-11-20 19:46:34 -05:00
Pekka Paalanen 3a87b1f497 nouveau: fix DRM headers
The nouveau_drmif.h is not the Nouveau DRM kernel ABI file, but purely
user space stuff. Remove it, it does not belong in include/drm/.

Copy the right header from Nouveau kernel v2.6.31-rc9-757-gaca551c.

Signed-off-by: Pekka Paalanen <pq@iki.fi>
2009-11-21 01:00:36 +02:00
Jesse Barnes ee746a83ce Bump libdrm version to 2.4.16 for page flipping 2009-11-20 14:53:47 -08:00
Kristian Høgsberg 1e1b3c0a93 modetest: add pageflip test case to modetest 2009-11-20 14:53:38 -08:00
Kristian Høgsberg b80bcffba6 libdrm: add libdrm support for page flip ioctl 2009-11-20 14:53:27 -08:00
Kristian Høgsberg 10ce0ec188 Merge remote branch 'origin/master' into libdrm 2009-11-20 17:09:03 -05:00
Kristian Høgsberg 1b064cc428 Update README 2009-11-20 17:08:28 -05:00
Maciej Cencora b4312b639d libdrm_radeon: add radeon_bo_is_referenced_by_cs function
Signed-off-by: Alex Deucher <alexdeucher@gmail.com>
2009-11-18 16:07:13 -05:00
Jesse Barnes 2577764a50 drm/i915: add GETPARAM request for page flipping 2009-11-17 20:07:48 +00:00
Kristian Høgsberg e8523e087f Drop stale TODO and unused ChangeLog 2009-11-17 11:15:56 -05:00
Kristian Høgsberg 4f57abfe66 Move libdrm/ up one level 2009-11-17 11:15:06 -05:00
Kristian Høgsberg 9dd3613073 Drop shared-core, bsd-core, linux-core and scripts subdirs 2009-11-17 10:54:11 -05:00
Kristian Høgsberg a66cf9ce68 Use headers copied from kernel instead of shared-core 2009-11-17 10:54:11 -05:00
Kristian Høgsberg ba79b1a8c2 Fix typo in i915 pipe_from_crtc_id ioctl struct name 2009-11-17 10:54:11 -05:00
Kristian Høgsberg 2b42af9a2f Copy headers from kernel v2.6.32-rc6-130-g5b8f0be 2009-11-17 10:54:07 -05:00
Kristian Høgsberg a99680384a Add makefile rule to copy headers from kernel tree 2009-11-17 09:23:52 -05:00
Francisco Jerez c20706ffe5 nouveau: Update some nouveau_class.h definitions from renouveau.xml.
Signed-off-by: Francisco Jerez <currojerez@riseup.net>
Signed-off-by: Pekka Paalanen <pq@iki.fi>
2009-11-15 18:13:28 +02:00
Chris Wilson 83a35b68f4 intel: Export madvise
Wrap the madvise ioctl for use in APPLE_object_purgeable.

Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
Acked-by: Jesse Barnes <jbarnes@virtuousgeek.org>
2009-11-11 13:09:22 +00:00
Julien Cristau 89cc98c0d5 Only install libdrm_intel.pc if we build libdrm_intel 2009-11-05 15:49:09 +00:00
Ben Skeggs b7ed162d29 nouveau: turn another assertion into an error
Signed-off-by: Ben Skeggs <skeggsb@beleth.(none)>
2009-11-04 17:31:18 +10:00
Ben Skeggs f4c5063026 nouveau: modify api slightly to allow caller to handle reloc failures
Signed-off-by: Ben Skeggs <skeggsb@beleth.(none)>
2009-11-04 15:24:27 +10:00
Ben Skeggs a8bdf0e00c nouveau: add reloc refcnt to pending bo list
Signed-off-by: Ben Skeggs <bskeggs@redhat.com>
2009-11-04 14:58:19 +10:00
Ben Skeggs 63910f8aa6 nouveau: drop rendering on the floor rather than asserting if flush fails
Signed-off-by: Ben Skeggs <bskeggs@redhat.com>
2009-11-04 13:24:52 +10:00
Ben Skeggs 68c2ac9640 nouveau: update view of available aperture space after each flush
Signed-off-by: Ben Skeggs <bskeggs@redhat.com>
2009-11-04 13:24:52 +10:00
Mathias Fröhlich 6eafd1cf38 radeon: fix allocation
The old code increments the command stream size by another kbyte, but does
not make sure that the requested packet size fits into the stream. The patch
ensures that the whole next packet fits there and rounds the allocated size to
a power of two.

Signed-off-by: Alex Deucher <alexdeucher@gmail.com>
2009-11-03 11:41:26 -05:00
Kristian Høgsberg b0b96636db Add support for vblank events
The kernel will now write data to the DRM fd for various event types if
requested.  Currently, the only supported event is a vblank event: it contains
the vblank count for the event as well as a timestamp from when the event
ocurred.  Since the DRM fd is now pollable, it's easy to integrate into
existing event loops.
2009-10-29 17:14:09 -07:00
Eric Anholt 0d7ad7e43c intel: Only call clock_gettime once per unreference_final.
Notably when freeing a batchbuffer, we often end up freeing many of the
buffers it points at as well.  Avoiding repeated calls brings us a 9% CPU
win for cairo-gl.

[ # ]  backend                         test   min(s) median(s) stddev. count
before:
[  0]       gl            firefox-talos-gfx   58.941   58.966   0.75%    3/3
after:
[  0]       gl            firefox-talos-gfx   54.186   54.195   0.49%    3/3
2009-10-20 14:24:44 -07:00
Eric Anholt 66d2714f54 intel: Improve bo_references performance by skipping the tree walk.
If the target we're asking about hasn't ever been used as a relocation
target, then it obviously hasn't been used as a target by the batch's reloc
tree.  This is the common case for good GL programming where you only map
fresh buffers, and gives us a 5% win in cairo-gl.

[ # ]  backend                         test   min(s) median(s) stddev. count
before:
[  0]       gl            firefox-talos-gfx   64.680   64.756   0.06%    3/3
after:
[  0]       gl            firefox-talos-gfx   60.816   60.970   0.29%    3/3
2009-10-20 13:31:55 -07:00
Ben Skeggs 67628aa39d nouveau: retry if pushbuf ioctl interrupted by signal
Signed-off-by: Ben Skeggs <bskeggs@redhat.com>
2009-10-20 12:57:46 +10:00
Ben Skeggs fdd960a95c nouveau: function to return status of bo being referenced in pushbuf
Will be used to implement gallium's is_{texture,buffer}_referenced()
callbacks properly.

Signed-off-by: Ben Skeggs <bskeggs@redhat.com>
2009-10-19 09:07:45 +10:00
Patrice Mandin 3a387a983e nouveau: nv30: add render target logbase2 width,height 2009-10-13 22:50:46 +02:00
Eric Anholt a221e4fd92 intel: Add the defines for the kernel overlay support landing in 2.6.33. 2009-10-13 11:36:01 -07:00
Chris Wilson 901bacd29c intel: Fallback to atomic-ops.h [libatomic-ops-dev]
Use the external implementation for atomic operations across a wide
range of architectures.

Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
2009-10-13 15:13:00 +01:00
Chris Wilson 24c905f841 configure: Typo in error message.
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
2009-10-13 14:25:54 +01:00
Chris Wilson fc8f6be5a9 configure: Conditionally build libdrm_intel
Only build libdrm_intel automatically if we have support for atomic
operations. To force configure to build drm pass --enable-intel, which
will cause the configure to error if no support is found. Or pass
--disable-intel to explicitly prevent libdrm_intel from being built.

Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
2009-10-12 23:58:47 +01:00
Eric Anholt a107e5b129 Bump to 2.4.15 for release. 2009-10-08 16:59:17 -07:00
Eric Anholt 9764061ab1 intel: Remove the asserts about the ignored alignment parameter.
I slipped it in with the alloc_tiled changes, since we were explicitly
throwing the parameter away.  It caught some bogus released code, which
we've now fixed, so remove the asserts to keep old drivers working.
2009-10-08 15:55:02 -07:00
Jesse Barnes 3a7dfcdfaf intel: Add a bo_alloc function for tiled BOs.
This simplifies driver code in handling object allocation, and also gives us
an opportunity to possibly cache tiled buffers if it turns out to be a win.

[anholt: This is chopped out of the execbuf2 patch, as it seems to be useful
separately and cleans up the execbuf2 changes to be more obvious]
2009-10-06 15:45:10 -07:00
Eric Anholt 02c775fc75 intel: Fix up some stale doxygen comments. 2009-10-06 15:45:10 -07:00