should fix PR#40029. while there, fix the radeon unload, which
was improperly matching mutex init/destroy operations and leading
to trying to destroy lock that was never initialised.
vnode that may disappear before the caller has a chance to reference it.
Reference the vnode while the specfs cache is locked.
Welcome to 5.99.37.
No objections on tech-kern.
some firmware sizes are the expected size. (XXX make all.)
based upon similar changes seen in the linux radeon drm driver.
this saves about 250KB in the kernel or module.
Rename real routines to proc_find() and pgrp_find(), remove PFIND_* flags
and have consistent behaviour. Provide proc_find_raw() for special cases.
Fix memory leak in sysctl_proc_corename().
COMPAT_LINUX: rework ptrace() locking, minimise differences between
different versions per-arch.
Note: while this change adds some formal cosmetics for COMPAT_DARWIN and
COMPAT_IRIX - locking there is utterly broken (for ages).
Fixes PR/43176.
useful yet, but that's not a big deal since the latest xf86-video-ati
doesn't support DRM on these yet.
new microcode images obtained from:
http://people.freedesktop.org/~agd5f/radeon_ucode/
XXX: need to fix max_hw_contexts handling at the very least.
XXX: should convert radeondrm to use firmload(9)
this is mostly from freebsd (though it also exists in other versions
of the drm code) svn commits:
--
SVN rev 196470 on 2009-08-23 14:55:57Z by rnoland
Add kernel support for Radeon R6/7xx 3D.
You will still need Mesa from git and possibly an updated DDX driver,
but this is working fairly well now.
--
SVN rev 196142 on 2009-08-12 12:57:02Z by rnoland
Add support for radeon RS880 IGP chips to drm.
--
SVN rev 195501 on 2009-07-09 16:39:28Z by rnoland
Add support for Radeon HD 4770 (RV740) chips.
--
SVN rev 196471 on 2009-08-23 15:02:58Z by rnoland
Add GET_PARAM support for Z pipes.
This is needed for occulsion queries on rv530 chips.
--
SVN rev 198695 on 2009-10-30 18:07:22Z by rnoland
A bit of cleanup work on radeon_freelist_get()
* Fix the main loop to search all buffers before sleeping.
* Remove dead code
--
SVN rev 197606 on 2009-09-28 22:41:28Z by rnoland
Fix offset handling
--
SVN rev 197605 on 2009-09-28 22:40:29Z by rnoland
radeon_family is an enum, so ordering can be important.
sync up with what amd is shipping.
--
SVN rev 197603 on 2009-09-28 22:37:07Z by rnoland
R600 doesn't support IRQs yet, so don't try to use them.
--
special thanks to robert noland @ freebsd for making this an
easy port!
some bus space somewhere. otherwise, just use normal accesses since
it is normal memory.
this fixes radeondrm on x86 since bus_space_tag_t became a pointer.
add the "GEM" and "TTM" mapping types to sysctl support (though right
now we will never have them in our list of maps.)
- we have to DRM_LOCK()/DRM_UNLOCK(), thus s/rad_dev/dev/ in a variable name
- only call into radeon_cp_{stop,resume}() if the device is active
with this my nforce4 dual core amd system is able to suspend/resume with both
X and drm active.
and non-const types, and the kernel uses both const and non-const
PMF qualifiers and device suspensors, so change the pmf_qual_t and
device_suspensor_t typedefs from "pointers to const" to non-pointer,
non-const types.
viadrm0 at vga1: VIA P4M900 / VN896
viadrm0: AGP at 0xf0000000 128MB
viadrm0: Initialized via 2.11.1 20070202
xf86-video-openchrome seems happy with it, although 3d acceleration isn't
supported on the P4M900 so I can't test that part.
("(boundary & (boundary - 1)) == 0") triggers with i915drm in recent -5 kernel
Read the comment in the code for a detailed explanation. This should be fixed
properly in the i386 bus code, but it is too intrusive to do for -5.
XXX: pullup for 5.x
all the files attached to dev->files. we check for one per "open_count"
that is above 1. could perhaps assert() that we are empty afterwards.
this fixes restarting X + drm after actually using drm.
- call drm_rmmap() in radeon_do_cleanup_cp on the two maps created
- in several vblank functions, check to make sure we have mappings
enabled before doing something that might blow up. fixes PR#41715.
with our changes and the work recently done by Arto Huusko
<arto.huusko@pp2.inet.fi> and FUKAUMI Naoki <fun@naobsd.org>.
it includes all the changes arto provided from both mesa-drm and
the r6xx-r7xx-support branch. it does not yet include code to
handle the (deleted) drm_pciids.h file, but i'll probably just
check in a generated one for now.
i have not yet merged the changes from outside this dir.
from arto's messages to tech-x11:
The important change that was needed is that drm_scatter.c was
fixed to return pointer to all allocated pages, not just the
beginning of the allocated segments.
Other changes:
- drm_scatter maps COHERENT memory
- drm_drawable: drawable handle allocation is done
inside lock
- drm_memory: when mapping "agp" memory, store offset
of mapped area, so that new requests to same offset
return the same area instead of trying to remap
and fail
- drm_vm: use bus_space_mmap for frame buffer and registers
- r600_cp.c: ioremapfree allocated gart range
- radeon_cp.c: use mtsleep
- some memset calls I had added had their args swapped,
and no memory was cleared
revision 1.17
date: 2009/03/29 19:50:17; author: mrg; state: Exp; lines: +7 -7
drm_addmap():
- for _DRM_CONSISTENT mappings, keep the handle.
- use DRM_HANDLE_NEEDS_MASK()
drm_mapbufs():
- use DRM_HANDLE_NEEDS_MASK()
drm_mmap():
- use DRM_HANDLE_NEEDS_MASK()
- for _DRM_SCATTER_GATHER and _DRM_SHM, use vtophys() on the
adjusted offset. XXX
this is gets radeon working on amd64 with an older PCI 9250 card.
XXX: need to excise vtophys() usage.
XXX: need to finish porting these fixes to external.
yay! this takes care of one of the XXX's. still not quite working.
- fix a DEBUG message
- apply from sys/dev:
revision 1.20
date: 2009/01/18 10:04:35; author: mrg; state: Exp; lines: +6 -2
Don't attempt to unload a DRM device that's in use. (Note:
Unloading doesn't work right in any case -- it doesn't clean up the
sysctl tree, among other things. This code needs Work, but at least
this prevents it crashing randomly due to autounload while X is
running.) Also, fix the dependency list for radeondrm.
contributed anonymously.