1. 31 5月, 2016 1 次提交
    • L
      vga_switcheroo: Add helper for deferred probing · b00e5334
      Lukas Wunner 提交于
      So far we've got one condition when DRM drivers need to defer probing
      on a dual GPU system and it's coded separately into each of the relevant
      drivers. As suggested by Daniel Vetter, deduplicate that code in the
      drivers and move it to a new vga_switcheroo helper. This yields better
      encapsulation of concepts and lets us add further checks in a central
      place. (The existing check pertains to pre-retina MacBook Pros and an
      additional check is expected to be needed for retinas.)
      
      One might be tempted to check deferred probing conditions in
      vga_switcheroo_register_client(), but this is usually called fairly late
      during driver load. The GPU is fully brought up and ready for switching
      at that point. On boot the ->probe hook is potentially called dozens of
      times until it finally succeeds, and each time we'd repeat bringup and
      teardown of the GPU, lengthening boot time considerably and cluttering
      logfiles. A separate helper is therefore needed which can be called
      right at the beginning of the ->probe hook.
      
      Note that amdgpu currently does not call this helper as the AMD GPUs
      built into MacBook Pros are only supported by radeon so far.
      
      v2: This helper could eventually be used by audio clients as well,
          so rephrase kerneldoc to refer to "client" instead of "GPU"
          and move the single existing check in an if block specific
          to PCI_CLASS_DISPLAY_VGA devices. Move documentation on
          that check from kerneldoc to a comment. (Daniel Vetter)
      
      v3: Mandate in kerneldoc that registration of client shall only
          happen after calling this helper. (Daniel Vetter)
      
      v4: Rebase on 412c8f7d ("drm/radeon: Return -EPROBE_DEFER when
          amdkfd not loaded")
      
      v5: Some Optimus GPUs use PCI_CLASS_DISPLAY_3D, make sure those are
          matched as well. (Emil Velikov)
      
      v6: The if-condition referring to PCI_BASE_CLASS_DISPLAY may be
          considered a functional change. Move to a separate commit to
          keep this a pure refactoring change. (Emil Velikov, Jani Nikula)
      
      Cc: Daniel Vetter <daniel.vetter@ffwll.ch>
      Cc: Ben Skeggs <bskeggs@redhat.com>
      Cc: Alex Deucher <alexander.deucher@amd.com>
      Signed-off-by: NLukas Wunner <lukas@wunner.de>
      Signed-off-by: NDaniel Vetter <daniel.vetter@ffwll.ch>
      Link: http://patchwork.freedesktop.org/patch/msgid/575885fd440c2b13c3f19ddf44360cfbbff35f50.1464685538.git.lukas@wunner.de
      b00e5334
  2. 20 5月, 2016 1 次提交
  3. 30 3月, 2016 1 次提交
  4. 14 3月, 2016 3 次提交
  5. 09 2月, 2016 1 次提交
  6. 11 1月, 2016 7 次提交
  7. 15 12月, 2015 2 次提交
  8. 03 11月, 2015 2 次提交
  9. 16 10月, 2015 1 次提交
  10. 07 10月, 2015 1 次提交
  11. 28 8月, 2015 16 次提交
  12. 27 7月, 2015 2 次提交
  13. 02 7月, 2015 1 次提交
    • P
      drm: Turn off Legacy Context Functions · 0e975980
      Peter Antoine 提交于
      The context functions are not used by the i915 driver and should not
      be used by modeset drivers. These driver functions contain several bugs
      and security holes. This change makes these functions optional can be
      turned on by a setting, they are turned off by default for modeset
      driver with the exception of the nouvea driver that may require them with
      an old version of libdrm.
      
      The previous attempt was
      
      commit 7c510133
      Author: Daniel Vetter <daniel.vetter@ffwll.ch>
      Date:   Thu Aug 8 15:41:21 2013 +0200
      
          drm: mark context support as a legacy subsystem
      
      but this had to be reverted
      
      commit c21eb21c
      Author: Dave Airlie <airlied@redhat.com>
      Date:   Fri Sep 20 08:32:59 2013 +1000
      
          Revert "drm: mark context support as a legacy subsystem"
      
      v2: remove returns from void function, and formatting (Daniel Vetter)
      
      v3:
      - s/Nova/nouveau/ in the commit message, and add references to the
        previous attempts
      - drop the part touching the drm hw lock, that should be a separate
        patch.
      
      Signed-off-by: Peter Antoine <peter.antoine@intel.com> (v2)
      Cc: Peter Antoine <peter.antoine@intel.com> (v2)
      Reviewed-by: NPeter Antoine <peter.antoine@intel.com>
      Signed-off-by: NDaniel Vetter <daniel.vetter@ffwll.ch>
      0e975980
  14. 26 6月, 2015 1 次提交