aboutsummaryrefslogtreecommitdiff
path: root/drivers/gpu/drm/ast
AgeCommit message (Collapse)AuthorFilesLines
2016-12-14drm/ast: Add local 'fb' variablesVille Syrjälä1-5/+10
Add a local 'fb' variable to a few places to get rid of the 'crtc->primary->fb' stuff. Looks neater and helps me with my poor coccinelle skills later. Cc: Dave Airlie <[email protected]> Signed-off-by: Ville Syrjälä <[email protected]> Link: http://patchwork.freedesktop.org/patch/msgid/[email protected] Reviewed-by: Daniel Vetter <[email protected]>
2016-12-01drm: Make the connector .detect() callback optionalLaurent Pinchart1-7/+0
Many drivers (21 to be exact) create connectors that are always connected (for instance to an LVDS or DSI panel). Instead of forcing them to implement a dummy .detect() handler, make the callback optional and consider the connector as always connected in that case. Reviewed-by: Alex Deucher <[email protected]> Acked-by: Maxime Ripard <[email protected]> Acked-by: Jyri Sarha <[email protected]> Acked-by: Jani Nikula <[email protected]> Acked-by: Philipp Zabel <[email protected]> Acked-by: Vincent Abriou <[email protected]> Acked-by: Alexey Brodkin <[email protected]> Signed-off-by: Laurent Pinchart <[email protected]> [seanpaul fixed small conflict in rcar-du/rcar_du_lvdscon.c] Signed-off-by: Sean Paul <[email protected]>
2016-11-14drm/ast: free correct pointer in astfb_create() error pathsAndrew Donnellan1-1/+1
In the err_free_vram and err_release_fbi error paths in astfb_create(), we attempt to free afbdev->sysram. The only jumps to these error paths occur before we assign afbdev->sysram = sysram. Free sysram instead. Signed-off-by: Andrew Donnellan <[email protected]> Signed-off-by: Daniel Vetter <[email protected]> Link: http://patchwork.freedesktop.org/patch/msgid/[email protected]
2016-11-11Merge tag 'topic/drm-misc-2016-11-10' of ↵Dave Airlie1-2/+0
git://anongit.freedesktop.org/drm-intel into drm-next - better atomic state debugging from Rob - fence prep from gustavo - sumits flushed out his backlog of pending dma-buf/fence patches from various people - drm_mm leak debugging plus trying to appease Kconfig (Chris) - a few misc things all over * tag 'topic/drm-misc-2016-11-10' of git://anongit.freedesktop.org/drm-intel: (35 commits) drm: Make DRM_DEBUG_MM depend on STACKTRACE_SUPPORT drm/i915: Restrict DRM_DEBUG_MM automatic selection drm: Restrict stackdepot usage to builtin drm.ko drm/msm: module param to dump state on error irq drm/msm/mdp5: add atomic_print_state support drm/atomic: add debugfs file to dump out atomic state drm/atomic: add new drm_debug bit to dump atomic state drm: add helpers to go from plane state to drm_rect drm: add helper for printing to log or seq_file drm: helper macros to print composite types reservation: revert "wait only with non-zero timeout specified (v3)" v2 drm/ttm: fix ttm_bo_wait dma-buf/fence: revert "don't wait when specified timeout is zero" (v2) dma-buf/fence: make timeout handling in fence_default_wait consistent (v2) drm/amdgpu: add the interface of waiting multiple fences (v4) dma-buf: return index of the first signaled fence (v2) MAINTAINERS: update Sync File Framework files dma-buf/sw_sync: put fence reference from the fence creation dma-buf/sw_sync: mark sync_timeline_create() static drm: Add stackdepot include for DRM_DEBUG_MM ...
2016-11-07Backmerge tag 'v4.9-rc4' into drm-nextDave Airlie1-0/+6
Linux 4.9-rc4 This is needed for nouveau development.
2016-11-02drm: define drm_compat_ioctl NULL on CONFIG_COMPAT=n and reduce #ifdefsJani Nikula1-2/+0
If we define drm_compat_ioctl NULL on CONFIG_COMPAT=n, we don't have to check for the config everywhere. Reviewed-by: Patrik Jakobsson <[email protected]> Signed-off-by: Jani Nikula <[email protected]> Signed-off-by: Sean Paul <[email protected]> Link: http://patchwork.freedesktop.org/patch/msgid/[email protected]
2016-10-26drm/drivers: add support for using the arch wc mapping API.Dave Airlie1-0/+6
This fixes a regression in all these drivers since the cache mode tracking was fixed for mixed mappings. It uses the new arch API to add the VRAM range to the PAT mapping tracking tables. Fixes: 87744ab3832 (mm: fix cache mode tracking in vm_insert_mixed()) Reviewed-by: Christian König <[email protected]>. Signed-off-by: Dave Airlie <[email protected]>
2016-10-25drm/ttm: make eviction decision a driver callback v2Christian König1-0/+1
This way the driver can decide if it is valuable to evict a BO or not. The current implementation is added as default to all existing drivers. v2: fix some typos found during internal testing Signed-off-by: Christian König <[email protected]> Reviewed-by: Alex Deucher <[email protected]> Signed-off-by: Alex Deucher <[email protected]>
2016-09-19drm: use drm_file to tag vm-bosDavid Herrmann1-1/+2
Rather than using "struct file*", use "struct drm_file*" as tag VM tag for BOs. This will pave the way for "struct drm_file*" without any "struct file*" back-pointer. Signed-off-by: David Herrmann <[email protected]> Signed-off-by: Daniel Vetter <[email protected]> Link: http://patchwork.freedesktop.org/patch/msgid/[email protected]
2016-08-12drm: Remove superflous linux/fb.h includesDaniel Vetter1-1/+0
Everyone who uses the fbdev emulation helpers doesn't need to include fb.h directly. Remove it. Reviewed-by: Alex Deucher <[email protected]> Signed-off-by: Daniel Vetter <[email protected]> Link: http://patchwork.freedesktop.org/patch/msgid/[email protected]
2016-07-19Merge remote-tracking branch 'airlied/drm-next' into topic/drm-miscDaniel Vetter1-12/+1
Backmerge drm-next to be able to apply Chris' connector_unregister_all cleanup (need latest i915 and sun4i state for that). Also there's a trivial conflict in ttm_bo.c that git rerere fails to remember. Signed-off-by: Daniel Vetter <[email protected]>
2016-07-18drm/ast: make fbdev support really optionalTobias Jakobi1-4/+0
Currently enabling AST Server DRM support automatically pulls in fbdev dependency. However this dep is unnecessary since DRM core already handles this for us (DRM_FBDEV_EMULATION). Signed-off-by: Tobias Jakobi <[email protected]> Signed-off-by: Daniel Vetter <[email protected]> Link: http://patchwork.freedesktop.org/patch/msgid/[email protected]
2016-07-18drm/ast: Delete an unnecessary check before ↵Markus Elfring1-2/+1
drm_gem_object_unreference_unlocked() The drm_gem_object_unreference_unlocked() function tests whether its argument is NULL and then returns immediately. Thus the test around the call is not needed. This issue was detected by using the Coccinelle software. Signed-off-by: Markus Elfring <[email protected]> Signed-off-by: Daniel Vetter <[email protected]> Link: http://patchwork.freedesktop.org/patch/msgid/[email protected]
2016-07-07drm/ttm: remove dummy bo_move implementationsChristian König1-12/+1
It's pointless to only call the default implementation. Reviewed-by: Alex Deucher <[email protected]> Signed-off-by: Christian König <[email protected]> Signed-off-by: Alex Deucher <[email protected]>
2016-06-09Merge tag 'topic/drm-misc-2016-06-07' of ↵Dave Airlie2-7/+6
git://anongit.freedesktop.org/drm-intel into drm-next As promised, piles of prep work all around: - drm_atomic_state rework, prep for nonblocking commit helpers - fence patches from Gustavo and Christian to prep for atomic fences and some cool work in ttm/amdgpu from Christian - drm event prep for both nonblocking commit and atomic fences - Gustavo seems on a crusade against the non-kms-native version of the vblank functions. - prep work from Boris to nuke all the silly ->best_encoder implementations we have (we really only need that for truly dynamic cases like dvi-i vs dvi-d or dp mst selecting the right transcoder on intel) - prep work from Laurent to rework the format handling functions - and few small things all over * tag 'topic/drm-misc-2016-06-07' of git://anongit.freedesktop.org/drm-intel: (47 commits) drm/dsi: Implement set tear scanline drm/fb_cma_helper: Implement fb_mmap callback drm/qxl: Remove useless drm_fb_get_bpp_depth() call drm/ast: Remove useless drm_fb_get_bpp_depth() call drm/atomic: Fix remaining places where !funcs->best_encoder is valid drm/core: Change declaration for gamma_set. Documentation: add fence-array to kernel DocBook drm/shmobile: use drm_crtc_vblank_{get,put}() drm/radeon: use drm_crtc_vblank_{get,put}() drm/qxl: use drm_crtc_vblank_{get,put}() drm/atmel: use drm_crtc_vblank_{get,put}() drm/armada: use drm_crtc_vblank_{get,put}() drm/amdgpu: use drm_crtc_vblank_{get,put}() drm/virtio: use drm_crtc_send_vblank_event() drm/udl: use drm_crtc_send_vblank_event() drm/qxl: use drm_crtc_send_vblank_event() drm/atmel: use drm_crtc_send_vblank_event() drm/armada: use drm_crtc_send_vblank_event() drm/doc: Switch to sphinx/rst fixed-width quoting drm/doc: Drop kerneldoc for static functions in drm_irq.c ...
2016-06-07drm/ast: Remove useless drm_fb_get_bpp_depth() callLaurent Pinchart1-3/+0
The function has no side effect and its returned values are ignored, don't call it. Signed-off-by: Laurent Pinchart <[email protected]> Reviewed-by: Eric Engestrom <[email protected]> Signed-off-by: Daniel Vetter <[email protected]> Link: http://patchwork.freedesktop.org/patch/msgid/1465236852-11710-1-git-send-email-laurent.pinchart@ideasonboard.com
2016-06-07drm/core: Change declaration for gamma_set.Maarten Lankhorst1-4/+6
Change return value to int to propagate errors from gamma_set, and remove start parameter. Updates always use the full size, and some drivers even ignore the start parameter altogether. This is needed for atomic drivers, where an atomic commit can fail with -EINTR or -ENOMEM and should be restarted. This is already and issue for drm_atomic_helper_legacy_set_gamma, which this patch fixes up. Changes since v1: - Fix compiler warning. (Emil) - Fix commit message (Daniel) Cc: Alex Deucher <[email protected]> Acked-by: Alex Deucher <[email protected]> Cc: Christian König <[email protected]> Cc: David Airlie <[email protected]> Cc: Patrik Jakobsson <[email protected]> Cc: Ben Skeggs <[email protected]> Cc: Eric Anholt <[email protected]> Cc: VMware Graphics <[email protected]> Cc: Mathieu Larouche <[email protected]> Cc: Thierry Reding <[email protected]> Acked-by: Patrik Jakobsson <[email protected]> Signed-off-by: Maarten Lankhorst <[email protected]> [danvet: Improve commit message a bit more, mention that this fixes the helper.] Signed-off-by: Daniel Vetter <[email protected]> Link: http://patchwork.freedesktop.org/patch/msgid/[email protected]
2016-06-01drm/ast: Use lockless gem BO free callbackDaniel Vetter1-1/+1
No dev->struct_mutex anywhere to be seen. Cc: Dave Airlie <[email protected]> Signed-off-by: Daniel Vetter <[email protected]> Link: http://patchwork.freedesktop.org/patch/msgid/[email protected]
2016-05-17drm: Remove unused drm_device from drm_gem_object_lookup()Chris Wilson2-3/+3
drm_gem_object_lookup() has never required the drm_device for its file local translation of the user handle to the GEM object. Let's remove the unused parameter and save some space. Signed-off-by: Chris Wilson <[email protected]> Cc: [email protected] Cc: Dave Airlie <[email protected]> Cc: Daniel Vetter <[email protected]> [danvet: Fixup kerneldoc too.] Signed-off-by: Daniel Vetter <[email protected]>
2016-05-04drm/ttm: implement LRU add callbacks v2Christian König1-0/+2
This allows fine grained control for the driver where to add a BO into the LRU. v2: fix typo in comment Reviewed-by: Sinclair Yeh <[email protected]> Signed-off-by: Christian König <[email protected]> Reviewed-by: Alex Deucher <[email protected]> Signed-off-by: Alex Deucher <[email protected]>
2016-05-04drm/ttm: remove use_ticket parameter from ttm_bo_reserveChristian König1-1/+1
Not used any more. Reviewed-by: Sinclair Yeh <[email protected]> Signed-off-by: Christian König <[email protected]> Reviewed-by: Alex Deucher <[email protected]> Signed-off-by: Alex Deucher <[email protected]>
2016-04-06Merge tag 'topic/drm-misc-2016-04-01' of ↵Dave Airlie1-2/+0
git://anongit.freedesktop.org/drm-intel into drm-next * tag 'topic/drm-misc-2016-04-01' of git://anongit.freedesktop.org/drm-intel: drm: Add new DCS commands in the enum list drm: Make uapi headers C89 pendantic compliant drm/atomic: export drm_atomic_helper_wait_for_fences() drm: Untangle __KERNEL__ guards drm: Move DRM_MODE_OBJECT_* to uapi headers drm: align #include directives with libdrm in uapi headers drm: Make drm.h uapi header safe for C++ vgacon: dummy implementation for vgacon_text_force drm/sysfs: Nuke TV/DVI property files drm/ttm: Remove TTM_HAS_AGP drm: bridge/dw-hdmi: Remove pre_enable/post_disable dummy funcs Revert "drm: Don't pass negative delta to ktime_sub_ns()" drm/atmel: Fixup drm_connector_/unplug/unregister/_all drm: Rename drm_connector_unplug_all() to drm_connector_unregister_all() drm: bridge: Make (pre/post) enable/disable callbacks optional
2016-03-30vgacon: dummy implementation for vgacon_text_forceDaniel Vetter1-2/+0
This allows us to ditch a ton of ugly #ifdefs from a bunch of drm modeset drivers. v2: Make the dummy function actually return a sane value, spotted by Ville. v3: Because the patch is still in limbo there's no more drivers to convert, noticed by Emil. v4: Rebase once more, because hooray. I'll just go ahead an apply this one later on to drm-misc. Cc: Emil Velikov <[email protected]> Cc: Ville Syrjälä <[email protected]> Cc: Andrew Morton <[email protected]> Cc: Greg Kroah-Hartman <[email protected]> Reviewed-by: Emil Velikov <[email protected]> Reviewed-by: Alex Deucher <[email protected]> Signed-off-by: Daniel Vetter <[email protected]>
2016-03-16Merge tag 'topic/drm-misc-2016-03-14' of ↵Dave Airlie1-8/+0
git://anongit.freedesktop.org/drm-intel into drm-next * tag 'topic/drm-misc-2016-03-14' of git://anongit.freedesktop.org/drm-intel: (27 commits) drm: atomic helper: do not unreference error pointer drm/edid: Extract SADs properly from multiple audio data blocks drm: fix blob pointer check drm: introduce pipe color correction properties drm/atomic: Clean up update_connector_routing. drm/atomic: Clean up steal_encoder, v2. drm/atomic: Handle encoder assignment conflicts in a separate check, v3. drm/atomic: Handle encoder stealing from set_config better. drm/atomic: Always call steal_encoder, v2. drm/ast: removed optional dummy crtc mode_fixup function. drm/bochs: removed optional dummy crtc mode_fixup function. drm/fsl-dcu: removed optional dummy crtc mode_fixup function. drm/virtio: removed optional dummy crtc mode_fixup function. drm/nouveau/dispnv04: removed optional dummy crtc mode_fixup function. drm/atmel-hlcdc: remove optional dummy crtc mode_fixup function. drm/sti: removed optional dummy crtc mode_fixup function. drm/shmobile: removed optional dummy crtc mode_fixup function. drm/msm/mdp: removed optional dummy crtc mode_fixup function. drm/omapdrm: removed optional dummy crtc mode_fixup function. drm/rcar-du: removed optional dummy crtc mode_fixup function. ...
2016-03-14Merge drm-fixes into drm-next.Dave Airlie1-1/+1
Nouveau wanted this to avoid some worse conflicts when I merge that.
2016-03-04drm/ast: removed optional dummy crtc mode_fixup function.Carlos Palminha1-8/+0
This patch set nukes all the dummy crtc mode_fixup implementations. (made on top of Daniel topic/drm-misc branch) Signed-off-by: Carlos Palminha <[email protected]> Signed-off-by: Daniel Vetter <[email protected]> Link: http://patchwork.freedesktop.org/patch/msgid/0f8f948babd93fce8523253b0f525446e2f565db.1455630967.git.palminha@synopsys.com
2016-03-02drm/ast: Fix incorrect register check for DRAM widthTimothy Pearson1-1/+1
During DRAM initialization on certain ASpeed devices, an incorrect bit (bit 10) was checked in the "SDRAM Bus Width Status" register to determine DRAM width. Query bit 6 instead in accordance with the Aspeed AST2050 datasheet v1.05. Signed-off-by: Timothy Pearson <[email protected]> Cc: [email protected] Signed-off-by: Dave Airlie <[email protected]>
2016-02-16drm/ast: removed optional dummy encoder mode_fixup function.Carlos Palminha1-8/+0
mode_fixup function for encoder drivers became optional with patch http://patchwork.freedesktop.org/patch/msgid/[email protected] This patch set nukes all the dummy mode_fixup implementations. (made on top of Daniel topic/drm-misc branch) Signed-off-by: Carlos Palminha <[email protected]> Signed-off-by: Daniel Vetter <[email protected]> Link: http://patchwork.freedesktop.org/patch/msgid/12e1e900724c890166b88b0f4d67baba387482af.1455540137.git.palminha@synopsys.com
2015-12-11drm: Pass 'name' to drm_encoder_init()Ville Syrjälä1-1/+1
Done with coccinelle for the most part. However, it thinks '...' is part of the semantic patch, so I put an 'int DOTDOTDOT' placeholder in its place and got rid of it with sed afterwards. @@ identifier dev, encoder, funcs; @@ int drm_encoder_init(struct drm_device *dev, struct drm_encoder *encoder, const struct drm_encoder_funcs *funcs, int encoder_type + ,const char *name, int DOTDOTDOT ) { ... } @@ identifier dev, encoder, funcs; @@ int drm_encoder_init(struct drm_device *dev, struct drm_encoder *encoder, const struct drm_encoder_funcs *funcs, int encoder_type + ,const char *name, int DOTDOTDOT ); @@ expression E1, E2, E3, E4; @@ drm_encoder_init(E1, E2, E3, E4 + ,NULL ) v2: Add ', or NULL...' to @name kernel doc (Jani) Annotate the function with __printf() attribute (Jani) Signed-off-by: Ville Syrjälä <[email protected]> Signed-off-by: Daniel Vetter <[email protected]> Link: http://patchwork.freedesktop.org/patch/msgid/[email protected]
2015-11-24drm: Pass the user drm_mode_fb_cmd2 as const to .fb_create()Ville Syrjälä3-4/+4
Drivers shouldn't clobber the passed in addfb ioctl parameters. i915 was doing just that. To prevent it from happening again, pass the struct around as const, starting all the way from internal_framebuffer_create(). Signed-off-by: Ville Syrjälä <[email protected]> Signed-off-by: Daniel Vetter <[email protected]>
2015-11-24drm: Remove unused fbdev_list membersLukas Wunner1-1/+0
I noticed that intel_fbdev->our_mode is unused. Introduced by 79e539453b34 ("DRM: i915: add mode setting support"). Then I noticed that intel_fbdev->fbdev_list is unused as well. Introduced by 386516744ba4 ("drm/fb: fix fbdev object model + cleanup properly.") in i915, nouveau and radeon. Subsequently cargo culted to amdgpu, ast, cirrus, qxl, udl, virtio and mgag200. Already removed from the latter with cc59487a05b1 ("drm/mgag200: 'fbdev_list' in 'struct mga_fbdev' is not used"). Remove it from the others. Signed-off-by: Lukas Wunner <[email protected]> Signed-off-by: Daniel Vetter <[email protected]>
2015-11-11drm/ast: Initialized data needed to map fbdev memoryEgbert Eich4-0/+11
Due to a missing initialization there was no way to map fbdev memory. Thus for example using the Xserver with the fbdev driver failed. This fix adds initialization for fix.smem_start and fix.smem_len in the fb_info structure, which fixes this problem. Requested-by: Benjamin Herrenschmidt <[email protected]> Cc: [email protected] Signed-off-by: Egbert Eich <[email protected]> [pulled from SuSE tree by me - airlied] Signed-off-by: Dave Airlie <[email protected]>
2015-08-10drm/ast: Don't grab dev->struct_mutex for in mmap offset ioctlDaniel Vetter1-11/+5
Since David Herrmann's mmap vma manager rework we don't need to grab dev->struct_mutex any more to prevent races when looking up the mmap offset. Drop it and instead don't forget to use the unref_unlocked variant (since the drm core still cares). Reviewed-by: Thierry Reding <[email protected]> Signed-off-by: Daniel Vetter <[email protected]>
2015-08-06drm/ast: Use new drm_fb_helper functionsArchit Taneja1-31/+17
Use the newly created wrapper drm_fb_helper functions instead of calling core fbdev functions directly. They also simplify the fb_info creation. Cleaned up the error handling in astfb_create a bit. v2: - removed unused variable 'device' in astfb_create Cc: David Airlie <[email protected]> Cc: "Y.C. Chen" <[email protected]> Cc: Alex Deucher <[email protected]> Signed-off-by: Archit Taneja <[email protected]> Signed-off-by: Daniel Vetter <[email protected]>
2015-01-21drm/fb-helper: Propagate errors from initial config failureThierry Reding1-6/+15
Make drm_fb_helper_initial_config() return an int rather than a bool so that the error can be properly propagated. While at it, update drivers to propagate errors further rather than just ignore them. v2: - cirrus: No cleanup is required, the top-level cirrus_driver_load() will do it as part of cirrus_driver_unload() in its cleanup path. Reported-by: Fengguang Wu <[email protected]> Cc: David Airlie <[email protected]> Cc: Daniel Vetter <[email protected]> Cc: Patrik Jakobsson <[email protected]> Cc: Rob Clark <[email protected]> Cc: Tomi Valkeinen <[email protected]> Cc: Alex Deucher <[email protected]> Cc: Christian König <[email protected]> Cc: Ben Skeggs <[email protected]> Signed-off-by: Thierry Reding <[email protected]> Reviewed-by: Alex Deucher <[email protected]> Reviewed-by: Patrik Jakobsson <[email protected]> Reviewed-by: Christian König <[email protected]> [danvet: Squash in simplification patch from kbuild.] Signed-off-by: Daniel Vetter <[email protected]>
2014-11-05drm: Move drm_crtc_init from drm_crtc.h to drm_plane_helper.hDaniel Vetter1-0/+1
Just a bit of OCD cleanup on headers - this function isn't the core interface any more but just a helper for drivers who haven't yet transitioned to universal planes. Put the declaration at the right spot and sprinkle necessary #includes over all drivers. Maybe this helps to encourage driver maintainers to do the switch. v2: Fix #include ordering for tegra, reported by 0-day builder. v3: Include required headers, reported by Thierry. Cc: Matt Roper <[email protected]> Cc: Thierry Reding <[email protected]> Reviewed-by: Matt Roper <[email protected]> Reviewed-by: Sean Paul <[email protected]> Signed-off-by: Daniel Vetter <[email protected]>
2014-10-08drm/ast: Fix HW cursor imageBenjamin Herrenschmidt1-2/+2
The translation from the X driver to the KMS one typo'ed a couple of array indices, causing the HW cursor to look weird (blocky with leaking edge colors). This fixes it. Signed-off-by: Benjamin Herrenschmidt <[email protected]> Cc: [email protected] Signed-off-by: Dave Airlie <[email protected]>
2014-10-01Merge branch 'for-airlied-next' of ↵Dave Airlie1-1/+1
git://people.freedesktop.org/~mlankhorst/linux into drm-next fixups for nouveau and fencing * 'for-airlied-next' of git://people.freedesktop.org/~mlankhorst/linux: drm/nouveau: export reservation_object from dmabuf to ttm drm/ttm: add reservation_object as argument to ttm_bo_init drm: Pass dma-buf as argument to gem_prime_import_sg_table drm/nouveau: assign fence_chan->name correctly drm/nouveau: specify if interruptible wait is desired in nouveau_fence_sync drm/nouveau: bump driver patchlevel to 1.2.1
2014-09-30drm/ttm: add reservation_object as argument to ttm_bo_initMaarten Lankhorst1-1/+1
This allows importing reservation objects from dma-bufs. Signed-off-by: Maarten Lankhorst <[email protected]>
2014-09-24drm/ast: use container_of to resolve ast_fbdev from drm_fb_helperFabian Frederick1-1/+2
Use container_of instead of casting first structure member. Signed-off-by: Fabian Frederick <[email protected]> Signed-off-by: Daniel Vetter <[email protected]>
2014-09-24drm: Extract <drm/drm_gem.h>Daniel Vetter1-0/+2
v2: Don't forget git add, noticed by David. Cc: David Herrmann <[email protected]> Signed-off-by: Daniel Vetter <[email protected]> Acked-by: David Herrmann <[email protected]> Acked-by: Alex Deucher <[email protected]> Signed-off-by: Dave Airlie <[email protected]>
2014-09-24drm/<ttm-based-drivers>: Don't call drm_mmapDaniel Vetter1-1/+1
Really, the legacy buffer api should be dead, especially for all these newfangled drivers. I suspect this is copypasta from the transitioning days, which probably originated in radeon. Cc: "Christian König" <[email protected]> Cc: David Herrmann <[email protected]> Cc: Rashika <[email protected]> Cc: Josh Triplett <[email protected]> Cc: Daniel Vetter <[email protected]> Cc: Fabian Frederick <[email protected]> Cc: Gerd Hoffmann <[email protected]> Cc: Alexandre Courbot <[email protected]> Cc: Maarten Lankhorst <[email protected]> Cc: Christian Engelmayer <[email protected]> Signed-off-by: Daniel Vetter <[email protected]> Reviewed-by: David Herrmann <[email protected]> Acked-by: Ben Skeggs <[email protected]> Acked-by: Alex Deucher <[email protected]> Signed-off-by: Dave Airlie <[email protected]>
2014-09-16Merge branch 'drm-next-ast-fixes' of ssh://people.freedesktop.org/~/linux ↵Dave Airlie4-25/+123
into drm-next Pull in first set of changes from Ben for ast on ppc. I've done a quick boot test on x86 and it still seems to boot. * 'drm-next-ast-fixes' of ssh://people.freedesktop.org/~/linux: drm/ast: Cleanup analog init code path drm/ast: Don't assume DVO enabled means SIL164 on uninitialized chips drm/ast: Properly initialize P2A base before using it in ast_init_3rdtx() drm/ast: POST chip at probe time if VGA not enabled drm/ast: Try to use MMIO registers when PIO isn't supported
2014-09-16drm/ast: Add reduced blanking modes for wide screen modeY.C. Chen2-24/+56
Signed-off-by: Egbert Eich <[email protected]> Tested-by: Steven You2 Liang <[email protected]> Signed-off-by: Y.C. Chen <[email protected]> v3: based on [PATCH 1/2] drm/ast: Add missing entry to dclk_table[]. Add reduced blanking modes, improve mode matching to identify these modes by thier sync polarities. [airlied: argh whitespace damage] Signed-off-by: Dave Airlie <[email protected]>
2014-09-16drm: backmerge tag 'v3.17-rc5' into drm-nextDave Airlie2-1/+3
This is requested to get the fixes for intel and radeon into the same tree for future development work. i915_display.c: fix missing dev_priv conflict.
2014-09-15drm/ast: Cleanup analog init code pathBenjamin Herrenschmidt1-18/+31
Move the MMIO mangling to a separate routine and actually disable the DVO output when using pure analog. Signed-off-by: Benjamin Herrenschmidt <[email protected]> Signed-off-by: Dave Airlie <[email protected]>
2014-09-15drm/ast: Don't assume DVO enabled means SIL164 on uninitialized chipsBenjamin Herrenschmidt1-4/+10
It looks like the AST2400 comes up with the DVO enable bit set, which causes us to incorrectly assume we have a SIL164 regardless of the value of the scratch registers setup by the BMC firmware. So let's limit that test to the case where the chip has already been setup by a BIOS. Signed-off-by: Benjamin Herrenschmidt <[email protected]> Signed-off-by: Dave Airlie <[email protected]>
2014-09-15drm/ast: Properly initialize P2A base before using it in ast_init_3rdtx()Benjamin Herrenschmidt1-0/+11
If the P2A has been used to target other SOC registers before that call, we're going to hit the wrong place so make sure we set the base address up properly before using it. (P2A stands for PCIe to AHB bridge and is the bride that allows accessing the AST's internal AHB bus using a relocatable 64k window in the second half of the PCIe MMIO BAR) Signed-off-by: Benjamin Herrenschmidt <[email protected]> Signed-off-by: Dave Airlie <[email protected]>
2014-09-15drm/ast: POST chip at probe time if VGA not enabledBenjamin Herrenschmidt3-11/+62
We need to do it on machines without a BIOS such as POWER8. Also for detection to work without triggering PCIe errors, we need to enable VGA early on, inside ast_detect_chip(). While touching those files, replace a few hard coded register numbers with the corresponding symbolic constant. Signed-off-by: Benjamin Herrenschmidt <[email protected]> Signed-off-by: Dave Airlie <[email protected]>
2014-09-15drm/ast: Try to use MMIO registers when PIO isn't supportedBenjamin Herrenschmidt2-4/+21
If the PIO resources haven't been assigned, then we have no choice but try to use the MMIO version. This is the case for example on POWER8 which doesn't support PIO at all. Chips rev 0x20 or later have MMIO decoding enabled by default. Signed-off-by: Benjamin Herrenschmidt <[email protected]> Signed-off-by: Dave Airlie <[email protected]>