Michel Dänzer [Fri, 22 Jun 2007 09:45:23 +0000 (11:45 +0200)]
Fix vblank wait condition.
Sync-to-vblank actually works again for me with radeon.
Michel Dänzer [Fri, 22 Jun 2007 09:44:38 +0000 (11:44 +0200)]
Use drm_calloc instead of assigning 0.
Michel Dänzer [Fri, 22 Jun 2007 09:44:19 +0000 (11:44 +0200)]
drm_modeset_ctl_t fixes.
s/u64/drm_u64_t/ to allow userspace code using drm.h to compile.
Move 64 bit arg member to the beginning to avoid alignment issues with 32
bit userspace on 64 bit kernels.
Michel Dänzer [Fri, 22 Jun 2007 09:42:54 +0000 (11:42 +0200)]
Remove mask parameter from radeon_acknowledge_irqs().
Simply always acknowledge all interrupts we're interested in, to avoid hard
hangs when an unexpected interrupt is flagged.
Jesse Barnes [Thu, 21 Jun 2007 22:26:34 +0000 (15:26 -0700)]
Merge branch 'vblank-rework' into vblank
Jesse Barnes [Thu, 21 Jun 2007 22:23:20 +0000 (15:23 -0700)]
RADEON: fix race in vblank interrupt handling
It's possible that we disable vblank interrupts and clear the
corresponding flag in irq_enable_reg, but receive an interrupt at just
the wrong time, causing us to not ack it properly, nor report to the
core kernel that it was handled. Fix that case by always handling
vblank interrupts, even if the irq_enable_reg field is clear.
Jesse Barnes [Tue, 19 Jun 2007 00:43:58 +0000 (17:43 -0700)]
Remove broken CRTC enable checks and incorrect user irq enable in set_pipe
routine.
Michel Dänzer [Mon, 18 Jun 2007 11:08:21 +0000 (13:08 +0200)]
radeon: VBlank rework fixups.
Fix range of frame counter registers.
Use DRM_ERR() instead of Linux specific error codes in shared code.
Remove duplicate register definitions and superfluous local variables.
Jesse Barnes [Sat, 16 Jun 2007 00:06:46 +0000 (17:06 -0700)]
Remove broken crtc enable checks, radeon does it slightly differently
(this makes get_vblank_counter return an actual value).
Jesse Barnes [Fri, 15 Jun 2007 18:21:57 +0000 (11:21 -0700)]
First cut at radeon support for the vblank rework.
Michel Dänzer [Fri, 15 Jun 2007 09:01:51 +0000 (11:01 +0200)]
Remove DRIVER_IRQ_VBL(2).
If the driver doesn't support vertical blank interrupts, it won't call
drm_vblank_init(), and dev->num_crtcs will be 0.
Also fix an off-by-one test against dev->num_crtcs.
Michel Dänzer [Fri, 15 Jun 2007 08:49:16 +0000 (10:49 +0200)]
Make vblank waitqueue per CRTC.
Michel Dänzer [Fri, 15 Jun 2007 08:25:50 +0000 (10:25 +0200)]
Wake up vblank waitqueue in drm_handle_vblank().
Michel Dänzer [Fri, 15 Jun 2007 08:21:44 +0000 (10:21 +0200)]
i915: Fix tests for vblank interrupts being enabled on CRTC by X server.
Michel Dänzer [Fri, 15 Jun 2007 08:12:23 +0000 (10:12 +0200)]
Return current sequence number to userspace after blocking wait for vblank.
Michel Dänzer [Fri, 15 Jun 2007 08:10:33 +0000 (10:10 +0200)]
Fix memory leaks in vblank error paths.
Also use drm_calloc instead of drm_alloc and memset, and use the size of the
struct instead of the size of the pointer for allocation...
Jesse Barnes [Thu, 14 Jun 2007 18:32:31 +0000 (11:32 -0700)]
Comment new vblank routines and fixup several issues:
- use correct refcount variable in get/put routines
- extract counter update from drm_vblank_get
- make signal handling callback per-crtc
- update interrupt handling logic, drivers should use drm_handle_vblank
- move wakeup and counter update logic to new drm_handle_vblank routine
- fixup usage of get/put in light of counter update extraction
- fix longstanding bug in signal code, update pending counter only
*after* we're sure we'll setup signal handling
Jesse Barnes [Tue, 12 Jun 2007 23:29:09 +0000 (16:29 -0700)]
Remove unnecessary (and uncommented!) read barrier from the interrupt
path. It doesn't appear to serve any useful purpose.
Jesse Barnes [Tue, 12 Jun 2007 20:35:41 +0000 (13:35 -0700)]
Update vblank code:
- move pre/post modeset ioctl to core
- fixup i915 buffer swap
- fix outstanding signal count code
- create new core vblank init routine
- test (works with glxgears)
- simplify i915 interrupt handler
Jesse Barnes [Tue, 12 Jun 2007 17:44:21 +0000 (10:44 -0700)]
Initial checkin of vblank rework. Code attempts to reduce the number
of vblank interrupt in order to save power.
Dave Airlie [Sun, 10 Jun 2007 05:40:10 +0000 (15:40 +1000)]
use krh's idr mods to remove lists from idr code
Oliver McFadden [Fri, 8 Jun 2007 19:40:57 +0000 (19:40 +0000)]
r300: Added the CP maximum fetch size and ring rptr update variables.
Dave Airlie [Thu, 7 Jun 2007 08:45:00 +0000 (18:45 +1000)]
oops must fix this properly at some point
Dave Airlie [Thu, 7 Jun 2007 08:40:41 +0000 (18:40 +1000)]
drm: fix radeon setparam alignment issues on 32/64-bit
Oliver McFadden [Tue, 5 Jun 2007 19:19:42 +0000 (19:19 +0000)]
r300: Small correction to the previous commit.
Alex Deucher [Tue, 5 Jun 2007 19:05:49 +0000 (19:05 +0000)]
r300: Document more of the RADEON_RBBM_STATUS register.
Wang Zhenyu [Tue, 5 Jun 2007 18:15:29 +0000 (11:15 -0700)]
Add support for the G33, Q33, and Q35 chipsets.
These require that the status page be referenced by a pointer in GTT, rather
than phsyical memory. So, we have the X Server allocate that memory and tell
us the address, instead.
Dave Airlie [Tue, 5 Jun 2007 08:14:54 +0000 (18:14 +1000)]
remove include of linux ioctl32.h from drm drivers
Maurice van der Pot [Mon, 4 Jun 2007 00:49:30 +0000 (10:49 +1000)]
nouveau: fix RAMHT wrapping
Dave Airlie [Sun, 3 Jun 2007 08:30:52 +0000 (18:30 +1000)]
radeon: refine irq acking for vbl on crtc 2
root [Sun, 3 Jun 2007 08:12:28 +0000 (18:12 +1000)]
Revert "drm: add new drm_wait_on function to replace macro"
This reverts commit
6e860d08d0f5b1e9a2d711aaf9fd6b982aa8039e.
As I said not a good plan - this macro will have to stay for now,
trying to do the vbl code with the inline was a bit messy - may need specialised
drm wait on functions
root [Sun, 3 Jun 2007 08:11:44 +0000 (18:11 +1000)]
Revert "move i915 to new drm_wait_on function"
This reverts commit
feb68037784ac09e333a321d294fdb2d8c57a4c8.
This was a bad idea, the macro is actually a bit harder to convert
to a static for the other use cases
Dave Airlie [Sun, 3 Jun 2007 06:28:21 +0000 (16:28 +1000)]
radeon: add support for vblank on crtc2
This add support for CRTC2 vblank on radeon similiar to the i915 support
Dave Airlie [Fri, 1 Jun 2007 09:00:24 +0000 (19:00 +1000)]
drm: fixup initialisation of list heads and idr
Wang Zhenyu [Wed, 30 May 2007 08:25:49 +0000 (16:25 +0800)]
i915: Add support for 945GME chip
Wang Zhenyu [Wed, 30 May 2007 08:24:42 +0000 (16:24 +0800)]
i915: Add support for 965GME/GLE chip.
Jung-uk Kim [Tue, 15 May 2007 20:35:33 +0000 (13:35 -0700)]
Update a bunch of FreeBSD port code.
Tested on r200/r300. i915 updates still remain to be done.
Brian [Tue, 29 May 2007 20:56:17 +0000 (14:56 -0600)]
reformatting, clean-ups
Brian [Tue, 29 May 2007 20:54:00 +0000 (14:54 -0600)]
Clean-ups and reformatting.
Use 4-space indentation consistently.
Replace occurances of:
if (cond) code;
with:
if (cond)
code;
to facilitate putting breakpoints on code.
Dave Airlie [Sat, 26 May 2007 22:44:38 +0000 (08:44 +1000)]
drm: move context handling code to use linux idr
Dave Airlie [Sat, 26 May 2007 21:26:52 +0000 (07:26 +1000)]
drm: convert drawable handling to use Linux idr
This cleans this code up a lot and uses the generic Linux idr which is
designed for this.
Signed-off-by: Dave Airlie <airlied@linux.ie>
Thomas Gleixner [Fri, 25 May 2007 19:20:59 +0000 (05:20 +1000)]
drm: spinlock initializer cleanup
Michel Dänzer [Fri, 25 May 2007 18:35:54 +0000 (04:35 +1000)]
drm: make sure the drawable code doesn't call malloc(0).
Signed-off-by: Michel Dänzer <michel@tungstengraphics.com>
Signed-off-by: Dave Airlie <airlied@linux.ie>
Dave Airlie [Fri, 25 May 2007 18:02:55 +0000 (04:02 +1000)]
radeon: add other IGP chipsets
Dave Airlie [Fri, 25 May 2007 17:48:08 +0000 (03:48 +1000)]
Revert "drm/ttm: cleanup mm_ioctl ioctls to be separate ioctls."
This reverts commit
3fdef0dc2000308b16907b95f637c60acde80a74.
ditto not on master yet
Dave Airlie [Fri, 25 May 2007 17:47:48 +0000 (03:47 +1000)]
Revert "drm/ttm: cleanup most of fence ioctl split out"
This reverts commit
3dfc1400e9fc58c69292d7cf7c2e1653fa5e6991.
this shouldn't have gone on master yet
Dave Airlie [Tue, 8 May 2007 05:43:29 +0000 (15:43 +1000)]
whitespace fixups from kernel
Dave Airlie [Tue, 8 May 2007 05:09:48 +0000 (15:09 +1000)]
ati_pcigart: cut to 80 chars
Dave Airlie [Sun, 6 May 2007 01:35:11 +0000 (11:35 +1000)]
drm/ttm: cleanup most of fence ioctl split out
Dave Airlie [Sun, 6 May 2007 01:17:30 +0000 (11:17 +1000)]
drm/ttm: cleanup mm_ioctl ioctls to be separate ioctls.
This is the first bunch of ioctls
Dave Airlie [Fri, 25 May 2007 18:26:24 +0000 (04:26 +1000)]
drm: cleanup use of Linux list handling macros
This makes the drms use of the list handling macros a lot cleaner
and more along the lines of how they should be used.
Stephane Marchesin [Thu, 17 May 2007 15:35:14 +0000 (17:35 +0200)]
nouveau: don't build the module by default
Oliver McFadden [Sun, 13 May 2007 16:18:54 +0000 (16:18 +0000)]
r300: Added my comments into r300_reg.h.
Oliver McFadden [Sun, 13 May 2007 07:53:40 +0000 (07:53 +0000)]
r300: Synchronized R300 register defines file.
Just moved the indent control comments so that indent doesn't try to change
anything.
Matthieu Castet [Sat, 12 May 2007 13:35:39 +0000 (15:35 +0200)]
nouveau : nv10 graph move clipping value to per channel init
Matthieu Castet [Sat, 12 May 2007 13:16:37 +0000 (15:16 +0200)]
nouveau : nv10 graph clipping values were forgoten in ddx to drm commit
Keith Packard [Mon, 7 May 2007 13:07:48 +0000 (09:07 -0400)]
Allow vblank interrupts to remain disabled across VT switch.
i915_driver_irq_postinstall was forcing vblank interrupts to pipe A when
called with vblank interrupts disabled. This caused vblank interrupts to be
accidentally re-enabled when VT switching the X server. Instead, start the
driver with vblank interrupts enabled on pipe A to support older X servers,
but then leave control over the state to the X server if it is able to do so.
Oliver McFadden [Wed, 9 May 2007 18:31:31 +0000 (18:31 +0000)]
r300: Synchronized R300 register defines file.
Oliver McFadden [Wed, 9 May 2007 15:22:09 +0000 (15:22 +0000)]
r300: Synchronized R300 register defines file.
Matthieu Castet [Tue, 8 May 2007 19:18:02 +0000 (21:18 +0200)]
nouveau : fix fifo context size for nv10
Dave Airlie [Tue, 8 May 2007 07:51:21 +0000 (17:51 +1000)]
libdrm: fix typo on ttm fence interface
Brian [Sun, 6 May 2007 16:09:59 +0000 (10:09 -0600)]
s/OJBECTS/OBJECTS/
Oliver McFadden [Sun, 6 May 2007 12:47:03 +0000 (12:47 +0000)]
r300: Synchronize the register file from Mesa.
Oliver McFadden [Sun, 6 May 2007 12:35:16 +0000 (12:35 +0000)]
r300: Use the defined names for known registers.
Dave Airlie [Sun, 6 May 2007 00:50:10 +0000 (10:50 +1000)]
drm: remove unused define DRM_HAS_TTM
Thomas Hellstrom [Wed, 2 May 2007 15:13:32 +0000 (17:13 +0200)]
Fix buffer object list freeing.
Michel Dänzer [Tue, 1 May 2007 15:03:55 +0000 (17:03 +0200)]
Michel Dänzer [Sun, 29 Apr 2007 10:17:57 +0000 (12:17 +0200)]
radeon: Don't mess up page flipping when a file descriptor is closed.
There can still be other contexts that may use page flipping later on, so don't
just unilaterally 'clean it up', which could lead to the wrong page being
displayed, e.g. when running 3D apps with a GLX compositing manager such as
compiz using page flipping.
Dave Airlie [Sat, 28 Apr 2007 05:07:22 +0000 (15:07 +1000)]
move i915 to new drm_wait_on function
Dave Airlie [Sat, 28 Apr 2007 05:05:20 +0000 (15:05 +1000)]
drm: add new drm_wait_on function to replace macro
Dave Airlie [Sat, 28 Apr 2007 05:04:49 +0000 (15:04 +1000)]
remove register usage
Dave Airlie [Sat, 28 Apr 2007 04:49:27 +0000 (14:49 +1000)]
remove DRM_GETSAREA and replace with drm_getsarea function
George Sapountzis [Thu, 26 Apr 2007 11:16:51 +0000 (14:16 +0300)]
Revert "bug 7092 : add pci ids for mach64 in Dell poweredge 4200"
This reverts commit
255f3e6f76dfd267a14765dd1293229184298d89.
Rage IIc does not have a vertex setup engine.
George Sapountzis [Thu, 26 Apr 2007 11:16:28 +0000 (14:16 +0300)]
linux: minor indent.
George Sapountzis [Thu, 26 Apr 2007 11:16:13 +0000 (14:16 +0300)]
freebsd: remove stray apperance of IN_MODULE.
The xserver no longer uses the libc-wrapper.
George Sapountzis [Thu, 26 Apr 2007 11:15:55 +0000 (14:15 +0300)]
libdrm: remove HAVE_XORG_CONFIG_H and XFree86LOADER ifdef's.
We no longer import libdrm in the xserver.
Dave Airlie [Thu, 26 Apr 2007 07:54:06 +0000 (17:54 +1000)]
update create_lk_drm.sh script
Dave Airlie [Thu, 26 Apr 2007 06:25:43 +0000 (16:25 +1000)]
whitespace cleanup
Dave Airlie [Thu, 26 Apr 2007 06:22:28 +0000 (16:22 +1000)]
remove some whitespace violation
Dave Airlie [Thu, 26 Apr 2007 06:22:11 +0000 (16:22 +1000)]
drm: nopfn warning on 64-bit
Jesse Barnes [Thu, 26 Apr 2007 06:09:24 +0000 (16:09 +1000)]
drm/ttm: allow drm_buffer_object_create to be used in-kernel
Jesse Barnes [Wed, 11 Apr 2007 19:51:52 +0000 (12:51 -0700)]
Add new buffer object type for kernel allocations that don't initially have a user mapping.
(cherry picked from commit
2e21779992bd5026d8ec4dea52466377dbe5a0ed)
Brian [Wed, 25 Apr 2007 20:52:29 +0000 (14:52 -0600)]
More detailed instructions, tips.
Stephane Marchesin [Mon, 23 Apr 2007 20:37:01 +0000 (22:37 +0200)]
nouveau: fix wacky pci id
Kristian Høgsberg [Fri, 20 Apr 2007 22:06:31 +0000 (18:06 -0400)]
Initialize rwlock using rwlock_init to appease lockdep validator.
Thomas Hellstrom [Thu, 19 Apr 2007 21:25:14 +0000 (23:25 +0200)]
Avoid a fence timeout problem when a signal is pending.
Thomas Hellstrom [Fri, 20 Apr 2007 13:49:31 +0000 (15:49 +0200)]
Fix via compile error
(Reported by Benno Schulenberg.)
Thomas Hellstrom [Wed, 18 Apr 2007 14:33:28 +0000 (16:33 +0200)]
Simplify the ttm backend interface and the agp ttm backend.
Thomas Hellstrom [Tue, 17 Apr 2007 12:15:37 +0000 (14:15 +0200)]
Don't always free up memory space when we unpin buffers.
Thomas Hellstrom [Tue, 17 Apr 2007 08:53:19 +0000 (10:53 +0200)]
Fix buffer object reference problems.
(Reported by Dave Airlie).
Thomas Hellstrom [Tue, 17 Apr 2007 06:58:23 +0000 (08:58 +0200)]
via: Make sure we flush write-combining using a follow-up read.
Thomas Hellstrom [Tue, 17 Apr 2007 06:46:45 +0000 (08:46 +0200)]
Add a code comment.
Thomas Hellstrom [Mon, 16 Apr 2007 14:23:05 +0000 (16:23 +0200)]
Require the hardware lock for buffer creation
(since that implies a validate).
Fix drm_bo_wait_unfenced error messages and codes.
Fix some return codes from libdrm.
Matthieu Castet [Tue, 10 Apr 2007 21:19:29 +0000 (23:19 +0200)]
nouveau: nv10 per channel init from ddx
Oliver McFadden [Mon, 9 Apr 2007 23:23:40 +0000 (23:23 +0000)]
rs480: Renamed some unknown registers. See dri-devel list.
Ben Skeggs [Mon, 9 Apr 2007 13:20:26 +0000 (23:20 +1000)]
nouveau: NV46 support
Dave Airlie [Mon, 9 Apr 2007 12:00:34 +0000 (22:00 +1000)]
radeon: bump version for IGPGART support
Dave Airlie [Mon, 9 Apr 2007 11:52:59 +0000 (21:52 +1000)]
radeon: add support for reverse engineered xpress200m
The IGPGART setup code was traced using mmio-trace on fglrx by myself
and Phillip Ezolt <phillipezolt@gmail.com> on dri-devel.
This code doesn't let the 3D driver work properly as the card has no
vertex shader support.
Thanks to Matthew Garrett + Ubuntu for providing me some hardware to do this
work on.
Dave Airlie [Fri, 6 Apr 2007 21:21:05 +0000 (07:21 +1000)]
fixup install target, not sure what I was smokin...
Dave Airlie [Sun, 1 Apr 2007 06:30:52 +0000 (16:30 +1000)]
i915: use breadcrumb macro everywhere