aboutsummaryrefslogtreecommitdiff
path: root/drivers/gpu
AgeCommit message (Collapse)AuthorFilesLines
2010-04-20drm/vmwgfx: add support for new TTM fault callback V5Jerome Glisse1-3/+41
This add the support for the new fault callback, does change anything from driver point of view. Improvement: store the aperture base in a variable so that we don't call a function to get it on each fault. Patch hasn't been tested. V2 don't derefence bo->mem.mm_node as it's not NULL only for VRAM or GTT V3 update after io_mem_reserve/io_mem_free callback balancing V4 callback has to ioremap V5 ioremap is done by TTM Signed-off-by: Jerome Glisse <[email protected]> Reviewed-by: Thomas Hellstrom <[email protected]> Signed-off-by: Dave Airlie <[email protected]>
2010-04-20drm/nouveau/kms: add support for new TTM fault callback V5Jerome Glisse1-4/+54
This add the support for the new fault callback, does change anything from driver point of view, thought it should allow nouveau to add support for unmappable VRAM. Improvement: store the aperture base in a variable so that we don't call a function to get it on each fault. Patch hasn't been tested on any hw. V2 don't derefence bo->mem.mm_node as it's not NULL only for VRAM or GTT V3 update after io_mem_reserve/io_mem_free callback balancing V4 callback has to ioremap V5 ioremap is done by ttm Signed-off-by: Jerome Glisse <[email protected]> Signed-off-by: Dave Airlie <[email protected]>
2010-04-20drm/radeon/kms: add support for new fault callback V7Jerome Glisse3-7/+72
This add the support for the new fault callback and also the infrastructure for supporting unmappable VRAM. V2 validate BO with no_wait = true V3 don't derefence bo->mem.mm_node as it's not NULL only for VRAM or GTT V4 update to splitted no_wait ttm change V5 update to new balanced io_mem_reserve/free change V6 callback is responsible for iomapping memory V7 move back iomapping to ttm Signed-off-by: Jerome Glisse <[email protected]> Signed-off-by: Dave Airlie <[email protected]>
2010-04-20drm/ttm: ttm_fault callback to allow driver to handle bo placement V6Jerome Glisse3-84/+88
On fault the driver is given the opportunity to perform any operation it sees fit in order to place the buffer into a CPU visible area of memory. This patch doesn't break TTM users, nouveau, vmwgfx and radeon should keep working properly. Future patch will take advantage of this infrastructure and remove the old path from TTM once driver are converted. V2 return VM_FAULT_NOPAGE if callback return -EBUSY or -ERESTARTSYS V3 balance io_mem_reserve and io_mem_free call, fault_reserve_notify is responsible to perform any necessary task for mapping to succeed V4 minor cleanup, atomic_t -> bool as member is protected by reserve mecanism from concurent access V5 the callback is now responsible for iomapping the bo and providing a virtual address this simplify TTM and will allow to get rid of TTM_MEMTYPE_FLAG_NEEDS_IOREMAP V6 use the bus addr data to decide to ioremap or this isn't needed but we don't necesarily need to ioremap in the callback but still allow driver to use static mapping Signed-off-by: Jerome Glisse <[email protected]> Reviewed-by: Thomas Hellstrom <[email protected]> Signed-off-by: Dave Airlie <[email protected]>
2010-04-20drm/i915: drop pointer to drm_gem_objectDaniel Vetter6-26/+23
Luckily the change is quite a little bit less invasive than I've feared. Signed-off-by: Daniel Vetter <[email protected]> Acked-by: Eric Anholt <[email protected]> Signed-off-by: Dave Airlie <[email protected]>
2010-04-20drm/i915: don't use ->driver_private anymoreDaniel Vetter2-2/+2
Thanks to the to_intel_bo helper, this change is rather trivial. Signed-off-by: Daniel Vetter <[email protected]> Acked-by: Eric Anholt <[email protected]> Signed-off-by: Dave Airlie <[email protected]>
2010-04-20drm/i915: embed the gem object into drm_i915_gem_objectDaniel Vetter2-29/+30
Just embed it and adjust the pointers, No other changes (that's for later patches). Signed-off-by: Daniel Vetter <[email protected]> Acked-by: Eric Anholt <[email protected]> Signed-off-by: Dave Airlie <[email protected]>
2010-04-20drm/i915: introduce i915_gem_alloc_objectDaniel Vetter5-6/+14
Just preparation, no functional change. Signed-off-by: Daniel Vetter <[email protected]> Acked-by: Eric Anholt <[email protected]> Signed-off-by: Dave Airlie <[email protected]>
2010-04-20drm: free core gem object from driver callbacksDaniel Vetter4-7/+12
When drivers embed the core gem object into their own structures, they'll have to do this. Temporarily this results in an ugly kfree(gem_obj); in every gem driver. Signed-off-by: Daniel Vetter <[email protected]> Acked-by: Eric Anholt <[email protected]> Signed-off-by: Dave Airlie <[email protected]>
2010-04-20drm: extract drm_gem_object_initDaniel Vetter1-10/+29
This function can be used by drivers who allocate the drm gem object on their own. No functional change in here, just preparation. Signed-off-by: Daniel Vetter <[email protected]> Acked-by: Eric Anholt <[email protected]> Signed-off-by: Dave Airlie <[email protected]>
2010-04-20Merge branch 'drm-radeon-evergreen-accel' into drm-core-nextDave Airlie10-84/+2218
* drm-radeon-evergreen-accel: drm/radeon: fix cypress firmware typo. drm/radeon/kms/evergreen: add hpd support drm/radeon/kms/evergreen: implement irq support drm/radeon/kms/evergreen: setup and enable the CP drm/radeon/kms/evergreen: implement gfx init drm/radeon/kms/evergreen: add soft reset function drm/radeon/kms/evergreen: add gart support drm/radeon/kms: add support for evergreen power tables drm/radeon/kms: update atombios.h power tables for evergreen
2010-04-20Merge branch 'drm-fbdev-cleanup' into drm-core-nextDave Airlie30-1162/+1237
* drm-fbdev-cleanup: drm/fb: remove drm_fb_helper_setcolreg drm/kms/fb: use slow work mechanism for normal hotplug also. drm/kms/fb: add polling support for when nothing is connected. drm/kms/fb: provide a 1024x768 fbcon if no outputs found. drm/kms/fb: separate fbdev connector list from core drm connectors drm/kms/fb: move to using fb helper crtc grouping instead of core crtc list drm/fb: fix fbdev object model + cleanup properly. Conflicts: drivers/gpu/drm/i915/i915_drv.h drivers/gpu/drm/nouveau/nouveau_drv.h
2010-04-20Merge branch 'drm-radeon-lockup' into drm-core-nextDave Airlie23-474/+802
* drm-radeon-lockup: drm/radeon/kms: simplify & improve GPU reset V2 drm/radeon/kms: rename gpu_reset to asic_reset drm/radeon/kms: fence cleanup + more reliable GPU lockup detection V4 Conflicts: drivers/gpu/drm/radeon/r300.c
2010-04-20Merge branch 'drm-edid-fixes' into drm-core-nextDave Airlie5-289/+622
* drm-edid-fixes: drm/edid: When checking duplicate standard modes, walked the probed list drm/edid: Fix sync polarity for secondary GTF curve drm/modes: Fix interlaced mode names drm/edid: Add secondary GTF curve support drm/edid: Strengthen the algorithm for standard mode codes drm/edid: Fix the HDTV hack. drm/edid: Extend range-based mode addition for EDID 1.4 drm/edid: Add test for monitor reduced blanking support. drm/edid: Fix preferred mode parse for EDID 1.4 drm/edid: Remove some silly comments drm/edid: Remove arbitrary EDID extension limit drm/edid: Add modes for Established Timings III section drm/edid: Reshuffle mode list construction to closer match the spec drm/edid: Remove a redundant check drm/edid: Remove some misleading comments drm/edid: Fix secondary block fetch.
2010-04-20Merge branch 'drm-ttm-pool' into drm-core-nextDave Airlie6-28/+886
* drm-ttm-pool: drm/ttm: using kmalloc/kfree requires including slab.h drm/ttm: include linux/seq_file.h for seq_printf drm/ttm: Add sysfs interface to control pool allocator. drm/ttm: Use set_pages_array_wc instead of set_memory_wc. arch/x86: Add array variants for setting memory to wc caching. drm/nouveau: Add ttm page pool debugfs file. drm/radeon/kms: Add ttm page pool debugfs file. drm/ttm: Add debugfs output entry to pool allocator. drm/ttm: add pool wc/uc page allocator V3
2010-04-20Merge remote branch 'anholt/drm-intel-next' of /home/airlied/kernel/drm-next ↵Dave Airlie23-1485/+1775
into drm-core-next * 'anholt/drm-intel-next' of /home/airlied/kernel/drm-next: (48 commits) agp/intel-gtt: kill previous_size assignments agp/intel-gtt: kill intel_i830_tlbflush agp/intel: split out gmch/gtt probe, part 1 agp/intel: kill mutli_gmch_chip agp/intel: uncoditionally reconfigure driver on resume agp/intel: split out the GTT support agp/intel: introduce intel-agp.h header file drm/i915: Don't touch PORT_HOTPLUG_EN in intel_dp_detect() drm/i915/pch: Use minimal number of FDI lanes (v2) drm/i915: Add the support of memory self-refresh on Ironlake drm/i915: Move Pineview CxSR and watermark code into update_wm hook. drm/i915: Only save/restore FBC on the platform that supports FBC drm/i915: Fix the incorrect argument for SDVO SET_TV_format command drm/i915: Add support of SDVO on Ibexpeak PCH drm/i915: Don't enable pipe/plane/VCO early (wait for DPMS on). drm/i915: do not read uninitialized ->dev_private Revert "drm/i915: Use a dmi quirk to skip a broken SDVO TV output." drm/i915: implement multifunction SDVO device support drm/i915: remove unused intel_pipe_get_connector() drm/i915: remove connector object in old output structure ...
2010-04-19Merge branch 'drm-linus' of ↵Linus Torvalds17-19/+138
git://git.kernel.org/pub/scm/linux/kernel/git/airlied/drm-2.6 * 'drm-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/airlied/drm-2.6: drm/radeon/kms: add FireMV 2400 PCI ID. drm/radeon/kms: allow R500 regs VAP_ALT_NUM_VERTICES and VAP_INDEX_OFFSET drivers/gpu/radeon: Add MSPOS regs to safe list. drm/radeon/kms: disable the tv encoder when tv/cv is not in use drm/radeon/kms: adjust pll settings for tv drm/radeon/kms: fix tv dac conflict resolver drm/radeon/kms/evergreen: don't enable hdmi audio stuff drm/radeon/kms/atom: fix dual-link DVI on DCE3.2/4.0 drm/radeon/kms: fix rs600 tlb flush drm/radeon/kms: print GPU family and device id when loading drm/radeon/kms: fix calculation of mipmapped 3D texture sizes drm/radeon/kms: only change mode when coherent value changes. drm/radeon/kms: more atom parser fixes (v2)
2010-04-19drm/radeon/kms: allow R500 regs VAP_ALT_NUM_VERTICES and VAP_INDEX_OFFSETMarek Olšák5-6/+20
[airlied: fix V_A_N_V to not be safe and fix check to make sure only r500 - bump userspace version] Signed-off-by: Marek Olšák <[email protected]> Signed-off-by: Dave Airlie <[email protected]>
2010-04-19drivers/gpu/radeon: Add MSPOS regs to safe list.Corbin Simpson4-0/+8
Permits MSAA and D3D-style rasterization. [airlied: add rs600] Signed-off-by: Corbin Simpson <[email protected]> Signed-off-by: Dave Airlie <[email protected]>
2010-04-19drm/radeon/kms: disable the tv encoder when tv/cv is not in useAlex Deucher1-2/+6
Switching between TV and VGA caused VGA to break on some systems since the TV encoder was left enabled when VGA was used. fixes fdo bug 25520. Signed-off-by: Alex Deucher <[email protected]> Cc: stable <[email protected]> Signed-off-by: Dave Airlie <[email protected]>
2010-04-19drm/radeon/kms: adjust pll settings for tvAlex Deucher1-0/+4
May fix fdo bug 26582. Signed-off-by: Alex Deucher <[email protected]> Signed-off-by: Dave Airlie <[email protected]>
2010-04-19drm/radeon/kms: fix tv dac conflict resolverAlex Deucher1-0/+5
On systems with the tv dac shared between DVI and TV, we can only use the dac for one of the connectors. However, when using a digital monitor on the DVI port, you can use the dac for the TV connector just fine. Check the use_digital status when resolving the conflict. Fixes fdo bug 27649, possibly others. Signed-off-by: Alex Deucher <[email protected]> Cc: stable <[email protected]> Signed-off-by: Dave Airlie <[email protected]>
2010-04-19drm/radeon/kms/evergreen: don't enable hdmi audio stuffAlex Deucher2-1/+10
Signed-off-by: Alex Deucher <[email protected]> Signed-off-by: Dave Airlie <[email protected]>
2010-04-19drm/radeon/kms/atom: fix dual-link DVI on DCE3.2/4.0Alex Deucher1-0/+4
Got broken during the evergreen merge. Fixes fdo bug 27001. Signed-off-by: Alex Deucher <[email protected]> Signed-off-by: Dave Airlie <[email protected]>
2010-04-19drm/radeon/kms: fix rs600 tlb flushJerome Glisse1-1/+1
Typo in in flush leaded to no flush of the RS600 tlb which ultimately leaded to massive system ram corruption, with this patch everythings seems to work properly. Signed-off-by: Jerome Glisse <[email protected]> Cc: stable <[email protected]> Signed-off-by: Dave Airlie <[email protected]>
2010-04-19drm/radeon/kms: print GPU family and device id when loadingJerome Glisse2-2/+54
This will help figuring out GPU when looking at bugs log. Signed-off-by: Jerome Glisse <[email protected]> Signed-off-by: Dave Airlie <[email protected]>
2010-04-18drm/i915: fix tiling limits for i915 class hw v2Daniel Vetter3-14/+16
Current code is definitely crap: Largest pitch allowed spills into the TILING_Y bit of the fence registers ... :( I've rewritten the limits check under the assumption that 3rd gen hw has a 3d pitch limit of 8kb (like 2nd gen). This is supported by an otherwise totally misleading XXX comment. This bug mostly resulted in tiling-corrupted pixmaps because the kernel allowed too wide buffers to be tiled. Bug brought to the light by the xf86-video-intel 2.11 release because that unconditionally enabled tiling for pixmaps, relying on the kernel to check things. Tiling for the framebuffer was not affected because the ddx does some additional checks there ensure the buffer is within hw-limits. v2: Instead of computing the value that would be written into the hw fence registers and then checking the limits simply check whether the stride is above the 8kb limit. To better document the hw, add some WARN_ONs in i915_write_fence_reg like I've done for the i830 case (using the right limits). Signed-off-by: Daniel Vetter <[email protected]> Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=27449 Tested-by: Alexander Lam <[email protected]> Cc: [email protected] Signed-off-by: Eric Anholt <[email protected]>
2010-04-18drm/i915: Don't touch PORT_HOTPLUG_EN in intel_dp_detect()Karsten Wiese1-10/+0
PORT_HOTPLUG_EN has allready been setup in i915_driver_irq_postinstall(), when intel_dp_detect() runs. Delete the DP[BCD]_HOTPLUG_INT_EN defines, they are not referenced anymore. I found this while searching for a fix for https://bugzilla.redhat.com/show_bug.cgi?id=528312 Signed-off-by: Karsten Wiese <[email protected]> Signed-off-by: Eric Anholt <[email protected]>
2010-04-18drm/i915: set DIDL using the ACPI video output device _ADR method return.Zhang Rui1-4/+50
we used to set the DIDL in the output device detected order. But some BIOSes requires it to be initialized in the ACPI device order. e.g. the value of the first field in DIDL stands for the first ACPI video output device in ACPI namespace. Now we initialize the DIDL using the device id, i.e. _ADR return value, of each ACPI video device, if it is not 0. https://bugzilla.kernel.org/show_bug.cgi?id=15054 Signed-off-by: Zhang Rui <[email protected]> Signed-off-by: Eric Anholt <[email protected]>
2010-04-18drm/i915/pch: Use minimal number of FDI lanes (v2)Adam Jackson2-6/+21
This should be a small power savings. Tested on Lenovo T410 (Ironlake), LVDS VGA and DisplayPort, up to 1920x1200R. v2: Add Sandybridge support, fix obvious math error. Acked-by: Zhenyu Wang <[email protected]> Signed-off-by: Adam Jackson <[email protected]> Signed-off-by: Eric Anholt <[email protected]>
2010-04-18drm/i915: Fix 82854 PCI ID, and treat it like other 85XAdam Jackson2-3/+5
pci.ids and the datasheet both say it's 358e, not 35e8. Signed-off-by: Adam Jackson <[email protected]> Signed-off-by: Eric Anholt <[email protected]>
2010-04-18drm/i915: Attempt to fix watermark setup on 85x (v2)Adam Jackson1-5/+6
IS_MOBILE() catches 85x, so we'd always try to use the 9xx FIFO sizing; since there's an explicit 85x version, this seems wrong. v2: Handle 830m correctly too. Signed-off-by: Adam Jackson <[email protected]> Reviewed-by: Eric Anholt <[email protected]> Signed-off-by: Eric Anholt <[email protected]>
2010-04-17Merge branch 'for-linus' of ↵Linus Torvalds19-849/+871
git://git.kernel.org/pub/scm/linux/kernel/git/anholt/drm-intel * 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/anholt/drm-intel: drm/i915: Ignore LVDS EDID when it is unavailabe or invalid drm/i915: Add no_lvds entry for the Clientron U800 drm/i915: Rename many remaining uses of "output" to encoder or connector. drm/i915: Rename intel_output to intel_encoder. agp/intel: intel_845_driver is an agp driver! drm/i915: introduce to_intel_bo helper drm/i915: Disable FBC on 915GM and 945GM.
2010-04-12drm/i915: Add the support of memory self-refresh on IronlakeZhenyu Wang2-3/+201
Update the self-refresh watermark for display plane/cursor and enable the memory self-refresh on Ironlake. The watermark is also updated for the active display plane. More than 1W idle power is saved on one Ironlake laptop after enabling memory self-refresh. Signed-off-by: Zhao Yakui <[email protected]> Signed-off-by: Zhenyu Wang <[email protected]>
2010-04-12drm/i915: Move Pineview CxSR and watermark code into update_wm hook.Zhao Yakui2-74/+88
Previously, after setting up the Pineview CxSR state, i9xx_update_wm would get called and overwrite our state. BTW: We will disable the self-refresh and never enable it any more if we can't find the appropriate the latency on pineview plaftorm. In such case the update_wm callback will be NULL. The bitmask macro is also defined to access the corresponding fifo watermark register. Signed-off-by: Zhao Yakui <[email protected]> Signed-off-by: Zhenyu Wang <[email protected]>
2010-04-12drm/i915: Only save/restore FBC on the platform that supports FBCZhao Yakui1-19/+22
Signed-off-by: Zhao Yakui <[email protected]> Signed-off-by: Zhenyu Wang <[email protected]>
2010-04-12drm/i915: Fix the incorrect argument for SDVO SET_TV_format commandZhao Yakui1-1/+1
Otherwise it will cause that S-video output becomes black/white when switching to other TV format. http://bugs.freedesktop.org/show_bug.cgi?id=23916 Signed-off-by: Zhao Yakui <[email protected]> Tested-by: Arnold <[email protected]> Tested-by: Bazin <[email protected]> Tested-by: Nigel <[email protected]> Signed-off-by: Zhenyu Wang <[email protected]>
2010-04-12drm/i915: Add support of SDVO on Ibexpeak PCHZhao Yakui3-16/+36
SDVO on Ibexpeak PCH with Ironlake is multiplexed with HDMIB port, and only has SDVOB port. Signed-off-by: Zhao Yakui <[email protected]> Signed-off-by: Zhenyu Wang <[email protected]>
2010-04-12drm/i915: Don't enable pipe/plane/VCO early (wait for DPMS on).Carl Worth1-5/+0
The existing code handling the DPMS ON event is much more careful to ensure that these registers are enabled according to strict sequencing requirements. Enabling these early in mode_set simply defeats that. Signed-off-by: Carl Worth <[email protected]> Signed-off-by: Eric Anholt <[email protected]>
2010-04-12drm/i915: do not read uninitialized ->dev_privateLuca Tettamanti1-1/+1
->dev_private at that point is NULL and is initialied only a few lines later. Signed-off-by: Luca Tettamanti <[email protected]> Signed-off-by: Eric Anholt <[email protected]>
2010-04-12Revert "drm/i915: Use a dmi quirk to skip a broken SDVO TV output."Zhenyu Wang1-21/+1
This reverts commit 6070a4a928f8c92b9fae7d6717ebbb05f425d6b2. The quirk for this SDVO device on IBM specific board is just a hack in old code which showed the broken multifunction SDVO support in the driver. Multifunction SDVO patch provided the right fix for it. Signed-off-by: Zhenyu Wang <[email protected]>
2010-04-12drm/i915: implement multifunction SDVO device supportZhenyu Wang1-236/+375
With new intel_encoder/intel_connector structure change, each supported connector type on SDVO device will be created as a new 'intel_connector', and all attached to one 'intel_encoder' for its SDVO port. The SDVO encoder will handle SDVO protocol stuff, and each connector does its own part of work now, like detection is only to check if current active output is itself, etc. Update since last submit: - Fixed SDVO TV property creation failure by incorrect set target output call Signed-off-by: Zhenyu Wang <[email protected]>
2010-04-12drm/i915: remove unused intel_pipe_get_connector()Zhenyu Wang1-17/+0
Added by original eDP support patch, not used any more. Signed-off-by: Zhenyu Wang <[email protected]>
2010-04-12drm/i915: remove connector object in old output structureZhenyu Wang2-14/+0
As all display drivers have been converted, remove the left reference for connector object in old structure. Signed-off-by: Zhenyu Wang <[email protected]>
2010-04-12drm/i915: convert TV driver to new encoder/connector structureZhenyu Wang1-14/+26
Signed-off-by: Zhenyu Wang <[email protected]>
2010-04-12drm/i915: convert SDVO driver to new encoder/connector structureZhenyu Wang1-66/+94
Signed-off-by: Zhenyu Wang <[email protected]>
2010-04-12drm/i915: convert DVO driver to new encoder/connector structureZhenyu Wang1-36/+34
Also remove old UMS copied code for get_crtc. Signed-off-by: Zhenyu Wang <[email protected]> Signed-off-by: Eric Anholt <[email protected]>
2010-04-12drm/i915: convert DP/eDP driver to new encoder/connector structureZhenyu Wang2-31/+45
Signed-off-by: Zhenyu Wang <[email protected]> Signed-off-by: Eric Anholt <[email protected]>
2010-04-12drm/i915: convert HDMI driver to new encoder/connector structureZhenyu Wang1-12/+24
Signed-off-by: Zhenyu Wang <[email protected]> Signed-off-by: Eric Anholt <[email protected]>
2010-04-12drm/i915: convert LVDS driver to new encoder/connector structureZhenyu Wang1-11/+23
Signed-off-by: Zhenyu Wang <[email protected]> Signed-off-by: Eric Anholt <[email protected]>