1. 26 4月, 2021 1 次提交
  2. 16 3月, 2021 1 次提交
    • N
      drm: Add GUD USB Display driver · 40e1a70b
      Noralf Trønnes 提交于
      This adds a USB display driver with the intention that it can be
      used with future USB interfaced low end displays/adapters. The Linux
      gadget device driver will serve as the canonical device implementation.
      
      The following DRM properties are supported:
      - Plane rotation
      - Connector TV properties
      
      There is also support for backlight brightness exposed as a backlight
      device.
      
      Display modes can be made available to the host driver either as DRM
      display modes or through EDID. If both are present, EDID is just passed
      on to userspace.
      
      Performance is preferred over color depth, so if the device supports
      RGB565, DRM_CAP_DUMB_PREFERRED_DEPTH will return 16.
      
      If the device transfer buffer can't fit an uncompressed framebuffer
      update, the update is split up into parts that do fit.
      
      Optimal user experience is achieved by providing damage reports either by
      setting FB_DAMAGE_CLIPS on pageflips or calling DRM_IOCTL_MODE_DIRTYFB.
      
      LZ4 compression is used if the device supports it.
      
      The driver supports a one bit monochrome transfer format: R1. This is not
      implemented in the gadget driver. It is added in preparation for future
      monochrome e-ink displays.
      
      The driver is MIT licensed to smooth the path for any BSD port of the
      driver.
      
      v2:
      - Use devm_drm_dev_alloc() and drmm_mode_config_init()
      - drm_fbdev_generic_setup: Use preferred_bpp=0, 16 was a copy paste error
      - The drm_backlight_helper is dropped, copy in the code
      - Support protocol version backwards compatibility for device
      
      v3:
      - Use donated Openmoko USB pid
      - Use direct compression from framebuffer when pitch matches, not only on
        full frames, so split updates can benefit
      - Use __le16 in struct gud_drm_req_get_connector_status
      - Set edid property when the device only provides edid
      - Clear compression fields in struct gud_drm_req_set_buffer
      - Fix protocol version negotiation
      - Remove mode->vrefresh, it's calculated
      
      v4:
      - Drop the status req polling which was a workaround for something that
        turned out to be a dwc2 udc driver problem
      - Add a flag for the Linux gadget to require a status request on
        SET operations. Other devices will only get status req on STALL errors
      - Use protocol specific error codes (Peter)
      - Add a flag for devices that want to receive the entire framebuffer on
        each flush (Lubomir)
      - Retry a failed framebuffer flush
      - If mode has changed wait for worker and clear pending damage before
        queuing up new damage, fb width/height might have changed
      - Increase error counter on bulk transfer failures
      - Use DRM_MODE_CONNECTOR_USB
      - Handle R1 kmalloc error (Peter)
      - Don't try and replicate the USB get descriptor request standard for the
        display descriptor (Peter)
      - Make max_buffer_size optional (Peter), drop the pow2 requirement since
        it's not necessary anymore.
      - Don't pre-alloc a control request buffer, it was only 4k
      - Let gud.h describe the whole protocol explicitly and don't let DRM
        leak into it (Peter)
      - Drop display mode .hskew and .vscan from the protocol
      - Shorten names: s/GUD_DRM_/GUD_/ s/gud_drm_/gud_/ (Peter)
      - Fix gud_pipe_check() connector picking when switching connector
      - Drop gud_drm_driver_gem_create_object() cached is default now
      - Retrieve USB device from struct drm_device.dev instead of keeping a
        pointer
      - Honour fb->offsets[0]
      - Fix mode fetching when connector status is forced
      - Check EDID length reported by the device
      - Use drm_do_get_edid() so userspace can overrride EDID
      - Set epoch counter to signal connector status change
      - gud_drm_driver can be const now
      
      v5:
      - GUD_DRM_FORMAT_R1: Use non-human ascii values (Daniel)
      - Change name to: GUD USB Display (Thomas, Simon)
      - Change one __u32 -> __le32 in protocol header
      - Always log fb flush errors, unless the previous one failed
      - Run backlight update in a worker to avoid upsetting lockdep (Daniel)
      - Drop backlight_ops.get_brightness, there's no readback from the device
        so it doesn't really add anything.
      - Set dma mask, needed by dma-buf importers
      
      v6:
      - Use obj-y in Makefile (Peter)
      - Fix missing le32_to_cpu() when using GUD_DISPLAY_MAGIC (Peter)
      - Set initial brightness on backlight device
      
      v7:
      - LZ4_compress_default() can return zero, check for that
      - Fix memory leak in gud_pipe_check() error path (Peter)
      - Improve debug and error messages (Peter)
      - Don't pass length in protocol structs (Peter)
      - Pass USB interface to gud_usb_control_msg() et al. (Peter)
      - Improve gud_connector_fill_properties() (Peter)
      - Add GUD_PIXEL_FORMAT_RGB111 (Peter)
      - Remove GUD_REQ_SET_VERSION (Peter)
      - Fix DRM_IOCTL_MODE_OBJ_SETPROPERTY and the rotation property
      - Fix dma-buf import (Thomas)
      
      v8:
      - Forgot to filter RGB111 from reaching userspace
      - Handle a device that only returns unknown device properties (Peter)
      - s/GUD_PIXEL_FORMAT_RGB111/GUD_PIXEL_FORMAT_XRGB1111/ (Peter)
      - Fix R1 and XRGB1111 format conversion
      - Add FIXME about Big Endian being broken (Peter, Ilia)
      
      Cc: Lubomir Rintel <lkundrak@v3.sk>
      Acked-by: NDaniel Vetter <daniel.vetter@ffwll.ch>
      Reviewed-by: NPeter Stuge <peter@stuge.se>
      Tested-by: NPeter Stuge <peter@stuge.se>
      Signed-off-by: NNoralf Trønnes <noralf@tronnes.org>
      Link: https://patchwork.freedesktop.org/patch/msgid/20210313112545.37527-4-noralf@tronnes.org
      40e1a70b
  3. 11 3月, 2021 1 次提交
  4. 25 2月, 2021 1 次提交
  5. 16 2月, 2021 1 次提交
  6. 13 1月, 2021 1 次提交
  7. 09 11月, 2020 1 次提交
  8. 06 11月, 2020 1 次提交
  9. 29 10月, 2020 1 次提交
  10. 16 10月, 2020 1 次提交
  11. 18 7月, 2020 1 次提交
    • H
      drm: xlnx: DRM/KMS driver for Xilinx ZynqMP DisplayPort Subsystem · d76271d2
      Hyun Kwon 提交于
      The Xilinx ZynqMP SoC has a hardened display pipeline named DisplayPort
      Subsystem. It includes a buffer manager, a video pipeline renderer
      (blender), an audio mixer and a DisplayPort source controller
      (transmitter). The DMA engine the provide data to the buffer manager, as
      well as the DisplayPort PHYs that drive the lanes, are external to the
      subsystem and interfaced using the DMA engine and PHY APIs respectively.
      
      This driver supports the DisplayPort Subsystem and implements
      
      - Two planes, for graphics and video
      - One CRTC that supports alpha blending
      - One encoder for the DisplayPort transmitter
      - One connector for an external monitor
      
      It currently doesn't support
      
      - Color keying
      - Test pattern generation
      - Audio
      - Live input from the Programmable Logic (FPGA)
      - Output to the Programmable Logic (FPGA)
      Signed-off-by: NHyun Kwon <hyun.kwon@xilinx.com>
      Signed-off-by: NLaurent Pinchart <laurent.pinchart@ideasonboard.com>
      d76271d2
  12. 28 4月, 2020 1 次提交
  13. 21 4月, 2020 1 次提交
  14. 06 3月, 2020 1 次提交
  15. 28 1月, 2020 1 次提交
    • J
      drm/tidss: New driver for TI Keystone platform Display SubSystem · 32a1795f
      Jyri Sarha 提交于
      This patch adds a new DRM driver for Texas Instruments DSS IPs used on
      Texas Instruments Keystone K2G, AM65x, and J721e SoCs. The new DSS IP is
      a major change to the older DSS IP versions, which are supported by
      the omapdrm driver. While on higher level the Keystone DSS resembles
      the older DSS versions, the registers are completely different and the
      internal pipelines differ a lot.
      
      DSS IP found on K2G is an "ultra-light" version, and has only a single
      plane and a single output. The K3 DSS IPs are found on AM65x and J721E
      SoCs. AM65x DSS has two video ports, one full video plane, and another
      "lite" plane without scaling support. J721E has 4 video ports, 2 video
      planes and 2 lite planes. AM65x DSS has also an integrated OLDI (LVDS)
      output.
      
      Version history:
      
      v2: - rebased on top of drm-next-2019-11-27
          - sort all include lines in all files
          - remove all include <drm/drmP.h>
          - remove select "select VIDEOMODE_HELPERS"
          - call dispc_vp_setup() later in tidss_crtc_atomic_flush() (there is no
            to call it in new modeset case as it is also called in vp_enable())
          - change probe sequence and drm_device allocation (follow example in
            drm_drv.c)
          - use __maybe_unused instead of #ifdef for pm functions
          - remove "struct drm_fbdev_cma *fbdev;" from driver data
          - check panel connector type before connecting it
      
      v3: no change
      
      v4: no change
      
      v5: - remove fifo underflow irq handling, it is not an error and
            it should be used for debug purposes only
          - memory tuning, prefetch plane fifo up to high-threshold value to
            minimize possibility of underflows.
      
      v6: - Check CTM and gamma support from dispc_features when creating crtc
          - Implement CTM support for k2g and fix k3 CTM implementation
          - Remove gamma property persistence and always write color properties
            in a new modeset
      
      v7: - Fix checkpatch.pl --strict issues
          - Rebase on top of drm-misc-next-2020-01-10
      
      v8: - Remove idle debug prints from dispc_init()
          - Add Reviewed-by: Benoit Parrot <bparrot@ti.com>
      
      v9: - Rename dispc_write_irqenable() to dispc_set_irqenable() to avoid
            conflict exported omapfb function with same name
          - Add Signed-off-by: Tomi Valkeinen <tomi.valkeinen@ti.com>
      Co-developed-by: NTomi Valkeinen <tomi.valkeinen@ti.com>
      Signed-off-by: NJyri Sarha <jsarha@ti.com>
      Acked-by: NSam Ravnborg <sam@ravnborg.org>
      Reviewed-by: NBenoit Parrot <bparrot@ti.com>
      Signed-off-by: NTomi Valkeinen <tomi.valkeinen@ti.com>
      Link: https://patchwork.freedesktop.org/patch/msgid/925fbfad58ff828e8e07fdff7073a0ee65750c3d.1580129724.git.jsarha@ti.com
      32a1795f
  16. 09 1月, 2020 1 次提交
  17. 04 12月, 2019 1 次提交
  18. 20 11月, 2019 1 次提交
  19. 14 11月, 2019 1 次提交
  20. 08 11月, 2019 1 次提交
  21. 25 10月, 2019 1 次提交
    • L
      drm/dp_mst: Add topology ref history tracking for debugging · 12a280c7
      Lyude Paul 提交于
      For very subtle mistakes with topology refs, it can be rather difficult
      to trace them down with the debugging info that we already have. I had
      one such issue recently while trying to implement suspend/resume
      reprobing for MST, and ended up coming up with this.
      
      Inspired by Chris Wilson's wakeref tracking for i915, this adds a very
      similar feature to the DP MST helpers, which allows for partial tracking
      of topology refs for both ports and branch devices. This is a lot less
      advanced then wakeref tracking: we merely keep a count of all of the
      spots where a topology ref has been grabbed or dropped, then dump out
      that history in chronological order when a port or branch device's
      topology refcount reaches 0. So far, I've found this incredibly useful
      for debugging topology refcount errors.
      
      Since this has the potential to be somewhat slow and loud, we add an
      expert kernel config option to enable or disable this feature,
      CONFIG_DRM_DEBUG_DP_MST_TOPOLOGY_REFS.
      
      Changes since v1:
      * Don't forget to destroy topology_ref_history_lock
      Changes since v4:
      * Correct order of kref_put()/topology_ref_history_unlock - we can't
        unlock the history after kref_put() since the memory might have been
        freed by that point
      * Don't print message on allocation error failures, the kernel already
        does this for us
      Changes since v5:
      * Get rid of some leftover usages of %px
      * Remove a leftover empty return; statement
      
      Cc: Juston Li <juston.li@intel.com>
      Cc: Imre Deak <imre.deak@intel.com>
      Cc: Ville Syrjälä <ville.syrjala@linux.intel.com>
      Cc: Harry Wentland <hwentlan@amd.com>
      Cc: Daniel Vetter <daniel.vetter@ffwll.ch>
      Reviewed-by: NSean Paul <sean@poorly.run>
      Signed-off-by: NLyude Paul <lyude@redhat.com>
      Link: https://patchwork.freedesktop.org/patch/msgid/20191022023641.8026-15-lyude@redhat.com
      12a280c7
  22. 17 10月, 2019 1 次提交
  23. 09 10月, 2019 1 次提交
  24. 08 10月, 2019 1 次提交
  25. 10 9月, 2019 3 次提交
  26. 31 7月, 2019 3 次提交
  27. 25 7月, 2019 1 次提交
  28. 22 7月, 2019 1 次提交
  29. 15 7月, 2019 1 次提交
  30. 19 6月, 2019 1 次提交
    • P
      DRM: Add KMS driver for the Ingenic JZ47xx SoCs · 90b86fcc
      Paul Cercueil 提交于
      Add a KMS driver for the Ingenic JZ47xx family of SoCs.
      This driver is meant to replace the aging jz4740-fb driver.
      
      This driver does not make use of the simple pipe helper, for the reason
      that it will soon be updated to support more advanced features like
      multiple planes, IPU integration for colorspace conversion and up/down
      scaling, support for DSI displays, and TV-out and HDMI outputs.
      
      Notes:
          v2: - Remove custom handling of panel. The panel is now discovered using
                the standard API.
              - Lots of small tweaks suggested by upstream
      
          v3: - Use devm_drm_dev_init()
              - Update compatible strings to -lcd instead of -drm
              - Add destroy() callbacks to plane and crtc
              - The ingenic,lcd-mode is now read from the bridge's DT node
      
          v4: Remove ingenic,lcd-mode property completely. The various modes are now
              deduced from the connector type, the pixel format or the bus flags.
      
          v5: - Fix framebuffer size incorrectly calculated for 24bpp framebuffers
              - Use 32bpp framebuffer instead of 16bpp, as it'll work with both
                16-bit and 24-bit panel
              - Get rid of drm_format_plane_cpp() which has been dropped upstream
              - Avoid using drm_format_info->depth, which is deprecated.
      Signed-off-by: NPaul Cercueil <paul@crapouillou.net>
      Tested-by: NArtur Rojek <contact@artur-rojek.eu>
      Reviewed-by: NSam Ravnborg <sam@ravnborg.org>
      Signed-off-by: NSam Ravnborg <sam@ravnborg.org>
      Link: https://patchwork.freedesktop.org/patch/msgid/20190603152331.23160-2-paul@crapouillou.net
      90b86fcc
  31. 15 6月, 2019 1 次提交
  32. 24 5月, 2019 1 次提交
  33. 21 5月, 2019 1 次提交
  34. 15 5月, 2019 1 次提交
    • T
      drm: Add |struct drm_gem_vram_object| and helpers · 85438a8d
      Thomas Zimmermann 提交于
      The type |struct drm_gem_vram_object| implements a GEM object for simple
      framebuffer devices with dedicated video memory. The BO is either located
      in VRAM or system memory.
      
      The implementation has been created from the respective code in ast,
      bochs and mgag200. These drivers copy their implementation from each
      other; except for the names of several data types. The helpers are
      currently build with TTM, but this is considered an implementation
      detail and may change in future updates.
      
      v5:
      	* do WARN_ON_ONCE for pin-count mismatches
      	* allocate only 2 entries in placements array
      v4:
      	* cleanups from checkpatch.pl
      	* removed several fixed-size types from interfaces
      	* DRM_VRAM_HELPER now selects DRM_TTM
      	* remove separate config option for GEM VRAM
      v2:
      	* rename to |struct drm_gem_vram_object|
      	* move drm_is_gem_ttm() to a later patch in the series
      	* add drm_gem_vram_kmap_at()
      	* return is_iomem from kmap functions
      	* redefine TTM placement flags for public interface
      	* documentation fixes
      Signed-off-by: NThomas Zimmermann <tzimmermann@suse.de>
      Link: http://patchwork.freedesktop.org/patch/msgid/20190508082630.15116-2-tzimmermann@suse.deSigned-off-by: NGerd Hoffmann <kraxel@redhat.com>
      85438a8d
  35. 24 4月, 2019 1 次提交
  36. 13 4月, 2019 1 次提交
    • R
      drm/panfrost: Add initial panfrost driver · f3ba9122
      Rob Herring 提交于
      This adds the initial driver for panfrost which supports Arm Mali
      Midgard and Bifrost family of GPUs. Currently, only the T860 and
      T760 Midgard GPUs have been tested.
      
      v2:
      - Add GPU reset on job hangs (Tomeu)
      - Add RuntimePM and devfreq support (Tomeu)
      - Fix T760 support (Tomeu)
      - Add a TODO file (Rob, Tomeu)
      - Support multiple in fences (Tomeu)
      - Drop support for shared fences (Tomeu)
      - Fill in MMU de-init (Rob)
      - Move register definitions back to single header (Rob)
      - Clean-up hardcoded job submit todos (Rob)
      - Implement feature setup based on features/issues (Rob)
      - Add remaining Midgard DT compatible strings (Rob)
      
      v3:
      - Add support for reset lines (Neil)
      - Add a MAINTAINERS entry (Rob)
      - Call dma_set_mask_and_coherent (Rob)
      - Do MMU invalidate on map and unmap. Restructure to do a single
        operation per map/unmap call. (Rob)
      - Add a missing explicit padding to struct drm_panfrost_create_bo (Rob)
      - Fix 0-day error: "panfrost_devfreq.c:151:9-16: ERROR: PTR_ERR applied after initialization to constant on line 150"
      - Drop HW_FEATURE_AARCH64_MMU conditional (Rob)
      - s/DRM_PANFROST_PARAM_GPU_ID/DRM_PANFROST_PARAM_GPU_PROD_ID/ (Rob)
      - Check drm_gem_shmem_prime_import_sg_table() error code (Rob)
      - Re-order power on sequence (Rob)
      - Move panfrost_acquire_object_fences() before scheduling job (Rob)
      - Add NULL checks on array pointers in job clean-up (Rob)
      - Rework devfreq (Tomeu)
      - Fix devfreq init with no regulator (Rob)
      - Various WS and comments clean-up (Rob)
      
      Cc: Maarten Lankhorst <maarten.lankhorst@linux.intel.com>
      Cc: Maxime Ripard <maxime.ripard@bootlin.com>
      Cc: Sean Paul <sean@poorly.run>
      Cc: David Airlie <airlied@linux.ie>
      Cc: Daniel Vetter <daniel@ffwll.ch>
      Cc: Lyude Paul <lyude@redhat.com>
      Reviewed-by: NAlyssa Rosenzweig <alyssa@rosenzweig.io>
      Reviewed-by: NEric Anholt <eric@anholt.net>
      Reviewed-by: NSteven Price <steven.price@arm.com>
      Signed-off-by: NMarty E. Plummer <hanetzer@startmail.com>
      Signed-off-by: NTomeu Vizoso <tomeu.vizoso@collabora.com>
      Signed-off-by: NNeil Armstrong <narmstrong@baylibre.com>
      Signed-off-by: NRob Herring <robh@kernel.org>
      Link: https://patchwork.freedesktop.org/patch/msgid/20190409205427.6943-4-robh@kernel.org
      f3ba9122