vehemens
3e9541230d
[FreeBSD] Move vblank bits into their own structure.
...
Signed-off-by: Robert Noland <rnoland@2hip.net>
2008-08-24 15:25:19 -04:00
vehemens
e6010778a8
[FreeBSD] Fix lock leak.
...
Signed-off-by: Robert Noland <rnoland@2hip.net>
2008-08-24 15:25:19 -04:00
Robert Noland
7a3d6624c4
[FreeBSD] Duh, we need to actually define the drm_modeset_ctl...
2008-07-25 13:46:28 -04:00
Robert Noland
2580a065d8
[FreeBSD] Catch up to linux on vblank-rework
2008-07-24 00:21:00 -04:00
Robert Noland
f57f01f028
[FreeBSD] Improve upper_32_bits define.
...
Thanks to airlied.
2008-07-21 18:06:52 -04:00
Robert Noland
480c317a6a
[FreeBSD] drm_irq.c updates for vblank fixes.
2008-07-17 14:08:06 -04:00
Robert Noland
b0e4619a39
FreeBSD: Fix radeon build
2008-07-16 23:39:25 -04:00
Owain Gordon Ainsworth
74cf1f91be
BSD: change drm_locked_task*() to use the same scheme as linux.
...
The current code can sleep in an interrupt handler, that is bad. So
instead if we can't grab the lock, flag it and run the tasklet on
unlock.
Signed-off-by: Robert Noland <rnoland@2hip.net>
2008-07-16 21:37:39 -04:00
Robert Noland
96580f660e
[FreeBSD] We aren't allowed to hold locks over bus_dma_tag_create or bus_dmamem_alloc.
2008-07-15 16:53:54 -04:00
Robert Noland
29ffa0017d
[FreeBSD] Fix another lock leak
...
Reported by vehemens
2008-06-13 17:41:34 -04:00
Robert Noland
116870a908
I915 suspend/resume for FreeBSD
2008-06-08 13:56:14 -04:00
Robert Noland
3b6ca4bf3f
[FreeBSD] Rework ati_pcigart.c
...
This is mostly just a diff reduction with the linux version.
I'm not convinced that it will make anything better.
2008-06-08 02:00:48 -04:00
Robert Noland
96141bd33c
[FreeBSD] We need to request busmastering support.
...
This seems to be the key to getting at least some radeon
cards working. Most, if not all drivers need it enabled,
so just request it once the driver has attached.
2008-06-08 02:00:48 -04:00
Robert Noland
6d6921719c
[FreeBSD] Incorporate vblank fixes for bsd.
2008-06-08 01:53:45 -04:00
Robert Noland
ec3d996021
[FreeBSD] Forgot to call mtx_destroy on all the locks at unload.
2008-06-08 01:53:45 -04:00
Robert Noland
93c57ff4e5
[FreeBSD] Remove the locks in the vblank_disable_fn
...
They are recursive and causing panics with witness enabled.
2008-06-08 01:53:45 -04:00
Robert Noland
fc74c2e9d6
[FreeBSD] Go back to using vbl_lock and move init/destroy to load/unload.
2008-06-08 01:53:45 -04:00
Robert Noland
416754f1cc
[FreeBSD] Declare vblank_disable_fn callout MPSAFE.
2008-06-01 20:33:30 -07:00
Robert Noland
4ce47fd328
[FreeBSD] Get rid of vbl_lock and re-use irq_lock.
2008-06-01 20:33:30 -07:00
Robert Noland
ac4da86928
[FreeBSD] Add symlink for radeon_microcode.h
2008-06-01 12:07:54 -07:00
Robert Noland
2186f9f6ef
[FreeBSD] Call drm_vblank_cleanup during irq uninstall
...
I needed to re-arrange some functions for this.
Also needed to call DRM_SPINUNINIT on the vbl_lock during cleanup.
2008-06-01 12:07:54 -07:00
Owain Ainsworth
df127c303d
[BSD] Move unlock in drm_vm.c from accidental platform #ifdeffing.
...
Also remove an unreachable unlock.
2008-05-27 15:12:35 -07:00
Owain Ainsworth
cc7ad27fe4
[BSD] Fix lock leak in drm_update_draw malloc failure path.
2008-05-27 15:11:25 -07:00
Owain Ainsworth
9a2ae28fbe
[BSD] Fix lock leaks in error paths in drm_bufs.c.
2008-05-27 15:07:04 -07:00
Owain Ainsworth
200ac59573
[BSD] Remove superfluous recursive locking in drm_add_magic.
2008-05-27 14:59:38 -07:00
Robert Noland
8cd045079e
[FreeBSD] Add vblank-rework support and get drivers building.
...
The i915 driver now works again.
2008-05-27 14:25:20 -07:00
Eric Anholt
ad8eb0ed01
[FreeBSD] Convert from drm_device_t to struct drm_device for consistency.
2008-05-27 14:25:08 -07:00
Robert Noland
690dd04d1b
bsd: Replace other occurrences of msleep with mtx_sleep
2007-12-02 01:45:09 -05:00
Robert Noland
fbc307274f
bsd: Now make secondary vblank work
...
We needed to specifically check for driver support and test the correct
vbl_received value. Also pulled over support for _DRM_VBLANK_NEXTONMISS
from the linux code.
2007-12-02 01:23:11 -05:00
Robert Noland
787d500c15
bsd: Hook secondary vblank support.
2007-12-01 17:23:09 -05:00
Robert Noland
e6ca3f5754
bsd: Fix typo in i915_drv.c
2007-12-01 16:35:48 -05:00
Robert Noland
0c3e5261b6
mtx_sleep is preferred to msleep
...
Calling semantics are the same and both were introduced in 5.0
2007-12-01 14:44:30 -05:00
Robert Noland
d6295cc9ff
drm: Add _DRM_DRIVER map flag.
...
This flag indicates that the driver is responsible for the map.
2007-12-01 02:40:13 -05:00
Robert Noland
83e62be6f4
bsd: Move counter initialization to load time.
2007-12-01 02:32:23 -05:00
Robert C. Noland III
9be085cbf4
Fix up drm_ati_pcigart_info
2007-11-29 09:38:43 +10:00
Robert Noland
c12a3a3ce0
Bug #13233 : Chase move of agp headers on FreeBSD.
2007-11-18 22:41:41 -08:00
Kristian Høgsberg
68cdcda1ea
Add new shared header file drm_internal.h.
...
This header file is shared across linux and bsd, but is not installed
for user space to access. It's the place to put prototypes and data
types that aren't platform or chipset specific, but still internal to
the drm.
2007-11-14 14:28:34 -05:00
Jung-uk Kim
36120264ca
Bug #11870 : FreeBSD hardware lock cleanup fix with multiple opens by a process.
...
Previously, the lock would get released on the first close by the X Server
(during AIGLX setup), and the Radeon driver would then hang in initialization
due to unexpected failure in DRM calls that required the lock to be held.
Based on a patch by Kostik Belousov.
2007-10-17 12:52:12 -07:00
Eric Anholt
f0fd53f86b
FreeBSD: Fill in domain field when supported.
2007-10-10 15:32:05 -07:00
Eric Anholt
b668d6d905
Fix dev->agp->base initialization on BSD, and fix addmap range check on Linux.
...
With the previous linux commit, an AGP aperture at the end of the address space
would have wrapped to 0 and the test would have failed.
2007-08-15 14:29:31 -07:00
Eric Anholt
6e93c35ba7
BSD: Return EINVAL if drm_unlock is called on an unheld or other-owner lock.
2007-08-15 13:42:04 -07:00
vehemens
a9ee144eab
BSD: simplify drm_ioctl() after other refactoring.
2007-08-15 11:12:46 -07:00
vehemens
4cdd871e90
Bug #11989 : Fix regression in getstats ioctl (kernel panic).
2007-08-15 11:06:49 -07:00
Eric Anholt
56133e04de
BSD: Fix regression in setversion ioctl (current version not returned).
2007-08-15 11:06:49 -07:00
Eric Anholt
5346fc5f36
BSD: Replace brief description in each file's first line with doxygen later on.
...
The brief descriptions usually had the wrong filename in them.
2007-08-15 11:06:49 -07:00
vehemens
4340f49bf7
Bug #11951 : Fix an errno sign inversion on pre-FreeBSD 5.
...
Also, annotate where signs change, to hopefully remind the reader of these
issues in the future.
2007-08-13 11:36:10 -07:00
Eric Anholt
3b07a37a48
Add doxygen and fix whitespace for drm_auth.c
2007-08-13 10:50:25 -07:00
vehemens
263775c454
Fix drm_auth.c locking to not recurse on dev_lock.
2007-08-13 10:24:39 -07:00
Eric Anholt
be3099f265
Fix copy'n'paste-o in FreeBSD drawable code.
2007-07-25 12:59:43 -07:00
Eric Anholt
5b38e13416
Replace DRM_IOCTL_ARGS with (dev, data, file_priv) and remove DRM_DEVICE.
...
The data is now in kernel space, copied in/out as appropriate according to the
This results in DRM_COPY_{TO,FROM}_USER going away, and error paths to deal
with those failures. This also means that XFree86 4.2.0 support for i810 DRM
is lost.
2007-07-20 18:16:42 -07:00