1. 28 Nov, 2018 1 commit
  2. 22 Nov, 2018 2 commits
  3. 13 Jul, 2018 2 commits
  4. 25 Apr, 2018 1 commit
  5. 01 Feb, 2018 1 commit
  6. 12 Oct, 2017 1 commit
  7. 11 Aug, 2017 1 commit
  8. 04 Aug, 2017 1 commit
  9. 02 Aug, 2017 1 commit
  10. 06 Apr, 2017 1 commit
  11. 28 Feb, 2017 2 commits
  12. 15 Dec, 2016 1 commit
    • Ville Syrjälä's avatar
      drm: Nuke fb->bits_per_pixel · 272725c7
      Ville Syrjälä authored
      Replace uses of fb->bits_per_pixel with fb->format->cpp[0]*8.
      Less duplicated information is a good thing.
      
      Note that I didn't put parens around the cpp*8 in the below cocci script,
      on account of not wanting spurious parens all over the place. Instead I
      did the unsafe way, and tried to look over the entire diff to spot if
      any dangerous expressions were produced. I didn't see any.
      
      There are some cases where previously the code did X*bpp/8, so the
      division happened after the multiplication. Those are now just X*cpp
      so the division effectively happens before the multiplication,
      but that is perfectly fine since bpp is always a multiple of 8.
      
      @@
      struct drm_framebuffer *FB;
      expression E;
      @@
       drm_helper_mode_fill_fb_struct(...) {
      	...
      -	FB->bits_per_pixel = E;
      	...
       }
      
      @@
      struct drm_framebuffer *FB;
      expression E;
      @@
       i9xx_get_initial_plane_config(...) {
      	...
      -	FB->bits_per_pixel = E;
      	...
       }
      
      @@
      struct drm_framebuffer *FB;
      expression E;
      @@
       ironlake_get_initial_plane_config(...) {
      	...
      -	FB->bits_per_pixel = E;
      	...
       }
      
      @@
      struct drm_framebuffer *FB;
      expression E;
      @@
       skylake_get_initial_plane_config(...) {
      	...
      -	FB->bits_per_pixel = E;
      	...
       }
      
      @@
      struct drm_framebuffer FB;
      expression E;
      @@
      (
      - E * FB.bits_per_pixel / 8
      + E * FB.format->cpp[0]
      |
      - FB.bits_per_pixel / 8
      + FB.format->cpp[0]
      |
      - E * FB.bits_per_pixel >> 3
      + E * FB.format->cpp[0]
      |
      - FB.bits_per_pixel >> 3
      + FB.format->cpp[0]
      |
      - (FB.bits_per_pixel + 7) / 8
      + FB.format->cpp[0]
      |
      - FB.bits_per_pixel
      + FB.format->cpp[0] * 8
      |
      - FB.format->cpp[0] * 8 != 8
      + FB.format->cpp[0] != 1
      )
      
      @@
      struct drm_framebuffer *FB;
      expression E;
      @@
      (
      - E * FB->bits_per_pixel / 8
      + E * FB->format->cpp[0]
      |
      - FB->bits_per_pixel / 8
      + FB->format->cpp[0]
      |
      - E * FB->bits_per_pixel >> 3
      + E * FB->format->cpp[0]
      |
      - FB->bits_per_pixel >> 3
      + FB->format->cpp[0]
      |
      - (FB->bits_per_pixel + 7) / 8
      + FB->format->cpp[0]
      |
      - FB->bits_per_pixel
      + FB->format->cpp[0] * 8
      |
      - FB->format->cpp[0] * 8 != 8
      + FB->format->cpp[0] != 1
      )
      
      @@
      struct drm_plane_state *state;
      expression E;
      @@
      (
      - E * state->fb->bits_per_pixel / 8
      + E * state->fb->format->cpp[0]
      |
      - state->fb->bits_per_pixel / 8
      + state->fb->format->cpp[0]
      |
      - E * state->fb->bits_per_pixel >> 3
      + E * state->fb->format->cpp[0]
      |
      - state->fb->bits_per_pixel >> 3
      + state->fb->format->cpp[0]
      |
      - (state->fb->bits_per_pixel + 7) / 8
      + state->fb->format->cpp[0]
      |
      - state->fb->bits_per_pixel
      + state->fb->format->cpp[0] * 8
      |
      - state->fb->format->cpp[0] * 8 != 8
      + state->fb->format->cpp[0] != 1
      )
      
      @@
      @@
      - (8 * 8)
      + 8 * 8
      
      @@
      struct drm_framebuffer FB;
      @@
      - (FB.format->cpp[0])
      + FB.format->cpp[0]
      
      @@
      struct drm_framebuffer *FB;
      @@
      - (FB->format->cpp[0])
      + FB->format->cpp[0]
      
      @@
      @@
       struct drm_framebuffer {
      	 ...
      -	 int bits_per_pixel;
      	 ...
       };
      
      v2: Clean up the 'cpp*8 != 8' and '(8 * 8)' cases (Laurent)
      v3: Adjusted the semantic patch a bit and regenerated due to code
          changes
      Signed-off-by: Ville Syrjälä's avatarVille Syrjälä <ville.syrjala@linux.intel.com>
      Reviewed-by: Laurent Pinchart's avatarLaurent Pinchart <laurent.pinchart@ideasonboard.com>
      Reviewed-by: Alex Deucher <alexander.deucher@amd.com> (v1)
      Link: http://patchwork.freedesktop.org/patch/msgid/1481751140-18352-1-git-send-email-ville.syrjala@linux.intel.com
      272725c7
  13. 14 Dec, 2016 1 commit
  14. 01 Dec, 2016 1 commit
  15. 07 Jun, 2016 1 commit
  16. 17 May, 2016 1 commit
  17. 04 Mar, 2016 1 commit
  18. 16 Feb, 2016 1 commit
  19. 11 Dec, 2015 1 commit
  20. 11 Nov, 2015 1 commit
  21. 04 Nov, 2014 1 commit
  22. 07 Oct, 2014 1 commit
  23. 16 Sep, 2014 1 commit
  24. 18 Jul, 2014 1 commit
  25. 19 Jun, 2014 1 commit
  26. 19 May, 2014 3 commits
  27. 22 Apr, 2014 1 commit
    • Andrzej Hajda's avatar
      drm: make mode_valid callback optional · f9b0e251
      Andrzej Hajda authored
      Many drm connectors do not need mode validation.
      The patch makes this callback optional and removes dumb implementations.
      
      v2: Rebase:
      - imx move to a shared (but still dummy) ->mode_valid implementation.
      - probe helpers have been extracted to drm_probe_helper.c
      
      Signed-off-by: Andrzej Hajda <a.hajda@samsung.com> (v1)
      Signed-off-by: Daniel Vetter's avatarDaniel Vetter <daniel.vetter@ffwll.ch>
      f9b0e251
  28. 02 Apr, 2014 1 commit
    • Matt Roper's avatar
      drm: Replace crtc fb with primary plane fb (v3) · f4510a27
      Matt Roper authored
      Now that CRTC's have a primary plane, there's no need to track the
      framebuffer in the CRTC.  Replace all references to the CRTC fb with the
      primary plane's fb.
      
      This patch was generated by the Coccinelle semantic patching tool using
      the following rules:
      
              @@ struct drm_crtc C; @@
              -   (C).fb
              +   C.primary->fb
      
              @@ struct drm_crtc *C; @@
              -   (C)->fb
              +   C->primary->fb
      
      v3: Generate patch via coccinelle.  Actual removal of crtc->fb has been
          moved to a subsequent patch.
      
      v2: Fixup several lingering crtc->fb instances that were missed in the
          first patch iteration.  [Rob Clark]
      Signed-off-by: Matt Roper's avatarMatt Roper <matthew.d.roper@intel.com>
      Reviewed-by: Rob Clark's avatarRob Clark <robdclark@gmail.com>
      f4510a27
  29. 14 Jan, 2014 1 commit
    • Rashika's avatar
      drivers: gpu: Mark functions as static in ast_mode.c · 7f5ccd44
      Rashika authored
      Mark functions ast_set_sync_reg(), ast_set_dac_reg(),
      ast_set_start_address_crt1(), ast_crtc_init(), ast_encoder_init(),
      ast_connector_init(), ast_cursor_init(), ast_cursor_fini(),
      ast_show_cursor() and ast_hide_cursor() as static in drm/ast/ast_mode.c
      because they are not used outside this file.
      
      This eliminates the following warning in drm/ast/ast_mode.c:
      drivers/gpu/drm/ast/ast_mode.c:407:6: warning: no previous prototype for
      ‘ast_set_sync_reg’ [-Wmissing-prototypes]
      drivers/gpu/drm/ast/ast_mode.c:418:6: warning: no previous prototype for
      ‘ast_set_dac_reg’ [-Wmissing-prototypes]
      drivers/gpu/drm/ast/ast_mode.c:430:6: warning: no previous prototype for
      ‘ast_set_start_address_crt1’ [-Wmissing-prototypes]
      drivers/gpu/drm/ast/ast_mode.c:626:5: warning: no previous prototype for
      ‘ast_crtc_init’ [-Wmissing-prototypes]
      drivers/gpu/drm/ast/ast_mode.c:713:5: warning: no previous prototype for
      ‘ast_encoder_init’ [-Wmissing-prototypes]
      drivers/gpu/drm/ast/ast_mode.c:780:5: warning: no previous prototype for
      ‘ast_connector_init’ [-Wmissing-prototypes]
      drivers/gpu/drm/ast/ast_mode.c:813:5: warning: no previous prototype for
      ‘ast_cursor_init’ [-Wmissing-prototypes]
      drivers/gpu/drm/ast/ast_mode.c:850:6: warning: no previous prototype for
      ‘ast_cursor_fini’ [-Wmissing-prototypes]
      drivers/gpu/drm/ast/ast_mode.c:968:6: warning: no previous prototype for
      ‘ast_show_cursor’ [-Wmissing-prototypes]
      drivers/gpu/drm/ast/ast_mode.c:979:6: warning: no previous prototype for
      ‘ast_hide_cursor’ [-Wmissing-prototypes]
      Signed-off-by: default avatarRashika Kheria <rashika.kheria@gmail.com>
      Reviewed-by: Josh Triplett's avatarJosh Triplett <josh@joshtriplett.org>
      Signed-off-by: default avatarDave Airlie <airlied@redhat.com>
      7f5ccd44
  30. 03 Oct, 2012 1 commit
  31. 02 Oct, 2012 1 commit
  32. 02 Sep, 2012 1 commit
  33. 23 Aug, 2012 1 commit
  34. 20 Jul, 2012 1 commit
  35. 17 May, 2012 1 commit
    • Dave Airlie's avatar
      drm: Initial KMS driver for AST (ASpeed Technologies) 2000 series (v2) · 312fec14
      Dave Airlie authored
      This is the initial driver for the Aspeed Technologies chips found in
      servers. This driver supports the AST 2000, 2100, 2200, 2150 and 2300. It
      doesn't support the AST11xx due to lack of hw to test it on, and them requiring
      different codepaths.
      
      This driver is intended to be used with xf86-video-modesetting in userspace.
      
      This driver has a slightly different design than other KMS drivers, but
      future server chips will probably share similiar setup. As these GPUs commonly
      have low video RAM, it doesn't make sense to put the kms console in VRAM
      always. This driver places the kms console into system RAM, and does dirty
      updates to a copy in video RAM. When userspace sets a new scanout buffer,
      it forcefully evicts the video RAM console, and X can create a framebuffer
      that can use all of of video RAM.
      
      This driver uses TTM but in a very simple fashion to control the eviction
      to system RAM of the console, and multiple servers.
      
      v2: add s/r support, fix Kconfig.
      Signed-off-by: default avatarDave Airlie <airlied@redhat.com>
      312fec14