summaryrefslogtreecommitdiff
path: root/bsd-core/r128_drv.c
AgeCommit message (Collapse)Author
2009-02-27Move vblank_init to driver load time.Robert Noland
2008-10-10[FreeBSD] Rework all of the memory allocationsRobert Noland
Allocate memory from different pools. This allows the OS to track memory allocations for us, much like the linux memory debugging. This will ease tracking down memory leaks since the OS can track the number of allocations from each pool and help to point us in the right direction. Also replace drm_alloc and friends with static __inline__ versions while we are here.
2008-10-03[FreeBSD] Don't explicitly bzero driver softc.Robert Noland
This is already handled for us. Suggested by John Baldwin
2008-10-03[FreeBSD] Use M_WAITOK when allocating driver memory.Robert Noland
We don't explicitly check for error here and M_WAITOK will just put the process to sleep waiting on resources to become available. Suggested by John Baldwin
2008-09-10Remove incomplete and obsolete free/net/open code.vehemens
Signed-off-by: Robert Noland <rnoland@2hip.net>
2008-09-08[FreeBSD] We need to call drm_detach before we free dev->driver.Robert Noland
The driver is in control of the show, so when you try and unload a module the driver detach routine is called first. It is what drives the whole unload process and so lots of panics occur if dev->driver is already free.
2008-09-05Need M_NOWAIT for malloc.vehemens
Signed-off-by: Robert Noland <rnoland@2hip.net>
2008-08-29[FreeBSD] Use driver features macros and flagsvehemens
Signed-off-by: Robert Noland <rnoland@2hip.net>
2008-08-29[FreeBSD] Convert drm_driver to a pointer like linux.vehemens
Signed-off-by: Robert Noland <rnoland@2hip.net>
2008-05-27[FreeBSD] Add vblank-rework support and get drivers building.Robert Noland
The i915 driver now works again.
2008-05-27[FreeBSD] Convert from drm_device_t to struct drm_device for consistency.Eric Anholt
2005-12-30Merge patch from jhb to catch up with FreeBSD-current vgapci master deviceEric Anholt
changes.
2005-11-11Fix breakage from the move of driver ioctl externs to header files.Eric Anholt
2005-08-05Rename the driver hooks in the DRM to something a little moreEric Anholt
understandable: preinit -> load postinit -> (removed) presetup -> firstopen postsetup -> (removed) open_helper -> open prerelease -> preclose free_filp_priv -> postclose pretakedown -> lastclose postcleanup -> unload release -> reclaim_buffers_locked version -> (removed) postinit and version were replaced with generic code in the Linux DRM (drivers now set their version numbers and description in the driver structure, like on BSD). postsetup wasn't used at all. Fixes the savage hooks for initializing and tearing down mappings at the right times. Testing involved at least starting X, running glxgears, killing glxgears, exiting X, and repeating. Tested on: FreeBSD (g200, g400, r200, r128) Linux (r200, savage4)
2005-06-06Add a few more bits of Tonnerre's NetBSD port (Still need to deal with theEric Anholt
device attachment).
2005-04-16Use /*- to begin license blocks in BSD code to reduce diffs against FreeBSDEric Anholt
CVS.
2004-11-06Convert more drivers for bsd-core, moving the ioctl definitions to sharedEric Anholt
code. Remove the "drv" from sisdrv, as it's unnecessary. Use the drm_pci functions in i915 instead of per-os implementations of the same. Avoid whitespace within fields in drm_pciids.txt (one of the r300 definitions), since it breaks the bsd pciids script. Tested on sis, mga, r128. i915 needs more work.
2004-11-06Remove some core stuff that ended up being unnecessary.Eric Anholt
2004-11-06Get r128 basically working: Hook up the driver's dma ioctl, use the properEric Anholt
offset into the driver ioctl array, and don't make the ctx bitmap conditional.
2004-11-06Connect up r128_ioctls in driver config.Eric Anholt
2004-11-06Commit WIP of BSD conversion to core model. Compiles for r128, radeon, butEric Anholt
doesn't run yet. Moves the ioctl definitions for these two drivers back to the shared code -- they aren't OS-specific.
2003-10-17- Move IRQ functions from drm_dma.h to new drm_irq.h and disentangle themEric Anholt
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 Anholt
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-08-19- Remove $FreeBSD$ tags as they weren't too useful and merges are now beingEric Anholt
done through perforce. - Add copyright headers to drm_os_*bsd.h, still need to research the other copyright-less files better.
2003-04-26Add PCI DMA memory functions and make addbufs_pci and associated code useEric Anholt
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-25Merge from FreeBSD-current.Eric Anholt
2003-04-24Move one definition to drm_drv.h and remove the rest of drm_init.h whichEric Anholt
was all unused.
2003-03-25XFree86 4.3.0 mergeAlan Hourihane
2003-03-11Merge back from FreeBSD-current, adding FreeBSD ID tags to aid futureEric Anholt
merging. Also includes an update to radeon PCI IDs.
2003-02-21Merge from bsd-4-0-0-branch.Eric Anholt
2002-07-05merged bsd-3-0-0-branchAlan Hourihane