Commit Graph

600 Commits (6677e2a10b820a5ccfd375cc627b8e41453a71da)

Author SHA1 Message Date
Alan Hourihane fc83d76e5a add i915_ioc32.c 2005-06-29 13:13:22 +00:00
Alan Hourihane 6496c5d1e7 silence warning 2005-06-29 13:00:29 +00:00
Dave Airlie 6975571c3b fix some warnings from cross compiler 2005-06-29 12:02:18 +00:00
Dave Airlie 62b55eb433 make r128/mga compile properly on sparc cross-compiler 2005-06-29 11:56:42 +00:00
Alan Hourihane 2b427bee9b Move to linux specific directory 2005-06-29 11:36:37 +00:00
Dave Airlie 964c57e71f add mga and r128 32/64 bits
This is Egberts code, ported to Pauls framework by me..
2005-06-29 11:22:39 +00:00
Dave Airlie ae7d8d8a85 these don't need reclaim buffers their release functions handle it 2005-06-29 03:06:47 +00:00
Dave Airlie 2ce5ddec83 Bug in conversion from old DRM to core DRM.... 2005-06-29 02:57:18 +00:00
Eric Anholt 5d96c74ff1 - Remove drm_initmap and replace its usage with drm_addmap. This reduces
code duplication, and it also hands you the map pointer so you don't
    need to re-find it.
- Remove the permanent maps flag. Instead, for register and framebuffer
    maps, we always check whether there's already a map of that type and
    offset around. Move the Radeon map initialization into presetup (first
    open) so it happens again after every takedown.
- Remove the split cleanup of maps between driver takedown (last close) and
    cleanup (module unload). Instead, always tear down maps on takedown,
    and drivers can recreate them on first open.
- Make MGA always use addmap, instead of allocating consistent memory in
    the PCI case and then faking up a map for it, which accomplished nearly
    the same thing, in a different order. Note that the maps are exposed to
    the user again: we may want to expose a flag to avoid this, but it's
    not a security concern, and saves us a lot of code.
- Remove rmmaps in the MGA driver. Since the function is only called during
    takedown anyway, we can let them die a natural death.
- Make removal of maps happen in one function, which is called by both
    drm_takedown and drm_rmmap_ioctl.
Reviewed by: idr (previous revision) Tested on: mga (old/new/pci dma),
    radeon, savage
2005-06-28 20:58:34 +00:00
Dave Airlie 6397722f19 add compat code from Paul Mackerras 2005-06-28 13:02:20 +00:00
Dave Airlie 827806f697 Add compat to Makefile 2005-06-28 12:52:41 +00:00
Dave Airlie 170bf94a36 Add drm and radeon 32/64-bit compat code from Paul Mackerras 2005-06-28 12:50:15 +00:00
Alan Hourihane b6b270a260 Given that BenH says using the sysdev approach for DRM is bogus, I'll yank
the code for it, rather than introducing something that isn't going to
    work 100% of the time.
2005-06-28 08:03:33 +00:00
Alan Hourihane 75ba453365 Comment out the .resume function as without programming their dependent
registers things tend to lock up in certain situations.
The BIOS repost will fix things up.
2005-06-28 07:34:49 +00:00
Alan Hourihane e2d76b0642 Reverse the pm_message_t patch for now, it appears that the 2.6.12 release
didn't have it.
2005-06-27 15:17:12 +00:00
Alan Hourihane 1a6780348c Check for 2.6.12 suspend/resume changes (pm_message_t) 2005-06-27 12:39:02 +00:00
Jon Smirl afdabdabf5 removed dev->sysdev_registered 2005-06-26 13:31:15 +00:00
Jon Smirl 9deb276a06 Ref count the sysdev class to support multiple DRM cards 2005-06-24 22:48:16 +00:00
Jon Smirl 2b845f25c5 Make sysdev class only register when fbdev detected 2005-06-24 21:50:40 +00:00
Jon Smirl 5b0e93de32 More err path clean up for drm_pm Add mandatory sysdev shutdown function 2005-06-24 19:31:06 +00:00
Alan Hourihane fe42d43a63 Fix the sysdev approach for power management.
We need to use the container_of() call to access our device private.
2005-06-24 09:28:50 +00:00
Jon Smirl 7586a655fc Fix drm_memory_debug.c to compile, doesn't seem to be working Clean up
error return path in drm_stub.c
2005-06-23 05:29:16 +00:00
Jon Smirl 4152605ea1 Get the power management hooks into the right place so that everything gets
freed correctly.
2005-06-22 05:49:56 +00:00
Jon Smirl ae2264d3c9 Remove I2C support from radeon driver. Same support is available from
radeonfb.
2005-06-19 04:15:58 +00:00
Dave Airlie 71df0eed34 fix up drm_alloc_agp to take a dev arg and not pass crappy agpgart around 2005-06-17 09:09:17 +00:00
Jon Smirl 0569fe7a52 Fix 810/830 build 2005-06-17 04:47:30 +00:00
Alan Hourihane 53e950b344 Force AGP always for Intel chipsets.
Fixes bug #3552
2005-06-16 19:58:00 +00:00
Ian Romanick 72cfc797b5 Adds support for PCI cards to MGA DRM
This patch adds serveral new ioctls and a new query to get_param query to
    support PCI MGA cards.
Two ioctls were added to implement interrupt based waiting. With this
    change, the client-side driver no longer needs to map the primary DMA
    region or the MMIO region. Previously, end-of-frame waiting was done by
    busy waiting in the client-side driver until one of the MMIO registers
    (the current DMA pointer) matched a pointer to the end of primary DMA
    space. By using interrupts, the busy waiting and the extra mappings are
    removed.
A third ioctl was added to bootstrap DMA. This ioctl, which is used by the
    X-server, moves a *LOT* of code from the X-server into the kernel. This
    allows the kernel to do whatever needs to be done to setup DMA buffers.
    The entire process and the locations of the buffers are hidden from
    user-mode.
Additionally, a get_param query was added to differentiate between G4x0
    cards and G550 cards. A gap was left in the numbering sequence so that,
    if needed, G450 cards could be distinguished from G400 cards. According
    to Ville Syrjälä, the G4x0 cards and the G550 cards handle
    anisotropic filtering differently. This seems the most compatible way
    to let the client-side driver know which card it's own. Doing this very
    small change now eliminates the need to bump the DRM minor version
    twice.
http://marc.theaimsgroup.com/?l=dri-devel&m=106625815319773&w=2
A number of ioctl handlers in linux-core were also modified so that they
    could be called in-kernel. In these cases, the in-kernel callable
    version kept the existing name (e.g., drm_agp_acquire) and the ioctl
    handler added _ioctl to the name (e.g., drm_agp_acquire_ioctl).
This patch also replaces the drm_agp_do_release function with
    drm_agp_release. drm_agp_release (drm_core_agp_release in the previous
    patch) is very similar to drm_agp_do_release, and I saw no reason to
    have both.
This commit *breaks the build* on BSD. Eric said that he would make the
    required updates to the BSD side soon.
Xorg bug: 3259 Reviewed by: Eric Anholt
2005-06-14 22:34:11 +00:00
Ian Romanick dfc650bd80 Completely re-initialize DMA settings
There were two problems. First, the 'warp' and 'primary' pointers weren't
    cleared, so mga_do_cleanup_dma, which gets called multiple times, would
    try to ioremapfree them multiple times. This resulted in the new error
    messages to syslog. The second problem was the, since the dev_private
    structure isn't reallocated and cleaned out in mga_do_init_dma, when
    the server is reloaded idle-waits would wait for impossible values.
I have given this patch some more riggorous testing. This includes:
- Load module, start server, run GL app, stop server, unload module.
- Load module, start server, run GL app, stop server, unload module, reload
    module, restart server, run GL app.
- Load module, start server, run GL app, stop server, restart server, run
    GL app, stop server, unload module.
In all three cases, everything worked as expected. Please let me know if
    there are any further regressions with this patch.
Xorg bug: 3408 Reported by: Chris Rankin
2005-06-09 21:18:56 +00:00
Jon Smirl 1252890ff1 drm_mem_init should be done at core load, not driver init 2005-06-09 13:22:12 +00:00
Alan Hourihane 246c617c87 Fix copyrights 2005-06-06 09:18:44 +00:00
Dave Airlie 805a07714f misc cleanup patch from Adrian Bunk 2005-06-04 06:18:11 +00:00
Eric Anholt 9cad6fb4e0 Bugzilla #3217: Create a new __drm_pci_free which is used internally in
linux-core to free pci memory without freeing the structure. Linux-core
    internals often create pci dma handle structures on the stack due to
    the lack of a drm_local_map_t to store them in properly. Fix the
    original drm_pci_free to actually free the dma handle structure instead
    of leaking it.
Signed-off-by: Sergey Vlasov <vsu@altlinux.ru>
2005-05-28 20:36:22 +00:00
Eric Anholt d7756397d6 Bugzilla #3217: The size field in the new dma handle structure was
uninitialized, and its use in drm_pci_free later resulted in panics.
Signed-off-by: Sergey Vlasov <vsu@altlinux.ru>
2005-05-28 20:25:04 +00:00
Alan Hourihane 54fbf85125 Actually check for drm_fb_loaded before trying to initialize the sysdev
approach.
2005-05-28 00:08:53 +00:00
Alan Hourihane 45f1db8db9 Re-implement the power management.
There's two choices when fb is or isn't loaded as we treat ourselves as a
    PCI driver in the latter case.
If we are a PCI driver, then register the suspend/resume functions
    directly. If not, then we register as a sysdev and pick up the
    suspend/resume actions and pump them down into a generic *power
    function.
It'll be nice when this little mess is sorted out with regard to being a
    real PCI driver ;-/
2005-05-28 00:00:08 +00:00
Ian Romanick 4a84416c45 Modify drm_driver::device_is_agp to return a tri-state value to indicate
that a device absolutely is, absolutely is not, or may or may not be
    AGP. Modify the i915 DRM to use this to force all i9x5 devices to be
    "AGP" (even the PCI-e devices).
Reported by: Lukas Hejtmanek
2005-05-27 23:42:11 +00:00
Ian Romanick a686be5bc8 Change the MGA initialization and cleanup a bit. The dev_private structure
is now allocated (and partially filled in) by the new
    mga_driver_preinit function.
This allows the driver to detect the type of card (i.e., G200 class vs.
    G400 class) on its own. The chipset value passed to mga_dma_init is now
    ignored. This same technique is used by the radeon DRM.
As a result of this, mga_driver_pretakedown was converted to
    mga_driver_postcleanup. This routine gets called in some other places
    than might be expected, and it sets the dev_private pointer to NULL.
    That little gem took over an hour to track down. :(
2005-05-21 02:27:51 +00:00
Ian Romanick fced784140 Refactor common, boilerplate ioctl code from drm_addbufs_* functions into
drm_addbufs. This makes the code more like the BSD code, and makes the
    drm_addbufs_* functions callable in-kernel.
Reviewed by: Dave Airlie
2005-05-20 00:17:40 +00:00
Felix Kuehling 6d4b9a830b Savage doesn't require AGP any more. Enable build even without CONFIG_AGP. 2005-05-17 02:08:02 +00:00
Ian Romanick e051cd19c0 Added device_is_agp callback to drm_driver. This function is called by the
platform-specific drm_device_is_agp function. Added implementation of
    this function the the Linux-specific portion of the MGA driver to
    detect PCI G450 cards. Added code to the Linux-specific portion of the
    generic DRM layer to not initialize AGP infrastructure if the card is
    not AGP (this matches what already existed in BSD).
Bumped the driver date and the driver patch-level for MGA.
This mostly fixes bugzilla #3248. The BSD side still needs an
    implementation of mga_driver_device_is_agp.
2005-05-16 17:37:10 +00:00
Eric Anholt ec111d70fe Convert BSD code to mostly use bus_dma, the dma abstraction for dealing
with IOMMUs and such. There is one usage of the forbidden vtophys()
    left in drm_scatter.c which will be fixed up soon. This required a KPI
    change for drm_pci_alloc/free() to return/use a drm_dma_handle_t that
    keeps track of os-specific bits, rather than just passing around the
    vaddr/busaddr/size.
Submitted by: Tonnerre Lombard (partially) Tested on: FreeBSD: Rage128
    AGP/PCI Linux: Savage4 AGP/PCI
2005-04-26 05:19:11 +00:00
Thomas Hellstrom 699d4ad53a A fix for a locking bug which is triggered when a client tries to lock with
flag DMA_QUIESCENT (typically the X server), but gets interrupted by a
    signal. The locking IOCTL should then return an error, but if
    DMA_QUIESCENT succeeds it returns 0, and the client falsely thinks it
    has the lock. In addition The client waits for DMA_QUISCENT and
    possibly DMA_READY without having the lock.
2005-04-20 18:50:49 +00:00
Dave Airlie b0c461c8e3 Revert last commit, it affect via things 2005-04-19 00:31:16 +00:00
Adam Jackson 0a5e02c7b5 Add skeletal imagine driver (but don't build it yet). 2005-03-29 01:47:38 +00:00
Thomas Hellstrom 532ccb98b5 Via updates:
New PCI command parser. Moved from via_dma.c to via_verifier.c so functions
    with similar functionality are close to eachother.
Moved video related functions to via_video.c, which might be extended in
    the future, as new video functionality is added.
New device-specific generic IRQ IOCTL, similar to the general VBLANK IOCTL,
    but with support for multiple device IRQ sources and functionality.
Support for Unichrome Pro PM800/CN400 video DMA commands in verifier and
    PCI parser.
Support for Unichrome Pro PM800/CN400 HQV IRQs in the new generic IRQ
    IOCTL.
Bumped minor. New version 2.6.0.
2005-03-28 21:21:42 +00:00
Dave Airlie c6161eff86 Description: Rather than use custom code in DRM_WAIT_ON() to do exactly
what wait_event_interruptible_timeout() does, use the function and just
    change the return values appropriately.
Signed-off-by: Nishanth Aravamudan <nacc@us.ibm.com>
2005-03-27 07:05:28 +00:00
Dave Airlie 385f927692 Some ia64 platforms may not support write combining on all type of memory,
so we need to consult the EFI memory map before we try to set the write
    combine attribute of a page. This patch will try to map a page write
    combined if it's not an AGP page and the EFI memory map says it's ok,
    otherwise it falls back to a regular, uncached mapping. Can someone
    please apply this to the drm tree?
From: Jesse Barnes
2005-03-27 06:58:12 +00:00
Dave Airlie 956a701544 fix up AGP multi-head support for kernel 2.6.12 2005-03-25 09:48:34 +00:00
Dave Airlie 2ad8387428 verify_area is deprecated, replaced by access_ok. Seems I missed this one
when I did the big overall conversion.
Signed-off-by: Jesper Juhl <juhl-lkml@dif.dk>
2005-03-25 09:47:36 +00:00
Dave Airlie ca04fbc7ba fix bug with XFree86 4.3 on core drm
Signed-off-by: Dave Airlie <airlied@linux.ie>
2005-03-25 09:05:10 +00:00
Dave Airlie c8d2d5d419 3dfx DRM depends on PCI
Signed-off-by: Geert Uytterhoeven <geert@linux-m68k.org>
2005-03-25 09:02:20 +00:00
Dave Airlie df6ef4836e For 2.6.12 and 2.6.11.x:
Remove incorrect "drm_"-prefix from parameter description.
Signed-off-by: Magnus Damm <damm@opensource.se>
2005-03-25 09:01:27 +00:00
Dave Airlie 7d3c42b589 Fix for bug 2673 from Egbert Eich - memset the version 2005-03-08 23:47:11 +00:00
Eric Anholt 81459d6e50 Close a race which could allow for privilege escalation by users with DRI
privileges on Radeon hardware. Essentially, a malicious program could
    submit a packet containing an offset (possibly in main memory) to be
    rendered from/to, while a separate thread switched that offset in
    userspace rapidly between a valid value and an invalid one.
    radeon_check_and_fixup_offset() would pull the offset in from user
    space, check it, and spit it back out to user space to be copied in
    later by the emit code. It would sometimes catch the bad value, but
    sometimes the malicious program could modify it after the check and get
    an invalid offset rendered from/to.
Fix this by allocating a temporary buffer and copying the data in at once.
    While here, make the cliprects stuff not do the VERIFYAREA_READ and
    COPY_FROM_USER_UNCHECKED gymnastics, avoiding a lock order reversal on
    FreeBSD. Performance impact is negligible -- no difference on r200 to
    ~1% improvement on rv200 in quake3 tests (P4 1Ghz, demofour at
    1024x768, n=4 or 5).
2005-02-08 04:17:14 +00:00
Dave Airlie dc4defe742 Invalid bound check of driver defined ioctls in drm_ioctl
Bug 2489 Reporter: Aapo Tahkola <aet@rasterburn.org>
2005-02-07 22:55:54 +00:00
Dave Airlie 03ddea5b27 change DRIVER_ to CORE_ makes things look nicer, also change it so the
driver name is marked on resource allocations
2005-02-07 11:20:43 +00:00
Dave Airlie 300e0866d6 fix agp detection on linux 2005-02-07 10:44:28 +00:00
Eric Anholt 080a547d4d - Implement drm_initmap, and extend it with the resource number to help
FreeBSD. Add drm_get_resource_{start|len} so linux-specific stuff
    doesn't need to be in shared code.
- Fix mach64 build by using __DECONST to work around passing a const
    pointer to useracc, which is unfortunately not marked const.
- Get rid of a lot of maplist code by not having dev->maplist be a pointer,
    and by sticking the link entries directly in drm_local_map_t rather
    than having a separate structure for the linked list.
- Factor out map uninit and removal into its own routine, rather than
    duplicating in both drm_takedown() and drm_rmmap().
- Hook up more driver functions, and correct FreeBSD-specific bits of
    radeon_cp.c, making radeon work.
- Baby steps towards using bus_space as we should.
2005-02-05 08:00:14 +00:00
Dave Airlie 1dd948f280 make functions static in i915, remove unused functions 2005-02-01 10:43:42 +00:00
Dave Airlie 62e0a58ecf update i830 similiar to the kernel, add statics 2005-02-01 10:33:51 +00:00
Dave Airlie 8d4c731aa1 make more functions static in i810 and fix pageflip cleanup 2005-02-01 10:18:27 +00:00
Dave Airlie 41cbbb47af fix radeon drv 2005-01-29 23:05:35 +00:00
Dave Airlie 311da0f212 hopefully fix drm_core setversion ioctl... pointed out by Eric on irc 2005-01-24 01:05:07 +00:00
Alan Hourihane 9620a0b8bb Fix cut & paste problem 2005-01-19 10:03:33 +00:00
Dave Airlie 37318f1675 remove duplicate drm_sysfs.o 2005-01-16 07:49:55 +00:00
Dave Airlie 354dd17d25 The patch makes drmAddBufs/drmMapBufs can handle buffers in video memory
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>
2005-01-16 05:40:12 +00:00
Felix Kuehling ffc51f1f32 Setup MTRRs for frame buffer and aperture manually on Savage3D and
Savage4-based cards. Automatic setup in drm_initmap doesn't work due to
    the weird alignment and size of the aperture.
2005-01-15 16:55:01 +00:00
Felix Kuehling d4a8f16eb6 Use virt_to_page instead of vmalloc_to_page in drm_do_vm_shm_nopage for
consistent pages allocated with drm_pci_alloc.
2005-01-12 16:07:49 +00:00
Jon Smirl 6e38fd3576 Adjust 4 level page check for <= 2.6.10 2005-01-09 17:30:44 +00:00
Thomas Hellstrom fb6a4d0a7d via updates: moved the verifier state struct to dev_priv. Implemented AGP
alignment check.
2005-01-07 11:37:01 +00:00
Jon Smirl c6c7496ca0 Adjust drm-memory for 4 level page tables in 2.6.10 ifdef'd to use 3 levels
in kernels older than 2.6.10
2005-01-06 17:09:22 +00:00
Felix Kuehling 04842e8bcf Completeley rewritten Savage DRM which can be considered secure (modulo
implementation errors). Direct hardware (MMIO, BCI) access is no longer
    needed in the Mesa driver. Bumped version to 2.0.0. Corresponding
    changes to the DDX and Mesa drivers are being committed.
2005-01-01 20:22:58 +00:00
Felix Kuehling ed165a2529 Added a new DRM map type _DRM_CONSISTENT for consistent PCI memory. It uses
drm_pci_alloc/free for allocating/freeing the memory. Only implemented
    in the Linux DRM so far.
2005-01-01 20:03:15 +00:00
Dave Airlie fe4ade81bb i810/i830 bug with Jon's file operations changes 2005-01-01 12:07:51 +00:00
Dave Airlie b4782ba76b Use wbinvd macro instead of assembly for it,
From: Stefan Dirsch <sndirsch@suse.de> Signed-off-by: Dave Airlie
    <airlied@linux.ie>
2004-12-10 11:53:24 +00:00
Thomas Hellstrom 98d01f9542 Patch from Jon Smirl from Nov. 2nd that makes older X servers behave well
with linux-core. Without this, they will fail on their second
    invocation since the drm already has a busID assigned.
Submitted by: Jon Smirl
2004-12-07 12:18:47 +00:00
Thomas Hellstrom 267e064527 Added 3D functionality to the via command verifier. Modified the via
ring-buffer code somewhat to workaround hardware problems. Bumped via
    minor version number.
2004-12-03 23:03:36 +00:00
Dave Airlie f0a86288fa patch from bug 1803 - will try and push to kernel soon 2004-11-11 11:09:11 +00:00
Jon Smirl 4b4df875b2 Fix more build problems on linux-core 2004-11-09 16:58:02 +00:00
Jon Smirl 76b1a7f2b4 make linux-core build again 2004-11-09 03:36:06 +00:00
Eric Anholt cb5aaa8987 Convert more drivers for bsd-core, moving the ioctl definitions to shared
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-06 23:02:07 +00:00
Jon Smirl 000c8eb18e Fix Linux build. Why won't this complile? extern int const foo; static
struct drm_driver driver = { .var = foo }; error says foo is not
    constant
2004-11-06 16:41:24 +00:00
Eric Anholt c9202c8965 Commit WIP of BSD conversion to core model. Compiles for r128, radeon, but
doesn't run yet. Moves the ioctl definitions for these two drivers back
    to the shared code -- they aren't OS-specific.
2004-11-06 01:41:47 +00:00
Jon Smirl 39a23640b2 Move ati_pcigart shared routines into drm-core module 2004-11-05 17:29:14 +00:00
Felix Kuehling 5128542814 Allow drivers to override reclaim_buffers in an OS-independent way by
passing drm_device_t* as first parameter, like in the BSD version.
2004-10-31 15:16:44 +00:00
Jon Smirl 816a291709 Switch SPIN_LOCK_UNLOCKED to spin_lock_init() 2004-10-29 17:09:54 +00:00
Jon Smirl c611cb9f17 Add include of moduleparam.h 2004-10-29 14:38:07 +00:00
Jon Smirl b974e2cd68 Break poll() to make it match the Xserver's broken expectations. 2004-10-28 15:52:31 +00:00
Jon Smirl b37efdadca Round 2 of getting rid of inter_module_get() 2004-10-23 18:12:34 +00:00
Jon Smirl 43cbf43a5f Revert symbol_get() changes from drm_drv 2004-10-23 14:43:06 +00:00
Dave Airlie 4b29f85768 fix inter module put/get 2004-10-23 14:00:53 +00:00
Dave Airlie 1473556e06 actually 2.6.10 introduced pfn range so it should work now.. 2004-10-23 07:02:29 +00:00
Dave Airlie 182a0e5dac fix pfn vs page for older kernels (2.6.9-rc kernels many not work..) 2004-10-23 06:59:15 +00:00
Jon Smirl 9ea6fe7aa6 Prepare to eliminate inter_module_get("agp") 2004-10-23 04:21:27 +00:00
Jon Smirl ad87dd8427 Bring in patch from kernel for remap_pfn_range 2004-10-22 16:03:21 +00:00
Jon Smirl d76f734f68 Fix up the radeon i2c error handing 2004-10-21 16:58:28 +00:00
Jon Smirl 17ce33835a Don't release an i2c channel that has not initialized correctly 2004-10-20 16:23:42 +00:00
Jon Smirl 7ebbebf3d3 Switch linux-core from using dev->pdev->driver->name to
dev->driver->pci_driver.name. This avoids the stealth mode case where
    pdev is pointing to the wrong driver or no driver.
2004-10-20 05:11:49 +00:00
Jon Smirl 5ae6c5af75 Fix dd vs di version typo in drm_setversion 2004-10-20 04:41:38 +00:00
Jon Smirl 157a814be6 Add a protective check against a possible buffer overflow 2004-10-19 18:18:02 +00:00
Jon Smirl bcfbd73536 Fix missing I2C busses to be non-fatal error. 2004-10-19 16:30:02 +00:00
Jon Smirl ca1ec9268f drm-core, Clean up bug error path on stealth mode exit 2004-10-19 02:50:14 +00:00
Jose Fonseca 0d89b19325 Update Doxygen configuration & comments. 2004-10-18 14:16:41 +00:00
Jon Smirl a8b2c94c18 Remove drm_init.c 2004-10-15 20:37:01 +00:00
Jon Smirl 91aa32742c Move drm_cpu_valid out of drm_init. drm_init is empty now. 2004-10-15 20:36:15 +00:00
Jon Smirl fa50e2b513 Switch linux-core over to 2.6 parameter model to enable debug use
drm_debug=1
2004-10-15 02:59:35 +00:00
Jon Smirl 5e8838fd11 Add a poll function that alternates between zero and normal poll return to
bring DRM into conformance with normal poll().
2004-10-13 16:40:53 +00:00
Jon Smirl ad70dc676e Breakout heads into their own data structures. 2004-10-12 03:59:17 +00:00
Jon Smirl ad549c5ae6 Rename fn_tbl to driver. Core driver now uses pci_driver name which
reflects the personality name.
2004-10-10 22:54:55 +00:00
Dave Airlie efcb9fb7ae fix up whitespacing in Kconfig 2004-10-09 11:16:20 +00:00
Dave Airlie e09229d6c8 remove unused dma remnants that were gamma only - these could cause an oops
on via
2004-10-09 10:58:19 +00:00
Jon Smirl 3981f17227 Fix refcount bug in stealth mode 2004-10-08 14:31:25 +00:00
Jon Smirl 61d36f6179 Revert back to drm_order() instead of using kernel get_order(). The
functions are not identical.
2004-10-06 16:27:55 +00:00
Dave Airlie 4dbc1e8728 Patch for Kconfig for making i830/i915 not build together 2004-10-05 12:12:01 +00:00
Jon Smirl 6dee8401a6 enable the device in the right order, remove __devinit from drm_int 2004-10-05 02:58:14 +00:00
Jon Smirl e17abf5d5d Make the debug memory functions compile for the core model. 2004-09-30 23:47:45 +00:00
Jon Smirl a36a6a291d Remove DRM() macros from core ffb driver. DaveA says he'll make it compile
someday.
2004-09-30 21:27:59 +00:00
Jon Smirl 9f9a8f1382 Lindent of core build. Drivers checked for no binary diffs. A few files
weren't Lindent's because their comments didn't convert very well. A
    bunch of other minor clean up with no code implact included.
2004-09-30 21:12:10 +00:00
Jon Smirl 368493edc9 savage.h not used in core builds 2004-09-30 21:06:53 +00:00
Jon Smirl e1d74a9899 core ffb.h is not used anymore 2004-09-30 20:46:59 +00:00
Jon Smirl b3d70ad6a7 Remove unused drm_module.h 2004-09-30 20:25:13 +00:00
Jon Smirl 1c0a437fa2 Move things around to reduce public symbols and even out files. Switch to
get_order from drm_order.
2004-09-30 19:26:35 +00:00
Jon Smirl 3aef3841d0 Make fops per driver instead of global, remove default flush, poll, read
functions
2004-09-30 18:13:33 +00:00
Jon Smirl 0bff0d9eb6 Getting the AGP module is a global resource. Make sure a dual PCI/AGP
driver doesn't release it on unload since an AGP driver may also be
    loaded.
2004-09-28 22:25:06 +00:00
Jon Smirl 6d6526fdf9 core needs three new files 2004-09-27 19:53:51 +00:00
Jon Smirl fa6b1d129e First check in for DRM that splits core from personality modules 2004-09-27 19:51:38 +00:00
Jon Smirl 77fa7b9548 Flip the 2.4 check so that it looks for 2.6 instead. This will allow builds
where we can't determine the version through.
2004-09-27 15:42:48 +00:00
Jon Smirl 1d6392f1fd Makefile reminder to build in 2.6 when on 2.6 2004-09-24 04:21:21 +00:00
Jon Smirl 74f063fc9d Create new linux-2.6 build. Move all gpl files into the 2.6 build. If you
edit files for 2.6 be sure and break the link to the 2.4 directory and
    copy the cvs history.
2004-09-24 03:12:17 +00:00
Jon Smirl 36a257cfe9 Remove 2.6 code that allow DRM major device number to be shared. We can add
it back later if needed. Checked DRM on both 2.4 and
2.6 to ensure that it builds and runs.
2004-09-23 17:22:27 +00:00
Jon Smirl 55c5e24089 Add new sysfs support files 2004-09-23 05:40:05 +00:00
Jon Smirl c158a36c4c 1) switches from class_sysfs to drm sysfs implementation to allow
customization
2) compiles again on 2.4, but doesn't work
2004-09-23 05:39:15 +00:00
Felix Kuehling af326f6f0c Create permanent maps of framebuffer, aperture and MMIO registers. Added
chipset-type information in driver data field of Savage PCI-IDs. Added
    missing PCI-ID 0x8d03 (ProSavageDDR on Pentium boards). Don't require
    AGP.
2004-09-22 22:51:18 +00:00
Jon Smirl 27fc998f7d Remove hotplug reset support from DRM driver. This will be handled by the
VGA driver when it gets written.
2004-09-22 19:13:02 +00:00
Jon Smirl 2ad068005a Make DRM permanent maps match broken X behavior. X is mapping regions that
are both smaller and larger than what the hardware supports. If DRM
    tries to fix these requests X will fail.
2004-09-21 05:13:21 +00:00
Jon Smirl 6f31c42fe9 Remove size restriction on permanent addmap 2004-09-20 19:23:27 +00:00
Jon Smirl 59cc1d8256 Felix's fix for map request smaller than permanent map size 2004-09-20 17:09:26 +00:00
Dave Airlie 5654880eee remove HAVE_COUNTERS 2004-09-20 11:29:16 +00:00
Dave Airlie fa75a81c9a another fix after the macro stuff 2004-09-20 10:45:53 +00:00
Jon Smirl c15b1d15ff Fix from: Nishanth Aravamudan replace direct assignment with
__set_current_state()
2004-09-18 16:44:43 +00:00
Jon Smirl 0c6fb0fbe1 Add linux sysfs i2c support to radeon driver. This patch adds GPL licensed
files to the linux build but not to the BSD directories.
2004-09-17 04:02:28 +00:00
Jon Smirl c7c9d3ef7b Let's try adding the dyn-minor patch again. This patch will reuse minor
numbers if a card is hotplugged in/out instead of just having them
    increase.
2004-09-16 18:42:03 +00:00
Jon Smirl 5dfd89ae0a Fix drm_scatter to properly report it's availability 2004-09-16 14:32:17 +00:00
Jon Smirl eeb0ef1a70 Back dyn-minor patch out for now. fops handling is broken on some cards 2004-09-15 17:44:30 +00:00
Jon Smirl 941d2cf431 Don't use module_param if it isn't defined in older kernels. 2004-09-15 16:06:50 +00:00
Jon Smirl 64ef12c55c Dynamic device minor support. Minor device numbers will be reused if the
device is hotplugged in/out of the system
2004-09-15 00:20:21 +00:00
Jon Smirl 13cb3f1b00 Fix error path in probe() to release resources if there is an error. 2004-09-12 19:24:08 +00:00
Jon Smirl 15407efd46 Make the comment match the code 2004-09-12 03:30:30 +00:00
Jon Smirl 36050cc958 Fix DRM to compile cleanly with recent kernel changes in PCI IO and
DRM_COPY_FROM_USER. PCI IO changes in 2.6.9-rc1 bk currently.
2004-09-12 03:23:50 +00:00