aboutsummaryrefslogtreecommitdiff
path: root/drivers/gpu/drm/vmwgfx
AgeCommit message (Collapse)AuthorFilesLines
2010-10-06drm/vmwgfx: Bump minor and driver dateThomas Hellstrom1-2/+2
Signed-off-by: Thomas Hellstrom <[email protected]> Signed-off-by: Dave Airlie <[email protected]>
2010-10-06drm/vmwgfx: Save at least one screen layoutThomas Hellstrom1-0/+3
Save at least one screen layout during vga save to avoid odd things happening during restore. Signed-off-by: Thomas Hellstrom <[email protected]> Signed-off-by: Dave Airlie <[email protected]>
2010-10-06drm/vmwgfx: Add modinfo versionThomas Hellstrom1-0/+4
Signed-off-by: Thomas Hellstrom <[email protected]> Signed-off-by: Dave Airlie <[email protected]>
2010-10-06drm/vmwgfx: Add a parameter to get the max fb sizeThomas Hellstrom2-2/+5
This can be used by the X server to restrict mode resolutions and size of root pixmap. Bump minor to announce this availability. Bump driver date. Signed-off-by: Thomas Hellstrom <[email protected]> Signed-off-by: Dave Airlie <[email protected]>
2010-10-06drm/vmwgfx: Don't flush fb if we're in the suspended state.Thomas Hellstrom1-0/+3
Signed-off-by: Thomas Hellstrom <[email protected]> Signed-off-by: Dave Airlie <[email protected]>
2010-10-06drm/vmwgfx: Prune modes based on available VRAM sizeThomas Hellstrom4-11/+38
This needs to be reviewed once we support screen objects and don't rely on VRAM for the frame-buffer. Also fix some integer overflow issues pointed out by Michel Daenzer. Signed-off-by: Thomas Hellstrom <[email protected]> Signed-off-by: Dave Airlie <[email protected]>
2010-10-06drm/vmwgfx: Take the ttm lock around the dirty ioctlThomas Hellstrom3-8/+84
This makes sure noone accesses the fifo while it's taken down using the dirty ioctl. Also make sure all workqueues are idled before the fifo is taken down. Signed-off-by: Thomas Hellstrom <[email protected]> Signed-off-by: Dave Airlie <[email protected]>
2010-10-06drm: vmwgfx: Add a struct drm_file parameter to the dirty framebuffer callbackThomas Hellstrom1-0/+2
This is needed for the callback to identify the caller and take appropriate locks if needed. Signed-off-by: Thomas Hellstrom <[email protected]> Signed-off-by: Dave Airlie <[email protected]>
2010-10-06drm/vmwgfx: Add new-style PM hooks to improve hibernation behaviorThomas Hellstrom1-34/+79
Add the new-style PM hooks prepare and complete. This allows us to power up the device again after the hibernation image has been created, and display output will thus be active until the VM is finally powered off. Signed-off-by: Thomas Hellstrom <[email protected]> Signed-off-by: Dave Airlie <[email protected]>
2010-10-06drm/vmwgfx: Fix ACPI S3 & S4 functionality.Thomas Hellstrom2-2/+37
Don't suspend or hibernate when there are 3D resources active since we can't restore the device's 3D state. Instead fail with an error message. In other cases, make sure we re-enable the fifo and unlock ttm on resume. Signed-off-by: Thomas Hellstrom <[email protected]> Signed-off-by: Dave Airlie <[email protected]>
2010-10-06drm/vmwgfx: Really support other depths than 32Thomas Hellstrom1-21/+85
Also add some sanity checks. Signed-off-by: Thomas Hellstrom <[email protected]> Signed-off-by: Dave Airlie <[email protected]>
2010-10-06Merge remote branch 'korg/drm-fixes' into drm-vmware-nextDave Airlie7-45/+164
necessary for some of the vmware fixes to be pushed in. Conflicts: drivers/gpu/drm/drm_gem.c drivers/gpu/drm/i915/intel_fb.c include/drm/drmP.h
2010-10-05drm/ttm: restructure to allow driver to plug in alternate memory managerBen Skeggs1-1/+2
Nouveau will need this on GeForce 8 and up to account for the GPU reordering physical VRAM for some memory types. Reviewed-by: Jerome Glisse <[email protected]> Acked-by: Thomas Hellström <[email protected]> Signed-off-by: Ben Skeggs <[email protected]>
2010-10-01vmwgfx: Fix fb VRAM pinning failure due to fragmentationThomas Hellstrom1-0/+5
If the soon-to-be scanout buffer is partly covering the intended VRAM region, move and pin will fail. In that case, just move it out to system before attempting to move it in again. Signed-off-by: Thomas Hellstrom <[email protected]> Signed-off-by: Dave Airlie <[email protected]>
2010-10-01vmwgfx: Remove initialisation of dev::devnameThomas Hellstrom1-6/+0
The removed code causes oopses with newer drms on master drop. Signed-off-by: Thomas Hellstrom <[email protected]> Signed-off-by: Dave Airlie <[email protected]>
2010-10-01vmwgfx: Enable use of the vblank systemThomas Hellstrom4-31/+49
This is to avoid accessing uninitialized data during drm_irq_uninstall and vblank ioctls. At the same time, enable error check from drm_kms_init which previously appeared to ignore all errors. Signed-off-by: Thomas Hellstrom <[email protected]> Signed-off-by: Dave Airlie <[email protected]>
2010-10-01vmwgfx: vt-switch (master drop) fixesThomas Hellstrom5-13/+115
We add an option not to enable fbdev, this option is off (0) by default. Not enabling fbdev at load time makes it possible to co-operate with vga16fb and vga text mode when VT switching. However, if 3D resources are active when VT switching, we're currently not able to switch over to vga, due to device limitations. This fixes a bug where we previously lost 3D state during VT switch. Signed-off-by: Thomas Hellstrom <[email protected]> Signed-off-by: Dave Airlie <[email protected]>
2010-10-01drm/vmwgfx: Fix breakage introduced by commit "drm: block userspace under ↵Thomas Hellstrom1-1/+1
allocating buffer and having drivers overwrite it (v2)" The mentioned commit breaks the vmwgfx ioctl argument sanity check. Signed-off-by: Thomas Hellstrom <[email protected]> Signed-off-by: Dave Airlie <[email protected]>
2010-09-24Merge remote branch 'origin/master' of /home/airlied/kernel//linux-2.6 into ↵Dave Airlie1-3/+4
drm-core-next
2010-09-23drivers/gpu/drm: Remove unnecessary casts of private_dataJoe Perches2-2/+2
Signed-off-by: Joe Perches <[email protected]> Signed-off-by: Jiri Kosina <[email protected]>
2010-09-16drm: use noop_llseekArnd Bergmann1-0/+1
The drm device drivers currently allow seeking on the character device but never care about the actual file position. When we change the default llseek operation to be no_llseek, calling llseek on a drm device would return an error condition, which is an API change. Explicitly setting noop_llseek lets us keep the current API. Signed-off-by: Arnd Bergmann <[email protected]> Cc: David Airlie <[email protected]> Cc: [email protected]
2010-09-14drm: Use a nondestructive mode for output detect when polling (v2)Chris Wilson1-3/+3
v2: Julien Cristau pointed out that @nondestructive results in double-negatives and confusion when trying to interpret the parameter, so use @force instead. Much easier to type as well. ;-) And fix the miscompilation of vmgfx reported by Sedat Dilek. Signed-off-by: Chris Wilson <[email protected]> Cc: [email protected] Signed-off-by: Dave Airlie <[email protected]>
2010-09-13drm: Use a nondestructive mode for output detect when pollingChris Wilson1-1/+2
Destructive load-detection is very expensive and due to failings elsewhere can trigger system wide stalls of up to 600ms. A simple first step to correcting this is not to invoke such an expensive and destructive load-detection operation automatically. Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=29536 Bugzilla: https://bugzilla.kernel.org/show_bug.cgi?id=16265 Reported-by: Bruno Prémont <[email protected]> Tested-by: Sitsofe Wheeler <[email protected]> Signed-off-by: Chris Wilson <[email protected]> Cc: [email protected] Signed-off-by: Dave Airlie <[email protected]>
2010-08-30drm: kill get_reg_ofs callbackDaniel Vetter1-1/+0
Every driver used the default implementation. Fold that one into the only callsite and drop the callback. Signed-off-by: Daniel Vetter <[email protected]> Signed-off-by: Dave Airlie <[email protected]>
2010-08-30drm: kill drm_map_ofs callbacksDaniel Vetter1-1/+0
All drivers happily copy&pasted the default implementation without checking whether this callback is used at all. It's not. Sigh. Kill it. Signed-off-by: Daniel Vetter <[email protected]> Signed-off-by: Dave Airlie <[email protected]>
2010-08-23Merge branch 'drm-core-next' of ↵Linus Torvalds1-17/+17
git://git.kernel.org/pub/scm/linux/kernel/git/airlied/drm-2.6 * 'drm-core-next' of git://git.kernel.org/pub/scm/linux/kernel/git/airlied/drm-2.6: (33 commits) drm/radeon/kms: fix typo in radeon_compute_pll_gain drm/radeon/kms: try to detect tv vs monitor for underscan drm/radeon/kms: fix sideport detection on newer rs880 boards drm/radeon: fix passing wrong type to gem object create. drm/radeon/kms: set encoder type to DVI for HDMI on evergreen drm/radeon/kms: add back missing break in info ioctl drm/radeon/kms: don't enable MSIs on AGP boards drm/radeon/kms: fix agp mode setup on cards that use pcie bridges drm: move dereference below check drm: fix end of loop test drm/radeon/kms: rework radeon_dp_detect() logic drm/radeon/kms: add missing asic callback assignment for evergreen drm/radeon/kms/DCE3+: switch pads to ddc mode when going i2c drm/radeon/kms/pm: bail early if nothing's changing drm/radeon/kms/atom: clean up dig atom handling drm/radeon/kms: DCE3/4 transmitter fixes drm/radeon/kms: rework encoder handling drm/radeon/kms: DCE3/4 AdjustPixelPll updates drm/radeon: Fix stack data leak drm/radeon/kms: fix GTT/VRAM overlapping test ...
2010-08-17drm: block userspace under allocating buffer and having drivers overwrite it ↵Dave Airlie1-17/+17
(v2) With the current screwed but its ABI, ioctls for the drm, Linus pointed out that we could allow userspace to specify the allocation size, but we pass it to the driver which then uses it blindly to store a struct. Now if userspace specifies the allocation size as smaller than the driver needs, the driver can possibly overwrite memory. This patch restructures the driver ioctls so we store the structure size we are expecting, and make sure we allocate at least that size. The copy from/to userspace are still restricted to the size the user specifies, this allows ioctl structs to grow on both sides of the equation. Up until now we didn't really use the DRM_IOCTL defines in the kernel, so this cleans them up and adds them for nouveau. v2: fix nouveau pushbuf arg (thanks to Ben for pointing it out) Reported-by: Linus Torvalds <[email protected]> Signed-off-by: Dave Airlie <[email protected]>
2010-08-12Merge branch 'drm-core-next' of ↵Linus Torvalds2-5/+5
git://git.kernel.org/pub/scm/linux/kernel/git/airlied/drm-2.6 * 'drm-core-next' of git://git.kernel.org/pub/scm/linux/kernel/git/airlied/drm-2.6: (55 commits) io-mapping: move asm include inside the config option vgaarb: drop vga.h include drm/radeon: Add probing of clocks from device-tree drm/radeon: drop old and broken mesa warning drm/radeon: Fix pci_map_page() error checking drm: Remove count_lock for calling lastclose() after 58474713 (v2) drm/radeon/kms: allow FG_ALPHA_VALUE on r5xx drm/radeon/kms: another r6xx/r7xx CS checker fix DRM: Replace kmalloc/memset combos with kzalloc drm: expand gamma_set drm/edid: Split mode lists out to their own header for readability drm/edid: Rewrite mode parse to use the generic detailed block walk drm/edid: Add detailed block walk for VTB extensions drm/edid: Add detailed block walk for CEA extensions drm: Remove unused fields from drm_display_info drm: Use ENOENT consistently for the error return for an unmatched handle. drm/radeon/kms: mark 3D power states as performance drm: Only set DPMS once on the CRTC not after every encoder. drm/radeon/kms: add additional quirk for Acer rv620 laptop drm: Propagate error code from fb_create() ... Fix up trivial conflicts in drivers/gpu/drm/drm_edid.c
2010-08-10drm: expand gamma_setJames Simmons1-1/+1
Expand the crtc_gamma_set function to accept a starting offset. The reason for this is to eventually use this function for setcolreg from drm_fb_helper.c. The fbdev colormap function can start at any offset in the color map. Signed-by: James Simmons <[email protected]> Signed-off-by: Dave Airlie <[email protected]>
2010-08-10drm: Propagate error code from fb_create()Chris Wilson1-4/+4
Change the interface to expect a PTR_ERR specifing the real error code as opposed to assuming a NULL return => -EINVAL. Just once the user may not be at fault! Signed-off-by: Chris Wilson <[email protected]> Signed-off-by: Dave Airlie <[email protected]>
2010-08-05Merge branch 'drm-core-next' of ↵Linus Torvalds4-13/+13
git://git.kernel.org/pub/scm/linux/kernel/git/airlied/drm-2.6 * 'drm-core-next' of git://git.kernel.org/pub/scm/linux/kernel/git/airlied/drm-2.6: (204 commits) agp: intel-agp: do not use PCI resources before pci_enable_device() agp: efficeon-agp: do not use PCI resources before pci_enable_device() drm: kill BKL from common code drm/kms: Simplify setup of the initial I2C encoder config. drm,io-mapping: Specify slot to use for atomic mappings drm/radeon/kms: only expose underscan on avivo chips drm/radeon: add new pci ids drm: Cleanup after failing to create master->unique and dev->name drm/radeon: tone down overchatty acpi debug messages. drm/radeon/kms: enable underscan option for digital connectors drm/radeon/kms: fix calculation of h/v scaling factors drm/radeon/kms/igp: sideport is AMD only drm/radeon/kms: handle the case of no active displays properly in the bandwidth code drm: move ttm global code to core drm drm/i915: Clear the Ironlake dithering flags when the pipe doesn't want it. drm/radeon/kms: make sure HPD is set to NONE on analog-only connectors drm/radeon/kms: make sure rio_mem is valid before unmapping it drm/agp/i915: trim stolen space to 32M drm/i915: Unset cursor if out-of-bounds upon mode change (v4) drm/i915: Unreference object not handle on creation ...
2010-08-04Merge branch 'master' into for-nextJiri Kosina1-0/+1
2010-08-04drm: move ttm global code to core drmDave Airlie2-11/+11
I wrote this for the prime sharing work, but I also noticed other external non-upstream drivers from a large company carrying a similiar patch, so I may as well ship it in master. Signed-off-by: Dave Airlie <[email protected]>
2010-08-02Merge branch 'drm-radeon-next' of ../drm-radeon-next into drm-core-nextDave Airlie1-0/+1
* 'drm-radeon-next' of ../drm-radeon-next: (333 commits) drm/radeon/kms: trivial code style fixes for audio drm/radeon: remove viewport transform from r6xx/r7xx blit emit drm/radeon: group r6xx/r7xx newly sequential blit state drm/radeon: reorder r6xx/r7xx blit state emit to make more regs sequential drm/radeon: r6xx/r7xx move vport clipping to a single packet drm/radeon: group r6xx/r7xx sequential blit state drm/radeon: remove duplicate state emit in r6xx/r7xx blit drm/radeon: add comments to r6xx/r7xx blit state drm/radeon/kms/r7xx: add workaround for hw issue with HDP flush drm/radeon/kms: remove rs4xx gart limit drm: radeon: fix sign bug drm/radeon/kms: check/restore sanity before doing anything else with GPU. drm/radeon: fall back to GTT if bo creation/validation in VRAM fails. drm/radeon/kms: add ioport register access drm/radeon/kms: enable HDMI audio on RS600/RS690/RS740 drm/radeon/kms: track audio engine state, do not use not setup timer drm/radeon/kms/r6xx+: add query for tile config (v2) drm/radeon/kms: fix CS alignment checking for tiling (v2) drm/radeon/kms: add tiling support to the cs checker for r6xx/r7xx drm/radeon/kms: Add crtc tiling setup support for evergreen ...
2010-08-02drm/vmgfx: operation on ‘par->dirty.y1’ may be undefinedChris Wilson1-1/+1
Trivial fix to set y1 = y2 = 0. Signed-off-by: Chris Wilson <[email protected]> Cc: Jakob Bornecrantz <[email protected]> Signed-off-by: Dave Airlie <[email protected]>
2010-08-02Merge tag 'v2.6.35-rc6' into drm-radeon-nextDave Airlie1-0/+1
Need this to avoid conflicts with future radeon fixes
2010-07-20vmwgfx: return -EFAULT if copy_to_user failsDan Carpenter1-0/+1
copy_to_user() returns the number of bytes remaining to be copied, but we want to return a negative error code. This gets copied to user space. Signed-off-by: Dan Carpenter <[email protected]> Signed-off-by: Dave Airlie <[email protected]>
2010-07-07Merge branch 'drm-platform' into drm-testingDave Airlie1-1/+1
* drm-platform: drm: Make sure the DRM offset matches the CPU drm: Add __arm defines to DRM drm: Add support for platform devices to register as DRM devices drm: Remove drm_resource wrappers
2010-06-16Merge branch 'master' into for-nextJiri Kosina13-171/+620
2010-06-16fix typos concerning "management"Uwe Kleine-König1-1/+1
Signed-off-by: Uwe Kleine-König <[email protected]> Signed-off-by: Jiri Kosina <[email protected]>
2010-06-08drm/vmwgfx: return -EFAULT for copy_to_user errorsDan Carpenter2-2/+7
copy_to/from_user() returns the number of bytes remaining to be copied but we want to return a negative error code here. This gets returned to userspace. Signed-off-by: Dan Carpenter <[email protected]> Signed-off-by: Dave Airlie <[email protected]>
2010-06-03drm/vmwgfx: Allow userspace to change default layout. Bump minor.Jakob Bornecrantz5-9/+134
The host may change the layout and, since the change is communicated to the master, the master needs a way to communicate the change to the kernel driver. The minor version number is bumped to advertize the availability of this feature. Signed-off-by: Jakob Bornecrantz <[email protected]> Signed-off-by: Thomas Hellstrom <[email protected]> Signed-off-by: Dave Airlie <[email protected]>
2010-06-03drm/vmwgfx: Fix framebuffer modesettingJakob Bornecrantz1-18/+4
Must set SVGA_NUM_REG_GUEST_DISPLAY before setting up the display information. Signed-off-by: Jakob Bornecrantz <[email protected]> Signed-off-by: Thomas Hellstrom <[email protected]> Signed-off-by: Dave Airlie <[email protected]>
2010-06-03drm/vmwgfx: Fix vga save / restore with display topology.Thomas Hellstrom2-7/+56
vga save / restore previously didn't handle the display topology case. Signed-off-by: Thomas Hellstrom <[email protected]> Signed-off-by: Dave Airlie <[email protected]>
2010-06-01drm: Add support for platform devices to register as DRM devicesJordan Crouse1-1/+1
Allow platform devices without PCI resources to be DRM devices. [airlied: fixup warnings with dev pointers] Signed-off-by: Jordan Crouse <[email protected]> Signed-off-by: Dave Airlie <[email protected]>
2010-06-01drm/vmwgfx: Remove some leftover debug messages.Thomas Hellstrom1-8/+0
Signed-off-by: Thomas Hellstrom <[email protected]> Signed-off-by: Dave Airlie <[email protected]>
2010-06-01drm/vmwgfx: Print warnings in kernel log about bo pinning that fails.Jakob Bornecrantz2-0/+6
Signed-off-by: Jakob Bornecrantz <[email protected]> Signed-off-by: Thomas Hellstrom <[email protected]> Signed-off-by: Dave Airlie <[email protected]>
2010-06-01drm/vmwgfx: Unpause overlay on update.Jakob Bornecrantz1-0/+2
The unpause codepath uses vmw_overlay_update() so we must unset the paused status. Signed-off-by: Jakob Bornecrantz <[email protected]> Signed-off-by: Thomas Hellstrom <[email protected]> Signed-off-by: Dave Airlie <[email protected]>
2010-06-01drm/vmwgfx: Some modesetting cleanups and fixes.Jakob Bornecrantz1-13/+4
Signed-off-by: Jakob Bornecrantz <[email protected]> Signed-off-by: Thomas Hellstrom <[email protected]> Signed-off-by: Dave Airlie <[email protected]>
2010-06-01drm/vmwgfx: Don't use SVGA_REG_ENABLE in modesetting code.Jakob Bornecrantz2-9/+0
We should not use SVGA_REG_ENABLE anywhere but in the fifo setup code, since it controls whether the device is active. Signed-off-by: Jakob Bornecrantz <[email protected]> Signed-off-by: Thomas Hellstrom <[email protected]> Signed-off-by: Dave Airlie <[email protected]>