1. 07 11月, 2014 1 次提交
  2. 19 8月, 2014 1 次提交
  3. 17 7月, 2014 1 次提交
    • M
      drm/radeon: Prevent too early kms-pageflips triggered by vblank. · f53f81b2
      Mario Kleiner 提交于
      Since 3.16-rc1 we have this new failure:
      
      When the userspace XOrg ddx schedules vblank events to
      trigger deferred kms-pageflips, e.g., via the OML_sync_control
      extension call glXSwapBuffersMscOML(), or if a glXSwapBuffers()
      is called immediately after completion of a previous swapbuffers
      call, e.g., in a tight rendering loop with minimal rendering,
      it happens frequently that the pageflip ioctl() is executed
      within the same vblank in which a previous kms-pageflip completed,
      or - for deferred swaps - always one vblank earlier than requested
      by the client app.
      
      This causes premature pageflips and detection of failure by
      the ddx, e.g., XOrg log warnings like...
      
      "(WW) RADEON(1): radeon_dri2_flip_event_handler: Pageflip
      completion event has impossible msc 201025 < target_msc 201026"
      
      ... and error/invalid return values of glXWaitForSbcOML() and
      Intel_swap_events extension.
      
      Reason is the new way in which kms-pageflips are programmed
      since 3.16.
      
      This commit changes the time window in which the hw can
      execute pending programmed pageflips. Before, a pending flip
      would get executed anywhere within the vblank interval. Now
      a pending flip only gets executed at the leading edge of
      vblank (start of front porch), making sure that a invocation
      of the pageflip ioctl() within a given vblank interval will
      only lead to pageflip completion in the following vblank.
      
      Tested to death on a DCE-4 card.
      Signed-off-by: NMario Kleiner <mario.kleiner.de@gmail.com>
      Signed-off-by: NAlex Deucher <alexander.deucher@amd.com>
      f53f81b2
  4. 07 3月, 2014 1 次提交
  5. 25 12月, 2013 1 次提交
    • A
      drm/radeon/pm: move pm handling into the asic specific code · 6c7bccea
      Alex Deucher 提交于
      We need more control over the ordering of dpm init with
      respect to the rest of the asic.  Specifically, the SMC
      has to be initialized before the rlc and cg/pg.  The pm
      code currently initializes late in the driver, but we need
      it to happen much earlier so move pm handling into the asic
      specific callbacks.
      
      This makes dpm more reliable and makes clockgating work
      properly on CIK parts and should help on SI parts as well.
      Signed-off-by: NAlex Deucher <alexander.deucher@amd.com>
      6c7bccea
  6. 09 11月, 2013 1 次提交
  7. 11 9月, 2013 1 次提交
  8. 27 6月, 2013 1 次提交
  9. 03 6月, 2013 1 次提交
    • A
      radeon: Fix system hang issue when using KMS with older cards · e49f3959
      Adis Hamzić 提交于
      The current radeon driver initialization routines, when using KMS, are written
      so that the IRQ installation routine is called before initializing the WB buffer
      and the CP rings. With some ASICs, though, the IRQ routine tries to access the
      GFX_INDEX ring causing a call to RREG32 with the value of -1 in
      radeon_fence_read. This, in turn causes the system to completely hang with some
      cards, requiring a hard reset.
      
      A call stack that can cause such a hang looks like this (using rv515 ASIC for the
      example here):
       * rv515_init (rv515.c)
       * radeon_irq_kms_init (radeon_irq_kms.c)
       * drm_irq_install (drm_irq.c)
       * radeon_driver_irq_preinstall_kms (radeon_irq_kms.c)
       * rs600_irq_process (rs600.c)
       * radeon_fence_process - due to SW interrupt (radeon_fence.c)
       * radeon_fence_read (radeon_fence.c)
       * hang due to RREG32(-1)
      
      The patch moves the IRQ installation to the card startup routine, after the ring
      has been initialized, but before the IRQ has been set. This fixes the issue, but
      requires a check to see if the IRQ is already installed, as is the case in the
      system resume codepath.
      I have tested the patch on three machines using the rv515, the rv770 and the
      evergreen ASIC. They worked without issues.
      
      This seems to be a known issue and has been reported on several bug tracking
      sites by various distributions (see links below). Most of reports recommend
      booting the system with KMS disabled and then enabling KMS by reloading the
      radeon module. For some reason, this was indeed a usable workaround, however,
      UMS is now deprecated and disabled by default.
      
      Bug reports:
      https://bugzilla.redhat.com/show_bug.cgi?id=845745
      https://bugs.launchpad.net/ubuntu/+source/linux/+bug/561789
      https://bbs.archlinux.org/viewtopic.php?id=156964Signed-off-by: NAdis Hamzić <adis@hamzadis.com>
      Signed-off-by: NAlex Deucher <alexander.deucher@amd.com>
      Cc: stable@vger.kernel.org
      e49f3959
  10. 22 4月, 2013 2 次提交
  11. 08 4月, 2013 1 次提交
  12. 01 2月, 2013 1 次提交
  13. 13 12月, 2012 1 次提交
  14. 03 10月, 2012 1 次提交
  15. 21 9月, 2012 1 次提交
  16. 13 8月, 2012 1 次提交
    • J
      drm/radeon: do not reenable crtc after moving vram start address · 81ee8fb6
      Jerome Glisse 提交于
      It seems we can not update the crtc scanout address. After disabling
      crtc, update to base address do not take effect after crtc being
      reenable leading to at least frame being scanout from the old crtc
      base address. Disabling crtc display request lead to same behavior.
      
      So after changing the vram address if we don't keep crtc disabled
      we will have the GPU trying to read some random system memory address
      with some iommu this will broke the crtc engine and will lead to
      broken display and iommu error message.
      
      So to avoid this, disable crtc. For flicker less boot we will need
      to avoid moving the vram start address.
      
      This patch should also fix :
      
      https://bugs.freedesktop.org/show_bug.cgi?id=42373
      
      Cc: <stable@vger.kernel.org>
      Signed-off-by: NJerome Glisse <jglisse@redhat.com>
      81ee8fb6
  17. 17 7月, 2012 2 次提交
  18. 03 5月, 2012 1 次提交
  19. 29 2月, 2012 1 次提交
  20. 22 2月, 2012 1 次提交
  21. 06 2月, 2012 1 次提交
  22. 21 12月, 2011 6 次提交
  23. 17 2月, 2011 1 次提交
  24. 27 1月, 2011 1 次提交
  25. 06 10月, 2010 1 次提交
    • A
      drm/radeon/kms: enable writeback (v2) · 724c80e1
      Alex Deucher 提交于
      When writeback is enabled, the GPU shadows writes to certain
      registers into a buffer in memory.  The driver can then read
      the values from the shadow rather than reading back from the
      register across the bus.  Writeback can be disabled by setting
      the no_wb module param to 1.
      
      On r6xx/r7xx/evergreen, the following registers are shadowed:
      - CP scratch registers
      - CP read pointer
      - IH write pointer
      On r1xx-rr5xx, the following registers are shadowed:
      - CP scratch registers
      - CP read pointer
      
      v2:
      - Combine wb patches for r6xx-evergreen and r1xx-r5xx
      - Writeback is disabled on AGP boards since it tends to be
      unreliable on AGP using the gart.
      - Check radeon_wb_init return values properly.
      Signed-off-by: NAlex Deucher <alexdeucher@gmail.com>
      Signed-off-by: NDave Airlie <airlied@redhat.com>
      724c80e1
  26. 04 8月, 2010 1 次提交
  27. 02 8月, 2010 1 次提交
    • D
      drm/radeon/kms: check/restore sanity before doing anything else with GPU. · 4c712e6c
      Dave Airlie 提交于
      On systems using kexec, the new kernel is booted straight from the old kernel, without any warning to the graphics driver. So the GPU is basically left as-is in a running state, however the CPU side is completly reset.
      
      Without stating the saneness of anyone using kexec on live systems, we should at least try not to crash the GPU. This patch resets 3 registers to 0 that could cause bad things to happen to the running system.
      
      This allows kexec to work on a Power6/RN50 system.
      Signed-off-by: NDave Airlie <airlied@redhat.com>
      4c712e6c
  28. 16 7月, 2010 1 次提交
    • A
      drm/radeon/kms: fix gtt MC base alignment on rs4xx/rs690/rs740 asics · 8d369bb1
      Alex Deucher 提交于
      The asics in question have the following requirements with regard to
      their gart setups:
      
      1. The GART aperture size has to be in the form of 2^X bytes, where X is from 25 to 31
      2. The GART aperture MC base has to be aligned to a boundary equal to the size of the
      aperture.
      3. The GART page table has to be aligned to the boundary equal to the size of the table.
      4. The GART page table size is: table_entry_size * (aperture_size / page_size)
      5. The GART page table has to be allocated in non-paged, non-cached, contiguous system
      memory.
      
      This patch takes care 2.  The rest should already be handled properly.
      
      This fixes a regression noticed by: Torsten Kaiser <just.for.lkml@googlemail.com>
      Tested-by: NTorsten Kaiser <just.for.lkml@googlemail.com>
      Signed-off-by: NAlex Deucher <alexdeucher@gmail.com>
      Signed-off-by: NDave Airlie <airlied@redhat.com>
      8d369bb1
  29. 18 5月, 2010 2 次提交
    • A
      drm/radeon/kms/pm: rework power management · ce8f5370
      Alex Deucher 提交于
      - Separate dynpm and profile based power management methods.  You can select the pm method
        by echoing the selected method ("dynpm" or "profile") to power_method in sysfs.
      - Expose basic 4 profile in profile method
        "default" - default clocks
        "auto" - select between low and high based on ac/dc state
        "low" - DC, low power mode
        "high" - AC, performance mode
        The current base profile is "default", but it should switched to "auto" once we've tested
        on more systems.  Switching the state is a matter of echoing the requested profile to
        power_profile in sysfs.  The lowest power states are selected automatically when dpms turns
        the monitors off in all states but default.
      - Remove dynamic fence-based reclocking for the moment.  We can revisit this later once we
        have basic pm in.
      - Move pm init/fini to modesetting path.  pm is tightly coupled with display state.  Make sure
        display side is initialized before pm.
      - Add pm suspend/resume functions to make sure pm state is properly reinitialized on resume.
      - Remove dynpm module option.  It's now selectable via sysfs.
      Signed-off-by: NAlex Deucher <alexdeucher@gmail.com>
      Signed-off-by: NDave Airlie <airlied@redhat.com>
      ce8f5370
    • B
      drm: move radeon_fixed.h to shared drm_fixed.h header · 68adac5e
      Ben Skeggs 提交于
      Will be used by nouveau driver also in the near future.
      Signed-off-by: NBen Skeggs <bskeggs@redhat.com>
      Signed-off-by: NDave Airlie <airlied@redhat.com>
      68adac5e
  30. 06 4月, 2010 2 次提交
    • J
      drm/radeon/kms: simplify & improve GPU reset V2 · 90aca4d2
      Jerome Glisse 提交于
      This simplify and improve GPU reset for R1XX-R6XX hw, it's
      not 100% reliable here are result:
      - R1XX/R2XX works bunch of time in a row, sometimes it
        seems it can work indifinitly
      - R3XX/R3XX the most unreliable one, sometimes you will be
        able to reset few times, sometimes not even once
      - R5XX more reliable than previous hw, seems to work most
        of the times but once in a while it fails for no obvious
        reasons (same status than previous reset just no same
        happy ending)
      - R6XX/R7XX are lot more reliable with this patch, still
        it seems that it can fail after a bunch (reset every
        2sec for 3hour bring down the GPU & computer)
      
      This have been tested on various hw, for some odd reasons
      i wasn't able to lockup RS480/RS690 (while they use to
      love locking up).
      
      Note that on R1XX-R5XX the cursor will disapear after
      lockup haven't checked why, switch to console and back
      to X will restore cursor.
      
      Next step is to record the bogus command that leaded to
      the lockup.
      
      V2 Fix r6xx resume path to avoid reinitializing blit
      module, use the gpu_lockup boolean to avoid entering
      inifinite waiting loop on fence while reiniting the GPU
      Signed-off-by: NJerome Glisse <jglisse@redhat.com>
      Signed-off-by: NDave Airlie <airlied@redhat.com>
      90aca4d2
    • J
      drm/radeon/kms: rename gpu_reset to asic_reset · a2d07b74
      Jerome Glisse 提交于
      Patch rename gpu_reset to asic_reset in prevision of having
      gpu_reset doing more stuff than just basic asic reset.
      Signed-off-by: NJerome Glisse <jglisse@redhat.com>
      Signed-off-by: NDave Airlie <airlied@redhat.com>
      a2d07b74
  31. 31 3月, 2010 1 次提交
    • A
      drm/radeon/kms: display watermark updates (v2) · f46c0120
      Alex Deucher 提交于
      - Add module option to force the display priority
        0 = auto, 1 = normal, 2 = high
      - Default to high on r3xx/r4xx/rv515 chips
        Fixes flickering problems during heavy acceleration
        due to underflow to the display controllers
      - Fill in minimal support for RS600
      
      v2 - update display priority when bandwidth is updated
      so the user can change the parameter at runtime and it
      will take affect on the next modeset.
      Signed-off-by: NAlex Deucher <alexdeucher@gmail.com>
      Signed-off-by: NDave Airlie <airlied@redhat.com>
      f46c0120