summaryrefslogtreecommitdiffstats
path: root/drivers/gpu/drm/nouveau/nv10_graph.c
Commit message (Collapse)AuthorAgeFilesLines
* drm/nouveau: restructure source tree, split core from drm implementationBen Skeggs2012-10-031-1189/+0
| | | | | | | | | | | | | | Future work will be headed in the way of separating the policy supplied by the nouveau drm module from the mechanisms provided by the driver core. There will be a couple of major classes (subdev, engine) of driver modules that have clearly defined tasks, and the further directory structure change is to reflect this. No code changes here whatsoever, aside from fixing up a couple of include file pathnames. Signed-off-by: Ben Skeggs <bskeggs@redhat.com>
* drm/nouveau/fifo: turn all fifo modules into engine modulesBen Skeggs2012-05-241-5/+4
| | | | | | | | | | | | | Been tested on each major revision that's relevant here, but I'm sure there are still bugs waiting to be ironed out. This is a *very* invasive change. There's a couple of pieces left that I don't like much (eg. other engines using fifo_priv for the channel count), but that's an artefact of there being a master channel list still. This is changing, slowly. Signed-off-by: Ben Skeggs <bskeggs@redhat.com>
* drm/nouveau: create real execution engine for software object classBen Skeggs2012-05-241-4/+0
| | | | | | | | | | | Just a cleanup more or less, and to remove the need for special handling of software objects. This removes a heap of documentation on dma/graph object formats. The info is very out of date with our current understanding, and is far better documented in rnndb in envytools git. Signed-off-by: Ben Skeggs <bskeggs@redhat.com>
* drm/nouveau/gr: disable fifo access and idle before suspend ctx unloadBen Skeggs2011-07-251-0/+5
| | | | Signed-off-by: Ben Skeggs <bskeggs@redhat.com>
* drm/nouveau: pass flag to engine fini() method on suspendBen Skeggs2011-07-251-1/+1
| | | | | | | | It may not be necessary to fail in certain cases (such as failing to idle) on module unload, whereas on suspend it's important to ensure a consistent state can be restored on resume. Signed-off-by: Ben Skeggs <bskeggs@redhat.com>
* drm/nouveau: replace nv04_graph_fifo_access() use with direct reg bashingBen Skeggs2011-07-251-4/+4
| | | | Signed-off-by: Ben Skeggs <bskeggs@redhat.com>
* drm/nouveau: move set_tile_region to nouveau_exec_engineBen Skeggs2011-05-161-1/+2
| | | | | | | In the very least VPE (PMPEG and friends) also has this style of tile region regs, lets make them just work if/when they get added. Signed-off-by: Ben Skeggs <bskeggs@redhat.com>
* drm/nv10/gr: move to exec engine interfacesBen Skeggs2011-05-161-96/+110
| | | | | | Like nv20-nv50, needs cleanup. Signed-off-by: Ben Skeggs <bskeggs@redhat.com>
* drm/nouveau: Fix brace placement checkpatch.pl errors.Emil Velikov2011-05-161-2/+1
| | | | | | | | Fix 'ERROR: that open brace { should be on the previous line' Fix 'ERROR: else should follow close brace }' Signed-off-by: Emil Velikov <emil.l.velikov@gmail.com> Signed-off-by: Francisco Jerez <currojerez@riseup.net>
* drm/nv04-nv10: Don't re-enable FIFO access multiple times after IRQ dispatch.Francisco Jerez2010-12-081-12/+0
| | | | | | | | | nvxx_graph_isr is already taking care of it. In some cases this could've made you miss PGRAPH interrupts (e.g. when you were supposed to get several IRQs of the same kind in a row). Signed-off-by: Francisco Jerez <currojerez@riseup.net> Signed-off-by: Ben Skeggs <bskeggs@redhat.com>
* drm/nouveau: tidy+move PGRAPH ISRs to their respective *_graph.c filesBen Skeggs2010-12-031-2/+70
| | | | | Reviewed-by: Francisco Jerez <currojerez@riseup.net> Signed-off-by: Ben Skeggs <bskeggs@redhat.com>
* drm/nouveau: Rework tile region handling.Francisco Jerez2010-12-031-10/+7
| | | | | | | | | The point is to share more code between the PFB/PGRAPH tile region hooks, and give the hardware specific functions a chance to allocate per-region resources. Signed-off-by: Francisco Jerez <currojerez@riseup.net> Signed-off-by: Ben Skeggs <bskeggs@redhat.com>
* drm/nouveau: Implement the pageflip ioctl.Francisco Jerez2010-12-031-0/+4
| | | | | | | nv0x-nv4x should be mostly fine, nv50 doesn't work yet. Signed-off-by: Francisco Jerez <currojerez@riseup.net> Signed-off-by: Ben Skeggs <bskeggs@redhat.com>
* drm/nv10: fix thinko and let nv17 do 3d again :)Ben Skeggs2010-12-031-1/+1
| | | | Signed-off-by: Ben Skeggs <bskeggs@redhat.com>
* drm/nouveau: only expose the object classes that are supported by the chipsetBen Skeggs2010-12-031-37/+55
| | | | | | | We previously added all the available classes for the entire generation, even though the objects wouldn't work on the hardware. Signed-off-by: Ben Skeggs <bskeggs@redhat.com>
* drm/nouveau: use object class structs more extensivelyBen Skeggs2010-12-031-0/+1
| | | | | | | The structs themselves, as well as the non-sw object creation function are probably very misnamed now. That's a problem for later :) Signed-off-by: Ben Skeggs <bskeggs@redhat.com>
* drm/nouveau: store engine type in gpuobj class structsBen Skeggs2010-12-031-20/+20
| | | | | | We will eventually want to address hw engines other than PGRAPH. Signed-off-by: Ben Skeggs <bskeggs@redhat.com>
* drm/nouveau: Refactor context destruction to avoid a lock ordering issue.Francisco Jerez2010-12-031-0/+15
| | | | | | | | | | | | | | | | The destroy_context() engine hooks call gpuobj management functions to release the channel resources, these functions use HARDIRQ-unsafe locks whereas destroy_context() is called with the HARDIRQ-safe context_switch_lock held, that's a lock ordering violation. Push the engine-specific channel destruction logic into destroy_context() and let the hardware-specific code lock and unlock when it's actually needed. Change the engine destruction order to avoid a race in the small gap between pgraph and pfifo context uninitialization. Reported-by: Marcin Slusarz <marcin.slusarz@gmail.com> Signed-off-by: Francisco Jerez <currojerez@riseup.net> Signed-off-by: Ben Skeggs <bskeggs@redhat.com>
* drm/nouveau: add more fine-grained locking to channel list + structuresBen Skeggs2010-12-031-2/+2
| | | | Signed-off-by: Ben Skeggs <bskeggs@redhat.com>
* drm/nv10: Don't oops if the card wants to switch to a channel with no grctx.Francisco Jerez2010-09-241-1/+1
| | | | | Signed-off-by: Francisco Jerez <currojerez@riseup.net> Signed-off-by: Ben Skeggs <bskeggs@redhat.com>
* drm/nv10: Fix up switching of NV10TCL_DMA_VTXBUF.Francisco Jerez2010-08-061-50/+125
| | | | | | | Not very nice, but I don't think there's a simpler workaround. Signed-off-by: Francisco Jerez <currojerez@riseup.net> Signed-off-by: Ben Skeggs <bskeggs@redhat.com>
* drm/nouveau: Pre-G80 tiling support.Francisco Jerez2010-01-111-11/+17
| | | | Signed-off-by: Francisco Jerez <currojerez@riseup.net>
* drm/nv10: Add the initial graph context and soft methods needed for LMA.Francisco Jerez2009-12-161-43/+154
| | | | | Signed-off-by: Francisco Jerez <currojerez@riseup.net> Signed-off-by: Ben Skeggs <bskeggs@redhat.com>
* drm/nouveau: Add DRM driver for NVIDIA GPUsBen Skeggs2009-12-111-0/+892
This adds a drm/kms staging non-API stable driver for GPUs from NVIDIA. This driver is a KMS-based driver and requires a compatible nouveau userspace libdrm and nouveau X.org driver. This driver requires firmware files not available in this kernel tree, interested parties can find them via the nouveau project git archive. This driver is reverse engineered, and is in no way supported by nVidia. Support for nearly the complete range of nvidia hw from nv04->g80 (nv50) is available, and the kms driver should support driving nearly all output types (displayport is under development still) along with supporting suspend/resume. This work is all from the upstream nouveau project found at nouveau.freedesktop.org. The original authors list from nouveau git tree is: Anssi Hannula <anssi.hannula@iki.fi> Ben Skeggs <bskeggs@redhat.com> Francisco Jerez <currojerez@riseup.net> Maarten Maathuis <madman2003@gmail.com> Marcin Koƛcielnicki <koriakin@0x04.net> Matthew Garrett <mjg@redhat.com> Matt Parnell <mparnell@gmail.com> Patrice Mandin <patmandin@gmail.com> Pekka Paalanen <pq@iki.fi> Xavier Chantry <shiningxc@gmail.com> along with project founder Stephane Marchesin <marchesin@icps.u-strasbg.fr> Signed-off-by: Ben Skeggs <bskeggs@redhat.com> Signed-off-by: Dave Airlie <airlied@redhat.com>