summaryrefslogtreecommitdiff
path: root/bsd/drmP.h
AgeCommit message (Collapse)AuthorFilesLines
2005-08-16Remove the long-stale BSD non-core bits.Eric Anholt1-625/+0
Prodded by: CVS breakage resulting in complaints about this directory.
2005-01-16The patch makes drmAddBufs/drmMapBufs can handle buffers in video memoryDave Airlie1-1/+2
The attached patch adds a new buffer type DRM_FB_BUFFER. It works like AGP memory but uses video memory. From: austinyuan@viatech.com.cn (fd.o bug 1668) Signed-off-by: Dave Airlie <airlied@linux.ie>
2004-08-17Merged drmfntbl-0-0-1drmfntbl-0-0-1-20040817-mergeDave Airlie1-13/+63
2004-07-06MFC as of 20040705: dev_t -> struct cdev * change.Eric Anholt1-1/+1
2004-05-09drm_hw_lock_t is now defined in drm.h, remove from here.Eric Anholt1-5/+0
2003-12-16Don't ioremap the framebuffer area. The ioremapped area wasn't used bydriinterface-0-0-2-branchEric Anholt1-2/+2
anything, and took up valuable KVA. While I'm in the area, clean up BSD MTRR stuff some more. Suggested by: jonsmirl
2003-11-05- Tie the DRM to a specific device: setunique no longer succeeds when givenEric Anholt1-3/+13
a busid that doesn't correspond to the device the DRM is attached to. This is a breaking of backwards-compatibility only for the multiple-DRI-head case with X Servers that don't use interface 1.1. - Move irq_busid to drm_irq.h and make it only return the IRQ for the current device. Retains compatibility with previous X Servers, cleans up unnecessary code. This means no irq_busid on !__HAVE_IRQ, but can be changed if necessary. - Bump interface version to 1.2. This version when set signifies that the control ioctl should ignore the irq number passed in and enable the interrupt handler for the attached device. Otherwise it errors out when the passed-in irq is not equal to the device's. - Store the highest version the interface has been set to in the device. - Fix a recursion on DRM_LOCK in irq_uninstall on FreeBSD. This leaves irq_uninstall being done without the lock in some cases, but it was racey anyways.
2003-11-05Remove buf_alloc which is unused since the locking commit.Eric Anholt1-1/+0
2003-11-04Memory layout transition:Michel Daenzer1-0/+3
the 2D driver initializes MC_FB_LOCATION and related registers sanely the DRM deduces the layout from these registers clients use the new SETPARAM ioctl to tell the DRM where they think the framebuffer is located in the card's address space the DRM uses all this information to check client state and fix it up if necessary This is a prerequisite for things like direct rendering with IGP chips and video capturing.
2003-10-23- Introduce a new ioctl, DRM_IOCTL_SET_VERSION. This ioctl allows theEric Anholt1-3/+2
server or client to notify the DRM that it expects a certain version of the device dependent or device independent interface. If the major doesn't match or minor is too large, EINVAL is returned. A major of -1 means that the requestor doesn't care about that portion of the interface. The ioctl returns the actual versions in the same struct. - Introduce DRM DI interface version 1.1. If the server requests version 1.1, then the DRM sets the unique itself according to the busid of the device it probed, which may then be accessed as normal using getunique. - Request version 1.1 in libdrm's drmOpenByBusID, allowing the X Server to request based on a BusID. Introduce a wrapper for DRM_IOCTL_SET_VERSION and bump libdrm minor version. - Pass the busid in DRIScreenInit if libdrm can handle both a busid and name. This allows drmOpenByBusID to be used to find the DRM instead of just the driver name, which allows us in the future to tie a DRM more strongly to the device it probed to. Introduce a function DRICreatePCIBusID which creates a busid in the form pci:oooo:bb:dd.f similar to linux's pci_name() function. This matches the format used by the DRM in version 1.1. libdrm knows how to match both this format and the old PCI:b:d:f format. - Use the new DRICreatePCIBusID function in the *_dri.c to request the new, more exact busid format.
2003-10-20Clean up BSD MTRR handling. The NetBSD code is untested, but it's my bestEric Anholt1-0/+2
shot.
2003-10-19- SMPng lock the DRM. This is only partial -- there are a few code pathsEric Anholt1-17/+20
used by root (the X Server) which are not locked. However, it should deal with lost-IRQ issues on -current which I think people have been experiencing but I am unable to reproduce (though I understand why they would occur, because of a bug of mine). Note that most of the locking (DRM_LOCK()/UNLOCK()) is all covered by Giant still, so it doesn't matter yet. - Remove locking on FreeBSD-stable and NetBSD. These are covered by the fact that there is no reentrancy of the kernel except by interrupts, which are locked using spldrm()/splx() instead.
2003-10-17- Move IRQ functions from drm_dma.h to new drm_irq.h and disentangle themEric Anholt1-9/+11
from __HAVE_DMA. This will be useful for adding vblank sync support to sis and tdfx. Rename dma_service to irq_handler, which is more accurately what it is. - Fix the #if _HAVE_DMA_IRQ in radeon, r128, mga, i810, i830, gamma to have the right number of underscores. This may have been a problem in the case that the server died without doing its DRM_IOCTL_CONTROL to uninit.
2003-10-17- Converted Linux drivers to initialize DRM instances based on PCI IDs, notEric Anholt1-0/+8
just a single instance. Moved the PCI ID lists from <card>_drv.c in BSD to <card>.h. The PCI ID lists include a driver private field, which may be used by drivers for chip family or other information. Based on work by jonsmirl. - Make tdfx_drv.c and tdfx.h match other drivers. - Fixed up linking of sis shared files. Tested with Radeon and SiS on Linux and FreeBSD, including a Linux setup with 2 SiS cards in a machine, but only one head being used (with DRI)
2003-10-02Axe more old gamma DMA infrastructure.Eric Anholt1-22/+0
2003-08-29Add DRM(calloc), which is convenient, used by the new sis code, and takesEric Anholt1-0/+1
advantage of M_ZERO on BSDs.
2003-08-19- Remove $FreeBSD$ tags as they weren't too useful and merges are now beingEric Anholt1-1/+1
done through perforce. - Add copyright headers to drm_os_*bsd.h, still need to research the other copyright-less files better.
2003-07-29IRQ code cleanup suggested by Linus TorvaldsMichel Daenzer1-1/+1
i830 build fix
2003-07-25Compile fixes for recent 2.5/2.6 Linux kernels. I hope this doesn't breakMichel Daenzer1-1/+1
the i830 driver or the BSDs. :)
2003-05-16Support AGP bridges where the AGP aperture can't be accessed directly byMichel Daenzer1-3/+3
the CPU (David Mosberger, Benjamin Herrenschmidt, myself, Paul Mackerras, Jeff Wiedemeier)
2003-04-26Add PCI DMA memory functions and make addbufs_pci and associated code useEric Anholt1-1/+8
it. To do this we need to save the bus address along with the virtual address in the seglist. Also fix some error handling and a few bits of whitespace.
2003-04-26Move the memory functions with debugging info to drm_memory_debug.h, andEric Anholt1-3/+0
remove a couple of dead functions.
2003-04-25Merge from FreeBSD-current.FreeBSD-20030424Eric Anholt1-1/+1
2003-04-24Remove more gamma DMA infrastructure. Most of this code was copied straightEric Anholt1-48/+0
from linux, so it could be added back if some driver needed it in the future.
2003-04-24Remove more gamma DMA code. This isn't all of it, but it's a major portion.Eric Anholt1-18/+1
2003-04-24Move some common code from addbufs_<type> to addbufs. Make buf_alloc beEric Anholt1-5/+2
protected by the count_lock and make it non-atomic.
2003-04-24Remove the ioctl_count variable from the device. A reference is held to theEric Anholt1-1/+0
fp throughout the ioctl syscall, so the device can't be closed out from under us.
2003-04-24Remove a bunch of dead code and fix spelling of a couple of comments.Eric Anholt1-43/+1
2003-04-24Move one definition to drm_drv.h and remove the rest of drm_init.h whichEric Anholt1-2/+0
was all unused.
2003-04-24Remove DRM_DMA_HISTOGRAM and associated code.Eric Anholt1-41/+0
2003-04-24Make DRM(read) and DRM(poll) stubs and remove DRM(write) andEric Anholt1-11/+0
DRM(write_string). This is the first part of removing much of the support code for gamma from the BSD DRM, since it appears that no new drivers are using it and nobody has ever shown interest in gamma on BSD.
2003-03-29Remove dead vma code and remove the unused devstate struct definition.Eric Anholt1-28/+14
2003-03-29Add DRMFILE definitions and supply filp for BSD in theEric Anholt1-4/+81
post-drm-filp-0-1-branch world. The filp is a void * cast from the current pid. This is a temporary solution which maintains the status quo until a proper solution is implemented. What is really needed is a unique pointer per open, hopefully with a device private area. This can be done in FreeBSD for all entry points except mmap, but is difficult (sys/dev/streams/streams.c is an example). I have partially completed code for this but have not had time to debug, so this is a temporary fix.
2003-03-11Merge back from FreeBSD-current, adding FreeBSD ID tags to aid futureX_4_3_0-20020324-preimportEric Anholt1-1/+1
merging. Also includes an update to radeon PCI IDs.
2003-03-06Remove the vbl signal code because it's untested (and has lock issues onEric Anholt1-0/+3
-current).
2003-02-21Merge from bsd-4-0-0-branch.bsd-4-0-0-20030221-mergeEric Anholt1-10/+23
2002-12-06Add vblank signal code for BSD DRM. Untested so far, but working with aEric Anholt1-0/+11
4.2.0 userland at least.
2002-10-29Use bus_alloc_resource/bus_release_resource more properly: save the ridEric Anholt1-0/+1
returned by alloc.
2002-09-26BSD vblank framework.Eric Anholt1-0/+10
2002-07-05merged bsd-3-0-0-branchbsd-3-0-0-20020705-mergeAlan Hourihane1-33/+31
2002-03-06first pass at merging mesa 4.0 kernel drivers into new bsd-3-0-0 branch.Alan Hourihane1-0/+4
2002-01-27First pass merge of XFree86 4.2.0 import.X_4_2_0-20020128-mergeDavid Dawes1-413/+310
2001-04-09First pass of XFree86 4.0.99.2 merge.X_4_0_99_2-20010410-mergeDavid Dawes1-10/+22
2000-07-10Import of XFree86 4.0.1X_4_0_1Alan Hourihane1-1/+1
2000-06-13Merged bsd-1-0-1pre401-20000613-freezebsd-1-0-1-20000613-mergeDoug Rabson1-5/+20
2000-05-30Merged bsd-1-0-0bsd-1-0-0-20000531-mergeDoug Rabson1-0/+708