aboutsummaryrefslogtreecommitdiff
AgeCommit message (Collapse)AuthorFilesLines
2017-07-31drm: Add a few missing descriptions in drm_driver docsSean Paul1-6/+46
Fixes the following warnings when building docs: ../include/drm/drm_drv.h:553: warning: No description found for parameter 'debugfs_init' ../include/drm/drm_drv.h:553: warning: No description found for parameter 'gem_open_object' ../include/drm/drm_drv.h:553: warning: No description found for parameter 'gem_close_object' ../include/drm/drm_drv.h:553: warning: No description found for parameter 'prime_handle_to_fd' ../include/drm/drm_drv.h:553: warning: No description found for parameter 'prime_fd_to_handle' ../include/drm/drm_drv.h:553: warning: No description found for parameter 'gem_prime_export' ../include/drm/drm_drv.h:553: warning: No description found for parameter 'gem_prime_import' ../include/drm/drm_drv.h:553: warning: No description found for parameter 'gem_vm_ops' ../include/drm/drm_drv.h:553: warning: No description found for parameter 'major' ../include/drm/drm_drv.h:553: warning: No description found for parameter 'minor' ../include/drm/drm_drv.h:553: warning: No description found for parameter 'patchlevel' ../include/drm/drm_drv.h:553: warning: No description found for parameter 'name' ../include/drm/drm_drv.h:553: warning: No description found for parameter 'desc' ../include/drm/drm_drv.h:553: warning: No description found for parameter 'date' ../include/drm/drm_drv.h:553: warning: No description found for parameter 'driver_features' There are still a couple more warnings for prime helpers that are documented elsewhere. Signed-off-by: Sean Paul <[email protected]> Reviewed-by: Daniel Vetter <[email protected]> Signed-off-by: Thierry Reding <[email protected]> Link: https://patchwork.freedesktop.org/patch/msgid/[email protected]
2017-07-31gpu/host1x: Remove excess parameter in host1x_subdev_add docsSean Paul1-1/+0
Fixes the following warning when building docs: ../drivers/gpu/host1x/bus.c:50: warning: Excess function parameter 'driver' description in 'host1x_subdev_add' Signed-off-by: Sean Paul <[email protected]> Signed-off-by: Thierry Reding <[email protected]> Link: https://patchwork.freedesktop.org/patch/msgid/[email protected]
2017-07-31drm: Fix warning when building docs for scdc_helperSean Paul2-38/+20
Fixes: ../drivers/gpu/drm/drm_scdc_helper.c:203: ERROR: Unexpected indentation. ../drivers/gpu/drm/drm_scdc_helper.c:204: WARNING: Block quote ends without a blank line; unexpected unindent. Changes in v2: - Property blockquote TMDS calculations so they look pretty (Daniel) - Remove duplicate documentation from the header file Signed-off-by: Sean Paul <[email protected]> Reviewed-by: Shashank Sharma <[email protected]> Signed-off-by: Thierry Reding <[email protected]> Link: https://patchwork.freedesktop.org/patch/msgid/[email protected]
2017-07-31drm/modes: Fix drm_mode_is_420_only() commentSean Paul1-1/+1
Fixes the following warnings when building docs: ../drivers/gpu/drm/drm_modes.c:1623: warning: No description found for parameter 'display' ../drivers/gpu/drm/drm_modes.c:1623: warning: Excess function parameter 'connector' description in 'drm_mode_is_420_only' Signed-off-by: Sean Paul <[email protected]> Reviewed-by: Daniel Vetter <[email protected]> Signed-off-by: Thierry Reding <[email protected]> Link: https://patchwork.freedesktop.org/patch/msgid/[email protected]
2017-07-31drm: Fix kerneldoc for atomic_async_updateDaniel Vetter1-3/+3
The enumeration of FIXMEs wasn't indented properly. Fixes: fef9df8b5945 ("drm/atomic: initial support for asynchronous plane update") Cc: Gustavo Padovan <[email protected]> Signed-off-by: Daniel Vetter <[email protected]> Signed-off-by: Thierry Reding <[email protected]> Link: https://patchwork.freedesktop.org/patch/msgid/[email protected]
2017-07-31drm/atomic: Update comment to match the codeThierry Reding1-1/+1
The kerneldoc for drm_atomic_crtc_needs_modeset() is outdated and no longer reflects the actual code. Fix that up to remove confusion. Reviewed-by: Daniel Vetter <[email protected]> Signed-off-by: Thierry Reding <[email protected]> Link: https://patchwork.freedesktop.org/patch/msgid/[email protected]
2017-07-31drm/rockchip: vop: rk3328: fix overlay abnormalMark yao3-0/+4
It's a hardware bug, all window's overlay channel reset value is same, hardware overlay would be die. so we must initial difference id for each overlay channel. The Channel register is supported on all vop will full design. Following is the details for this register VOP_WIN0_CTRL2 bit[7:4] win_rid_win0_cbr axi read id of win0 cbr channel bit[3:0] win_rid_win0_yrgb axi read id of win0 yrgb channel Signed-off-by: Mark Yao <[email protected]> Reviewed-by: Jeffy Chen <[email protected]> Tested-by: Heiko Stuebner <[email protected]> Link: https://patchwork.freedesktop.org/patch/msgid/[email protected]
2017-07-31dt-bindings: display: rockchip: fill Documents for vop seriesMark yao1-0/+4
Signed-off-by: Mark Yao <[email protected]> Acked-by: Rob Herring <[email protected]> Link: https://patchwork.freedesktop.org/patch/msgid/[email protected]
2017-07-31drm/rockchip: vop: add a series of vop supportMark yao3-224/+908
Vop Full framework now has following vops: IP version chipname 3.1 rk3288 3.2 rk3368 3.4 rk3366 3.5 rk3399 big 3.6 rk3399 lit 3.7 rk3228 3.8 rk3328 The above IP version is from H/W define, some of vop support get the IP version from VERSION_INFO register, some are not. hardcode the IP version for each vop to identify them. major version: used for IP structure, Vop full framework is 3, vop little framework is 2. minor version: on same structure, newer design vop will bigger then old one. Signed-off-by: Mark Yao <[email protected]> Reviewed-by: Jeffy Chen <[email protected]> Tested-by: Heiko Stuebner <[email protected]> Link: https://patchwork.freedesktop.org/patch/msgid/[email protected]
2017-07-31drm/rockchip: vop: group vop registersMark yao3-127/+146
Grouping the vop registers facilitates make register definition clearer, and also is useful for different vop reuse the same group register. Signed-off-by: Mark Yao <[email protected]> Reviewed-by: Jeffy Chen <[email protected]> Tested-by: Heiko Stuebner <[email protected]> Link: https://patchwork.freedesktop.org/patch/msgid/[email protected]
2017-07-31drm/rockchip: vop: move line_flag_num to interrupt registersMark yao3-9/+13
In the hardware design process, the design of line flags register is associated with the interrupt register, placing the line flags in the interrupt definition is more reasonable, and it would make multi-vop define easilier. Signed-off-by: Mark Yao <[email protected]> Reviewed-by: Sean Paul <[email protected]> Tested-by: Heiko Stuebner <[email protected]> Link: https://patchwork.freedesktop.org/patch/msgid/[email protected]
2017-07-31drm/rockchip: vop: move write_relaxed flags to vop registerMark yao3-35/+36
Since the drm atomic framework, only a small part of the vop register needs sync write, Currently seems only following registers need sync write: cfg_done, standby and interrupt related register. All ctrl registers are using the sync write method that is inefficient, hardcode the write_relaxed flags to vop registers, then can only do synchronize write for those actual needed register. Signed-off-by: Mark Yao <[email protected]> Tested-by: Heiko Stuebner <[email protected]> Reviewed-by: Jeffy Chen <[email protected]> Link: https://patchwork.freedesktop.org/patch/msgid/[email protected]
2017-07-31drm/rockchip: vop: initialize registers directlyMark yao3-49/+11
At present we are using init_table to initialize some registers, but the Register init table use un-document define, it is unreadable, and sometimes we only want to update tiny bits, init table method is not friendly, it's diffcult to reuse for difference chips. To make it clean, initialize registers directly, and drops init_table mechanism out. Signed-off-by: Mark Yao <[email protected]> Tested-by: Heiko Stuebner <[email protected]> Reviewed-by: Jeffy Chen <[email protected]> Link: https://patchwork.freedesktop.org/patch/msgid/[email protected]
2017-07-29v4l: vsp1: Add support for the BRS entityLaurent Pinchart11-60/+136
The Blend/ROP Sub Unit (BRS) is a stripped-down version of the BRU found in several VSP2 instances. Compared to a regular BRU, it supports two inputs only, and thus has no ROP unit. Add support for the BRS by modelling it as a new entity type, but reuse the vsp1_bru object underneath. Chaining the BRU and BRS entities seems to be supported by the hardware but isn't implemented yet as it isn't the primary use case for the BRS. Signed-off-by: Laurent Pinchart <[email protected]> Reviewed-by: Kieran Bingham <[email protected]> Acked-by: Mauro Carvalho Chehab <[email protected]>
2017-07-29v4l: vsp1: Add pipe index argument to the VSP-DU APILaurent Pinchart3-14/+28
In the H3 ES2.0 SoC the VSP2-DL instance has two connections to DU channels that need to be configured independently. Extend the VSP-DU API with a pipeline index to identify which pipeline the caller wants to operate on. Signed-off-by: Laurent Pinchart <[email protected]> Reviewed-by: Kieran Bingham <[email protected]> Acked-by: Mauro Carvalho Chehab <[email protected]>
2017-07-29v4l: vsp1: Don't create links for DRM pipelineLaurent Pinchart3-58/+12
When the VSP1 is used in a DRM pipeline the driver doesn't register the media device. Links between entities are not exposed to userspace, but are still used internally for the sole purpose of setting up internal source to sink pointers through the link setup handler. Instead of going through this complex procedure, remove link creation and set the sink pointers directly. Signed-off-by: Laurent Pinchart <[email protected]> Reviewed-by: Kieran Bingham <[email protected]> Acked-by: Mauro Carvalho Chehab <[email protected]>
2017-07-29v4l: vsp1: Store source and sink pointers as vsp1_entityLaurent Pinchart4-18/+18
The internal VSP entity source and sink pointers are stored as media_entity pointers, which are then cast to a vsp1_entity. As all sources and sinks are vsp1_entity instances, we can store the vsp1_entity pointers directly. Signed-off-by: Laurent Pinchart <[email protected]> Reviewed-by: Kieran Bingham <[email protected]> Acked-by: Mauro Carvalho Chehab <[email protected]>
2017-07-29v4l: vsp1: Don't set WPF sink pointerLaurent Pinchart1-1/+0
The sink pointer is used to configure routing inside the VSP, and as such must point to the next VSP entity in the pipeline. The WPF being a pipeline terminal sink, its output route can't be configured. The routing configuration code already handles this correctly without referring to the sink pointer, which thus doesn't need to be set. Signed-off-by: Laurent Pinchart <[email protected]> Reviewed-by: Kieran Bingham <[email protected]> Acked-by: Mauro Carvalho Chehab <[email protected]>
2017-07-29v4l: vsp1: Don't recycle active list at display startLaurent Pinchart5-35/+4
When the display start interrupt occurs, we know that the hardware has finished loading the active display list. The driver then proceeds to recycle the list, assuming it won't be needed anymore. This assumption holds true for headerless display lists, as the VSP doesn't reload the list for the next frame if it hasn't changed. However, this isn't true anymore for header display lists, as they are loaded at every frame start regardless of whether they have been updated. To prepare for header display lists usage in display pipelines, we need to postpone recycling the list until it gets replaced by a new one through a page flip. The driver already does so in the frame end interrupt handler, so all we need is to skip list recycling in the display start interrupt handler. While the active list can be recycled at display start for headerless display lists, there's no real harm in postponing that to the frame end interrupt handler in all cases. This simplifies interrupt handling as we don't need to process the display start interrupt anymore. Signed-off-by: Laurent Pinchart <[email protected]> Reviewed-by: Kieran Bingham <[email protected]> Acked-by: Mauro Carvalho Chehab <[email protected]>
2017-07-29v4l: vsp1: Fill display list headers without holding dlm spinlockLaurent Pinchart1-2/+4
The display list headers are filled using information from the display list only. Lower the display list manager spinlock contention by filling the headers without holding the lock. Signed-off-by: Laurent Pinchart <[email protected]> Reviewed-by: Kieran Bingham <[email protected]> Acked-by: Mauro Carvalho Chehab <[email protected]>
2017-07-29dma-buf/sync_file: Allow multiple sync_files to wrap a single dma-fenceChris Wilson2-3/+5
Up until recently sync_file were create to export a single dma-fence to userspace, and so we could canabalise a bit insie dma-fence to mark whether or not we had enable polling for the sync_file itself. However, with the advent of syncobj, we do allow userspace to create multiple sync_files for a single dma-fence. (Similarly, that the sw-sync validation framework also started returning multiple sync-files wrapping a single dma-fence for a syncpt also triggering the problem.) This patch reverts my suggestion in commit e24165537312 ("dma-buf/sync_file: only enable fence signalling on poll()") to use a single bit in the shared dma-fence and restores the sync_file->flags for tracking the bits individually. Reported-by: Gustavo Padovan <[email protected]> Fixes: f1e8c67123cf ("dma-buf/sw-sync: Use an rbtree to sort fences in the timeline") Fixes: e9083420bbac ("drm: introduce sync objects (v4)") Signed-off-by: Chris Wilson <[email protected]> Cc: Sumit Semwal <[email protected]> Cc: Sean Paul <[email protected]> Cc: Gustavo Padovan <[email protected]> Cc: [email protected] Cc: <[email protected]> # v4.13-rc1+ Signed-off-by: Gustavo Padovan <[email protected]> Link: http://patchwork.freedesktop.org/patch/msgid/[email protected]
2017-07-29tinydrm: repaper: add CONFIG_THERMAL dependencyArnd Bergmann1-0/+1
The new RePaper driver uses the thermal subsystem, and fails to link when it is built-in but thermal is a loadable module: drivers/gpu/drm/tinydrm/repaper.o: In function `repaper_probe': repaper.c:(.text+0x540): undefined reference to `thermal_zone_get_zone_by_name' drivers/gpu/drm/tinydrm/repaper.o: In function `repaper_fb_dirty': repaper.c:(.text+0xff4): undefined reference to `thermal_zone_get_temp' This adds another Kconfig dependency to prevent the broken configuration, forcing repaper to be a module too. Fixes: 3589211e9b03 ("drm/tinydrm: Add RePaper e-ink driver") Signed-off-by: Arnd Bergmann <[email protected]> Signed-off-by: Noralf Trønnes <[email protected]> Link: https://patchwork.freedesktop.org/patch/msgid/[email protected]
2017-07-29drm/hisilicon: hibmc: Use the drm_driver.dumb_destroy defaultNoralf Trønnes1-1/+0
drm_gem_dumb_destroy() is the drm_driver.dumb_destroy default, so no need to set it. Cc: Chen Feng <[email protected]> Signed-off-by: Noralf Trønnes <[email protected]> Reviewed-by: Sean Paul <[email protected]> Link: https://patchwork.freedesktop.org/patch/msgid/[email protected]
2017-07-29drm/nouveau: Use the drm_driver.dumb_destroy defaultNoralf Trønnes1-1/+0
drm_gem_dumb_destroy() is the drm_driver.dumb_destroy default, so no need to set it. Cc: Ben Skeggs <[email protected]> Signed-off-by: Noralf Trønnes <[email protected]> Acked-by: Alex Deucher <[email protected]> Link: https://patchwork.freedesktop.org/patch/msgid/[email protected]
2017-07-29drm/omapdrm: Use the drm_driver.dumb_destroy defaultNoralf Trønnes1-1/+0
drm_gem_dumb_destroy() is the drm_driver.dumb_destroy default, so no need to set it. Cc: Tomi Valkeinen <[email protected]> Signed-off-by: Noralf Trønnes <[email protected]> Reviewed-by: Laurent Pinchart <[email protected]> Link: https://patchwork.freedesktop.org/patch/msgid/[email protected]
2017-07-29drm/amdgpu: Use the drm_driver.dumb_destroy defaultNoralf Trønnes1-1/+0
drm_gem_dumb_destroy() is the drm_driver.dumb_destroy default, so no need to set it. Cc: Alex Deucher <[email protected]> Cc: Christian König <[email protected]> Signed-off-by: Noralf Trønnes <[email protected]> Acked-by: Alex Deucher <[email protected]> Link: https://patchwork.freedesktop.org/patch/msgid/[email protected]
2017-07-29drm/rockchip: Use .dumb_map_offset and .dumb_destroy defaultsNoralf Trønnes3-31/+0
This driver can use the drm_driver.dumb_destroy and drm_driver.dumb_map_offset defaults, so no need to set them. Cc: Mark Yao <[email protected]> Signed-off-by: Noralf Trønnes <[email protected]> Reviewed-by: Sean Paul <[email protected]> Link: https://patchwork.freedesktop.org/patch/msgid/[email protected]
2017-07-29drm/mediatek: Use .dumb_map_offset and .dumb_destroy defaultsNoralf Trønnes3-30/+0
This driver can use the drm_driver.dumb_destroy and drm_driver.dumb_map_offset defaults, so no need to set them. Cc: CK Hu <[email protected]> Cc: Philipp Zabel <[email protected]> Signed-off-by: Noralf Trønnes <[email protected]> Acked-by: Philipp Zabel <[email protected]> Link: https://patchwork.freedesktop.org/patch/msgid/[email protected]
2017-07-29drm/tinydrm: Use .dumb_map_offset and .dumb_destroy defaultsNoralf Trønnes1-3/+1
tinydrm can use the drm_driver.dumb_destroy and drm_driver.dumb_map_offset defaults, so no need to set them. Signed-off-by: Noralf Trønnes <[email protected]> Reviewed-by: Sean Paul <[email protected]> Link: https://patchwork.freedesktop.org/patch/msgid/[email protected]
2017-07-29drm/zte: Use .dumb_map_offset and .dumb_destroy defaultsNoralf Trønnes1-2/+0
This driver can use the drm_driver.dumb_destroy and drm_driver.dumb_map_offset defaults, so no need to set them. Cc: Shawn Guo <[email protected]> Signed-off-by: Noralf Trønnes <[email protected]> Acked-by: Shawn Guo <[email protected]> Link: https://patchwork.freedesktop.org/patch/msgid/[email protected]
2017-07-29drm/vc4: Use .dumb_map_offset and .dumb_destroy defaultsNoralf Trønnes1-2/+0
This driver can use the drm_driver.dumb_destroy and drm_driver.dumb_map_offset defaults, so no need to set them. Cc: Eric Anholt <[email protected]> Signed-off-by: Noralf Trønnes <[email protected]> Reviewed-by: Eric Anholt <[email protected]> Link: https://patchwork.freedesktop.org/patch/msgid/[email protected]
2017-07-29drm/tilcdc: Use .dumb_map_offset and .dumb_destroy defaultsNoralf Trønnes1-2/+0
This driver can use the drm_driver.dumb_destroy and drm_driver.dumb_map_offset defaults, so no need to set them. Cc: Jyri Sarha <[email protected]> Cc: Tomi Valkeinen <[email protected]> Signed-off-by: Noralf Trønnes <[email protected]> Acked-by: Jyri Sarha <[email protected]> Link: https://patchwork.freedesktop.org/patch/msgid/[email protected]
2017-07-29drm/sun4i: Use .dumb_map_offset and .dumb_destroy defaultsNoralf Trønnes1-2/+0
This driver can use the drm_driver.dumb_destroy and drm_driver.dumb_map_offset defaults, so no need to set them. Cc: Maxime Ripard <[email protected]> Signed-off-by: Noralf Trønnes <[email protected]> Acked-by: Maxime Ripard <[email protected]> Link: https://patchwork.freedesktop.org/patch/msgid/[email protected]
2017-07-29drm/stm: Use .dumb_map_offset and .dumb_destroy defaultsNoralf Trønnes1-2/+0
This driver can use the drm_driver.dumb_destroy and drm_driver.dumb_map_offset defaults, so no need to set them. Cc: Yannick Fertre <[email protected]> Cc: Philippe Cornu <[email protected]> Cc: Benjamin Gaignard <[email protected]> Cc: Vincent Abriou <[email protected]> Signed-off-by: Noralf Trønnes <[email protected]> Tested-by: Philippe Cornu <[email protected]> Acked-by: Philippe Cornu <[email protected]> Link: https://patchwork.freedesktop.org/patch/msgid/[email protected]
2017-07-29drm/shmobile: Use .dumb_map_offset and .dumb_destroy defaultsNoralf Trønnes1-2/+0
This driver can use the drm_driver.dumb_destroy and drm_driver.dumb_map_offset defaults, so no need to set them. Cc: Laurent Pinchart <[email protected]> Signed-off-by: Noralf Trønnes <[email protected]> Reviewed-by: Laurent Pinchart <[email protected]> Link: https://patchwork.freedesktop.org/patch/msgid/[email protected]
2017-07-29drm/rcar-du: Use .dumb_map_offset and .dumb_destroy defaultsNoralf Trønnes1-2/+0
This driver can use the drm_driver.dumb_destroy and drm_driver.dumb_map_offset defaults, so no need to set them. Cc: Laurent Pinchart <[email protected]> Signed-off-by: Noralf Trønnes <[email protected]> Reviewed-by: Laurent Pinchart <[email protected]> Link: https://patchwork.freedesktop.org/patch/msgid/[email protected]
2017-07-29drm/pl111: Use .dumb_map_offset and .dumb_destroy defaultsNoralf Trønnes1-2/+0
This driver can use the drm_driver.dumb_destroy and drm_driver.dumb_map_offset defaults, so no need to set them. Cc: Eric Anholt <[email protected]> Signed-off-by: Noralf Trønnes <[email protected]> Reviewed-by: Eric Anholt <[email protected]> Link: https://patchwork.freedesktop.org/patch/msgid/[email protected]
2017-07-29drm/imx: Use .dumb_map_offset and .dumb_destroy defaultsNoralf Trønnes1-2/+0
This driver can use the drm_driver.dumb_destroy and drm_driver.dumb_map_offset defaults, so no need to set them. Cc: Philipp Zabel <[email protected]> Signed-off-by: Noralf Trønnes <[email protected]> Acked-by: Philipp Zabel <[email protected]> Link: https://patchwork.freedesktop.org/patch/msgid/[email protected]
2017-07-29drm/atmel-hlcdc: Use .dumb_map_offset and .dumb_destroy defaultsNoralf Trønnes1-2/+0
This driver can use the drm_driver.dumb_destroy and drm_driver.dumb_map_offset defaults, so no need to set them. Cc: Boris Brezillon <[email protected]> Signed-off-by: Noralf Trønnes <[email protected]> Acked-by: Boris Brezillon <[email protected]> Link: https://patchwork.freedesktop.org/patch/msgid/[email protected]
2017-07-29drm/arm: mali-dp: Use .dumb_map_offset and .dumb_destroy defaultsNoralf Trønnes1-2/+0
This driver can use the drm_driver.dumb_destroy and drm_driver.dumb_map_offset defaults, so no need to set them. Cc: Liviu Dudau <[email protected]> Cc: Brian Starkey <[email protected]> Signed-off-by: Noralf Trønnes <[email protected]> Acked-by: Brian Starkey <[email protected]> Link: https://patchwork.freedesktop.org/patch/msgid/[email protected]
2017-07-29drm/arm: hdlcd: Use .dumb_map_offset and .dumb_destroy defaultsNoralf Trønnes1-2/+0
This driver can use the drm_driver.dumb_destroy and drm_driver.dumb_map_offset defaults, so no need to set them. Cc: Liviu Dudau <[email protected]> Signed-off-by: Noralf Trønnes <[email protected]> Acked-by: Brian Starkey <[email protected]> Link: https://patchwork.freedesktop.org/patch/msgid/[email protected]
2017-07-29drm/arc: Use .dumb_map_offset and .dumb_destroy defaultsNoralf Trønnes1-2/+0
This driver can use the drm_driver.dumb_destroy and drm_driver.dumb_map_offset defaults, so no need to set them. Cc: Alexey Brodkin <[email protected]> Signed-off-by: Noralf Trønnes <[email protected]> Acked-by: Alexey Brodkin <[email protected]> Link: https://patchwork.freedesktop.org/patch/msgid/[email protected]
2017-07-29drm/dumb-buffers: Add defaults for .dumb_map_offset and .dumb_destroyNoralf Trønnes1-8/+18
Almost everyone did end up using GEM as bo, so this adds defaults for the drm_driver.dumb_destroy and drm_driver.dumb_map_offset callbacks. Signed-off-by: Noralf Trønnes <[email protected]> Reviewed-by: Eric Anholt <[email protected]> Reviewed-by: Sean Paul <[email protected]> Link: https://patchwork.freedesktop.org/patch/msgid/[email protected]
2017-07-29drm/gem: Add drm_gem_dumb_map_offset()Noralf Trønnes2-0/+37
Add a common drm_driver.dumb_map_offset function for GEM backed drivers. Signed-off-by: Noralf Trønnes <[email protected]> Reviewed-by: Philipp Zabel <[email protected]> Reviewed-by: Laurent Pinchart <[email protected]> Reviewed-by: Sean Paul <[email protected]> Link: https://patchwork.freedesktop.org/patch/msgid/[email protected]
2017-07-28drm/vc4: Convert more lock requirement comments to lockdep assertions.Eric Anholt1-3/+8
Since I do my development with lockdep on, this will help make sure I don't introduce bugs here. Signed-off-by: Eric Anholt <[email protected]> Link: https://patchwork.freedesktop.org/patch/msgid/[email protected] Reviewed-by: Daniel Vetter <[email protected]>
2017-07-28drm/vc4: Add an ioctl for labeling GEM BOs for summary statsEric Anholt7-66/+257
This has proven immensely useful for debugging memory leaks and overallocation (which is a rather serious concern on the platform, given that we typically run at about 256MB of CMA out of up to 1GB total memory, with framebuffers that are about 8MB ecah). The state of the art without this is to dump debug logs from every GL application, guess as to kernel allocations based on bo_stats, and try to merge that all together into a global picture of memory allocation state. With this, you can add a couple of calls to the debug build of the 3D driver and get a pretty detailed view of GPU memory usage from /debug/dri/0/bo_stats (or when we debug print to dmesg on allocation failure). The Mesa side currently labels at the gallium resource level (so you see that a 1920x20 pixmap has been created, presumably for the window system panel), but we could extend that to be even more useful with glObjectLabel() names being sent all the way down to the kernel. (partial) example of sorted debugfs output with Mesa labeling all resources: kernel BO cache: 16392kb BOs (3) tiling shadow 1920x1080: 8160kb BOs (1) resource 1920x1080@32/0: 8160kb BOs (1) scanout resource 1920x1080@32/0: 8100kb BOs (1) kernel: 8100kb BOs (1) v2: Use strndup_user(), use lockdep assertion instead of just a comment, fix an array[-1] reference, extend comment about name freeing. Signed-off-by: Eric Anholt <[email protected]> Link: https://patchwork.freedesktop.org/patch/msgid/[email protected] Reviewed-by: Chris Wilson <[email protected]>
2017-07-28drm/vc4: Start using u64_to_user_ptr.Eric Anholt1-6/+5
Chris Wilson pointed out this little cleanup in a review of new code, so let's fix up the code I was copying from. Signed-off-by: Eric Anholt <[email protected]> Link: https://patchwork.freedesktop.org/patch/msgid/[email protected] Reviewed-by: Daniel Vetter <[email protected]>
2017-07-27drm/amdgpu: fix header on gfx9 clear stateAlex Deucher1-20/+21
This got missed when we open sourced this. Reviewed-by: Christian König <[email protected]> Signed-off-by: Alex Deucher <[email protected]> Cc: [email protected]
2017-07-26Merge airlied/drm-next into drm-misc-nextSean Paul450-4384/+11728
Backmerge drm-next with -rc2 in it to pull in a couple stm patches that were previously incorrectly applied to -misc-next. By picking them up in the correct manner, git will hopefully fix any errant trees that are out in the wild. Signed-off-by: Sean Paul <[email protected]>
2017-07-27drm: linux-next: build failure after merge of the drm-misc treeStephen Rothwell1-3/+2
Hi all, After merging the drm-misc tree, today's linux-next build (x86_64 allmodconfig) failed like this: drivers/staging/vboxvideo/vbox_drv.c:235:2: error: unknown field 'set_busid' specified in initializer .set_busid = drm_pci_set_busid, ^ drivers/staging/vboxvideo/vbox_drv.c:235:15: error: 'drm_pci_set_busid' undeclared here (not in a function) .set_busid = drm_pci_set_busid, ^ drivers/staging/vboxvideo/vbox_drv.c: In function 'vbox_init': drivers/staging/vboxvideo/vbox_drv.c:273:9: error: implicit declaration of function 'drm_pci_init' [-Werror=implicit-function-declaration] return drm_pci_init(&driver, &vbox_pci_driver); ^ drivers/staging/vboxvideo/vbox_drv.c: In function 'vbox_exit': drivers/staging/vboxvideo/vbox_drv.c:278:2: error: implicit declaration of function 'drm_pci_exit' [-Werror=implicit-function-declaration] drm_pci_exit(&driver, &vbox_pci_driver); ^ Caused by commits 5c484cee7ef9 ("drm: Remove drm_driver->set_busid hook") 10631d724def ("drm/pci: Deprecate drm_pci_init/exit completely") interacting with commit dd55d44f4084 ("staging: vboxvideo: Add vboxvideo to drivers/staging") from the staging.current tree. I have applied the following merge fix patch - please check that it is correct. From: Stephen Rothwell <[email protected]> Date: Wed, 19 Jul 2017 11:41:01 +1000 Subject: [PATCH] drm: fixes for staging due to API changes in the drm core Signed-off-by: Stephen Rothwell <[email protected]> Signed-off-by: Dave Airlie <[email protected]>