aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/gpu/drm/nouveau/nvd0_display.c
Commit message (Collapse)AuthorAge
* drm/nouveau: port remainder of drm code, and rip out compat layerBen Skeggs2012-10-02
| | | | | | | | v2: Ben Skeggs <bskeggs@redhat.com> - fill in nouveau_pm.dev to prevent oops - fix ppc issues (build + OF shadow) Signed-off-by: Ben Skeggs <bskeggs@redhat.com>
* drm/nouveau: start culling unused codeBen Skeggs2012-10-02
| | | | Signed-off-by: Ben Skeggs <bskeggs@redhat.com>
* drm/nouveau: port all engines to new engine module formatBen Skeggs2012-10-02
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This is a HUGE commit, but it's not nearly as bad as it looks - any problems can be isolated to a particular chipset and engine combination. It was simply too difficult to port each one at a time, the compat layers are *already* ridiculous. Most of the changes here are simply to the glue, the process for each of the engine modules was to start with a standard skeleton and copy+paste the old code into the appropriate places, fixing up variable names etc as needed. v2: Marcin Slusarz <marcin.slusarz@gmail.com> - fix find/replace bug in license header v3: Ben Skeggs <bskeggs@redhat.com> - bump indirect pushbuf size to 8KiB, 4KiB barely enough for userspace and left no space for kernel's requirements during GEM pushbuf submission. - fix duplicate assignments noticed by clang v4: Marcin Slusarz <marcin.slusarz@gmail.com> - add sparse annotations to nv04_fifo_pause/nv04_fifo_start - use ioread32_native/iowrite32_native for fifo control registers v5: Ben Skeggs <bskeggs@redhat.com> - rebase on v3.6-rc4, modified to keep copy engine fix intact - nv10/fence: unmap fence bo before destroying - fixed fermi regression when using nvidia gr fuc - fixed typo in supported dma_mask checking Signed-off-by: Ben Skeggs <bskeggs@redhat.com>
* drm/nouveau/pageflip: kick flip handling out of engsw and into fenceBen Skeggs2012-10-02
| | | | | | | | | | This is all very much a policy thing, and hence will not belong in SW after the rework. engsw now only handles receiving the event to say "can flip now" and makes a callback to perform the actual work. Signed-off-by: Ben Skeggs <bskeggs@redhat.com>
* drm/nouveau/instmem: completely new implementation, as a subdev moduleBen Skeggs2012-10-02
| | | | | | | | v2 (Ben Skeggs): - some fixes for 64KiB PAGE_SIZE - fix porting issues in (currently unused) nv41/nv44 pciegart code Signed-off-by: Ben Skeggs <bskeggs@redhat.com>
* drm/nouveau/fb: merge fb/vram and port to subdev interfacesBen Skeggs2012-10-02
| | | | Signed-off-by: Ben Skeggs <bskeggs@redhat.com>
* drm/nouveau: implement devinit subdev, and new init table parserBen Skeggs2012-10-02
| | | | | | | v2: - make sure not to execute display scripts unless resuming Signed-off-by: Ben Skeggs <bskeggs@redhat.com>
* drm/nvd0/disp: hopefully fix selection of 6/8bpc mode on DP outputsBen Skeggs2012-08-30
| | | | | | | | | | | I have a very limited number of traces available for DP on NVD9+, but, these values produce the same as the binary driver on a confirmed 18-bit eDP panel and a confirmed 24-bit eDP panel (Retina MBP). It's interesting that the bitfield values also match the MODE_CTRL values that control the same thing on nv50:nvd9. Signed-off-by: Ben Skeggs <bskeggs@redhat.com>
* drm/nvd0/disp: mask off high 16 bit of negative cursor x-coordinateChristoph Bumiller2012-08-13
| | | | | | Signed-off-by: Christoph Bumiller <e0425955@student.tuwien.ac.at> Signed-off-by: Ben Skeggs <bskeggs@redhat.com> Cc: stable@vger.kernel.org
* drm: Make the .mode_fixup() operations mode argument a const pointerLaurent Pinchart2012-07-19
| | | | | | | | The passed mode must not be modified by the operation, make it const. Signed-off-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com> Reviewed-by: Alex Deucher <alexander.deucher@amd.com> Signed-off-by: Dave Airlie <airlied@redhat.com>
* drm/nouveau: move flip-related channel setup to software engineBen Skeggs2012-05-24
| | | | Signed-off-by: Ben Skeggs <bskeggs@redhat.com>
* drm/nvd0/disp: remove unnecessary sync from flip_nextBen Skeggs2012-05-24
| | | | | | | | | | This shouldn't be necessary, I believe this is just a bit of missed debug code that got left over somehow. Causes flips to be always synced to vblank, regardless of swap interval, which we don't want.. Signed-off-by: Ben Skeggs <bskeggs@redhat.com>
* drm/nouveau: use the same packet header macros as userspaceBen Skeggs2012-05-24
| | | | | | Cosmetic cleanup only. Signed-off-by: Ben Skeggs <bskeggs@redhat.com>
* nouveau: add PRIME supportDave Airlie2012-05-23
| | | | | | | | | | | | This adds prime->fd and fd->prime support to nouveau, it passes the SG object to TTM, and then populates the GART entries using it. v2: add stubbed kmap + use new function to fill out pages array for faulting + add reimport test. Reviewed-by: Alex Deucher <alexander.deucher@amd.com> Signed-off-by: Dave Airlie <airlied@redhat.com>
* drm/nouveau/dp: support version 4.0 of DP tableBen Skeggs2012-03-22
| | | | Signed-off-by: Ben Skeggs <bskeggs@redhat.com>
* drm/nve0/disp: nvidia randomly decided to move the dithering methodBen Skeggs2012-03-22
| | | | Signed-off-by: Ben Skeggs <bskeggs@redhat.com>
* drm/nvd0/disp: ignore clock set if no pclkBen Skeggs2012-03-22
| | | | | | | | | This happens somehow during init on a machine I have, and leads to a divide-by-zero. Lets avoid that... Signed-off-by: Ben Skeggs <bskeggs@redhat.com>
* drm/nouveau: remove subchannel names from places where it doesn't matterBen Skeggs2012-03-22
| | | | | | These are FIFO methods, it doesn't matter what subchannel is being used. Signed-off-by: Ben Skeggs <bskeggs@redhat.com>
* drm/nvd0/disp: disconnect encoders before reprogramming themBen Skeggs2012-03-13
| | | | Signed-off-by: Ben Skeggs <bskeggs@redhat.com>
* drm/nvd0/disp: move syncs/magic setup to or mode_setBen Skeggs2012-03-13
| | | | | | | | | | NVIDIA appear to do these around the same place they do the MODE_CTRL methods, and for DP at least we need to bash some extra bits in "syncs" to keep EVO happy. It's a bit of a guess as to the 6/8bpc, but i have no better idea yet. Signed-off-by: Ben Skeggs <bskeggs@redhat.com>
* drm/nvd0/disp: fix dcb sor link matching in supervisor handlerBen Skeggs2012-03-13
| | | | Signed-off-by: Ben Skeggs <bskeggs@redhat.com>
* drm/nvd0/disp: initial implementation of displayportBen Skeggs2012-03-13
| | | | Signed-off-by: Ben Skeggs <bskeggs@redhat.com>
* drm/nvd0/disp: attempt to handle more than 2 crtcs if possibleBen Skeggs2012-03-13
| | | | | | | Theoretically handles CRTC2/CRTC3, should any GF119 out there actually have them enabled. The room is there for the regs etc, so why not :) Signed-off-by: Ben Skeggs <bskeggs@redhat.com>
* drm/nouveau/disp: parse connector info directly in nouveau_connector.cBen Skeggs2011-12-21
| | | | | | | | | | | | Another case where we parsed vbios data to some structs, then again use that info once to construct another set of data. Skip the intermediate step. This is also slightly improved in that we can now use DCB 3.x connector table info, which will allow NV4x to gain hotplug support, and to make quirks for SPWG LVDS panels unnecessary. Signed-off-by: Ben Skeggs <bskeggs@redhat.com>
* drm/nvd0/disp: use single, shared, sync bo for all evo channelsBen Skeggs2011-12-21
| | | | | | This simplifies some things, and hopefully won't come back to bite me. Signed-off-by: Ben Skeggs <bskeggs@redhat.com>
* drm/nvd0/disp: rename sync channel to flip channelBen Skeggs2011-12-21
| | | | Signed-off-by: Ben Skeggs <bskeggs@redhat.com>
* drm/nvd0/disp: handle yet another interruptBen Skeggs2011-12-21
| | | | | | | | | | | | | | Spotted while messing with overlay channels (probably as a result of sending a similar "disable" sequence as we do for the flip channels). The value in 0x61008c was 0x20, which one would reasonably guess is "bit 5 == something to report about evo channel 5" - but who knows. Spotted the binary driver getting this too, and it appears to not do anything exciting as a result. So, handle it the same way and avoid an IRQ storm. Signed-off-by: Ben Skeggs <bskeggs@redhat.com>
* drm/nvd0/disp: initialise overlay channelsBen Skeggs2011-12-21
| | | | Signed-off-by: Ben Skeggs <bskeggs@redhat.com>
* drm/nvd0/disp: add support for page flippingBen Skeggs2011-12-21
| | | | Signed-off-by: Ben Skeggs <bskeggs@redhat.com>
* drm/nvd0/disp: make it clearer that the cursor regs are pio evo channelsBen Skeggs2011-12-21
| | | | Signed-off-by: Ben Skeggs <bskeggs@redhat.com>
* drm/nvd0/disp: have evo names now, use themBen Skeggs2011-12-21
| | | | Signed-off-by: Ben Skeggs <bskeggs@redhat.com>
* drm/nvd0/disp: init display sync channelsBen Skeggs2011-12-21
| | | | Signed-off-by: Ben Skeggs <bskeggs@redhat.com>
* drm/nvd0/disp: scaler updates, overscan compensation etcBen Skeggs2011-12-21
| | | | Signed-off-by: Ben Skeggs <bskeggs@redhat.com>
* drm/nvd0/disp: update crtc timing calculations for interlace/doublescanBen Skeggs2011-12-21
| | | | Signed-off-by: Ben Skeggs <bskeggs@redhat.com>
* drm/nouveau/disp: introduce proper init/fini, separate from create/destroyBen Skeggs2011-12-21
| | | | Signed-off-by: Ben Skeggs <bskeggs@redhat.com>
* drm/nvd0/disp: enable hdmi audioBen Skeggs2011-12-21
| | | | Signed-off-by: Ben Skeggs <bskeggs@redhat.com>
* drm/nvd0/disp: hook evo up to debuggingBen Skeggs2011-12-21
| | | | Signed-off-by: Ben Skeggs <bskeggs@redhat.com>
* drm/nvd0/disp: enable hdmi on sor if hdmi monitor presentBen Skeggs2011-12-21
| | | | Signed-off-by: Ben Skeggs <bskeggs@redhat.com>
* drm/nvd0/disp: send eld to the audio codecBen Skeggs2011-12-21
| | | | Signed-off-by: Ben Skeggs <bskeggs@redhat.com>
* drm/nouveau: improve dithering properties, and implement proper auto modeBen Skeggs2011-12-21
| | | | Signed-off-by: Ben Skeggs <bskeggs@redhat.com>
* drm/nouveau: no need to pass parameters into set_scale/ditherBen Skeggs2011-12-21
| | | | Signed-off-by: Ben Skeggs <bskeggs@redhat.com>
* drm/nvd0/disp: fix sor dpms typo, preventing dpms on in some situationsBen Skeggs2011-11-30
| | | | Signed-off-by: Ben Skeggs <bskeggs@redhat.com>
* drm/nvd9/disp: bail out of mode_set_base if no fb bound to crtcBen Skeggs2011-09-20
| | | | Signed-off-by: Ben Skeggs <bskeggs@redhat.com>
* drm/nvd9/disp: stub some more api hooks so we don't oops on resumeBen Skeggs2011-09-20
| | | | Signed-off-by: Ben Skeggs <bskeggs@redhat.com>
* drm/nvd0/disp: tidy up what we have so farBen Skeggs2011-09-20
| | | | Signed-off-by: Ben Skeggs <bskeggs@redhat.com>
* drm/nvd0/disp: rewrite irq handler, should be somewhat sturdier nowBen Skeggs2011-09-20
| | | | Signed-off-by: Ben Skeggs <bskeggs@redhat.com>
* drm/nvd0/disp: do modeset irq handling from taskletBen Skeggs2011-09-20
| | | | Signed-off-by: Ben Skeggs <bskeggs@redhat.com>
* drm/nvd0/disp: untested LVDS supportBen Skeggs2011-09-20
| | | | Signed-off-by: Ben Skeggs <bskeggs@redhat.com>
* drm/nvd0/disp: track down fb positioning methodBen Skeggs2011-09-20
| | | | Signed-off-by: Ben Skeggs <bskeggs@redhat.com>
* drm/nvd0/disp: determine U table config in or_mode_set()Ben Skeggs2011-09-20
| | | | | | | Takes a gamble and presumes that we can safely store something random in OR_MODE_CTRL+4, the hw doesn't seem to mind... Signed-off-by: Ben Skeggs <bskeggs@redhat.com>