Summary: | radeon_gart_table_vram_pin takes 473 ms during ACPI S3 resume | ||||||
---|---|---|---|---|---|---|---|
Product: | DRI | Reporter: | Paul Menzel <pmenzel+bugs.freedesktop.org> | ||||
Component: | DRM/Radeon | Assignee: | Default DRI bug account <dri-devel> | ||||
Status: | CLOSED INVALID | QA Contact: | |||||
Severity: | normal | ||||||
Priority: | medium | ||||||
Version: | DRI git | ||||||
Hardware: | Other | ||||||
OS: | All | ||||||
Whiteboard: | |||||||
i915 platform: | i915 features: | ||||||
Attachments: |
|
Description
Paul Menzel
2018-07-22 07:45:52 UTC
(In reply to Paul Menzel from comment #0) > Is there a way to get rid of the for loop? Some memset equivalent? At least not easily. The hardware is not initialized yet, so we have to writeback the GART table using the CPU. Depending on the size of the table (which in turn depends on installed system memory) it can easily take even more than a second to do this. Just as a follow-up, the long time seems to have been caused by ftrace. With the patch below on top of drm-tip from this morning, it only takes 7 ms. diff --git a/drivers/gpu/drm/radeon/radeon_gart.c b/drivers/gpu/drm/radeon/radeon_gart.c index 1cef155cc933..f79a2f8b8d8e 100644 --- a/drivers/gpu/drm/radeon/radeon_gart.c +++ b/drivers/gpu/drm/radeon/radeon_gart.c @@ -175,10 +175,13 @@ int radeon_gart_table_vram_pin(struct radeon_device *rdev) /* We might have dropped some GART table updates while it wasn't * mapped, restore all entries */ + DRM_INFO("GART: Restore entries: num cpu pages %u, num gpu pages %u\n", + rdev->gart.num_cpu_pages, rdev->gart.num_gpu_pages); for (i = 0; i < rdev->gart.num_gpu_pages; i++) radeon_gart_set_page(rdev, i, rdev->gart.pages_entry[i]); mb(); radeon_gart_tlb_flush(rdev); + DRM_INFO("GART: Done restoring entries\n"); } return r; (In reply to Paul Menzel from comment #2) > Just as a follow-up, the long time seems to have been caused by ftrace. > > With the patch below on top of drm-tip from this morning, it only takes 7 > ms. Interesting. I wasn't aware that ftrace could have such negative side effects. Anyway if somebody has a radeon in a box with halve a TB system memory he can probably live with a few ms resume time :) |
Use of freedesktop.org services, including Bugzilla, is subject to our Code of Conduct. How we collect and use information is described in our Privacy Policy.