public inbox for drm-ai-reviews@public-inbox.freedesktop.org
 help / color / mirror / Atom feed
* [PATCH v9 0/4] Enable THP support in drm_pagemap
@ 2026-03-12 19:20 Francois Dugast
  2026-03-12 19:20 ` [PATCH v9 1/4] drm/pagemap: Unlock and put folios when possible Francois Dugast
                   ` (4 more replies)
  0 siblings, 5 replies; 11+ messages in thread
From: Francois Dugast @ 2026-03-12 19:20 UTC (permalink / raw)
  To: intel-xe; +Cc: dri-devel

Use Balbir Singh's series for device-private THP support [1] and previous
preparation work in drm_pagemap [2] to add 2MB/THP support in xe. This leads
to significant performance improvements when using SVM with 2MB pages.

[1] https://lore.kernel.org/linux-mm/20251001065707.920170-1-balbirs@nvidia.com/
[2] https://patchwork.freedesktop.org/series/151754/

v2:
- rebase on top of multi-device SVM
- add drm_pagemap_cpages() with temporary patch
- address other feedback from Matt Brost on v1

v3:
The major change is to remove the dependency to the mm/huge_memory
helper migrate_device_split_page() that was called explicitely when
a 2M buddy allocation backed by a large folio would be later reused
for a smaller allocation (4K or 64K). Instead, the first 3 patches
provided by Matthew Brost ensure large folios are split at the time
of freeing.

v4:
- add order argument to folio_free callback
- send complete series to linux-mm and MM folks as requested (Zi Yan
  and Andrew Morton) and cover letter to anyone receiving at least
  one of the patches (Liam R. Howlett)

v5:
- update zone_device_page_init() in patch #1 to reinitialize large
  zone device private folios

v6:
- fix drm_pagemap change in patch #1 to allow applying to 6.19 and
  add some comments

v7:
- now that patch #1 is merged, rebase and resend for CI

v8:
- rebase on 7.0.0-rc3

v9:
- fix build when CONFIG_ZONE_DEVICE is disabled

Francois Dugast (3):
  drm/pagemap: Unlock and put folios when possible
  drm/pagemap: Add helper to access zone_device_data
  drm/pagemap: Enable THP support for GPU memory migration

Matthew Brost (1):
  drm/pagemap: Correct cpages calculation for migrate_vma_setup

 drivers/gpu/drm/drm_gpusvm.c  |   7 +-
 drivers/gpu/drm/drm_pagemap.c | 157 +++++++++++++++++++++++++++-------
 include/drm/drm_pagemap.h     |  21 +++++
 3 files changed, 154 insertions(+), 31 deletions(-)

-- 
2.43.0


^ permalink raw reply	[flat|nested] 11+ messages in thread
* [PATCH v8 0/4] Enable THP support in drm_pagemap
@ 2026-03-12 15:16 Francois Dugast
  2026-03-12 15:16 ` [PATCH v8 4/4] drm/pagemap: Enable THP support for GPU memory migration Francois Dugast
  0 siblings, 1 reply; 11+ messages in thread
From: Francois Dugast @ 2026-03-12 15:16 UTC (permalink / raw)
  To: intel-xe; +Cc: dri-devel

Use Balbir Singh's series for device-private THP support [1] and previous
preparation work in drm_pagemap [2] to add 2MB/THP support in xe. This leads
to significant performance improvements when using SVM with 2MB pages.

[1] https://lore.kernel.org/linux-mm/20251001065707.920170-1-balbirs@nvidia.com/
[2] https://patchwork.freedesktop.org/series/151754/

v2:
- rebase on top of multi-device SVM
- add drm_pagemap_cpages() with temporary patch
- address other feedback from Matt Brost on v1

v3:
The major change is to remove the dependency to the mm/huge_memory
helper migrate_device_split_page() that was called explicitely when
a 2M buddy allocation backed by a large folio would be later reused
for a smaller allocation (4K or 64K). Instead, the first 3 patches
provided by Matthew Brost ensure large folios are split at the time
of freeing.

v4:
- add order argument to folio_free callback
- send complete series to linux-mm and MM folks as requested (Zi Yan
  and Andrew Morton) and cover letter to anyone receiving at least
  one of the patches (Liam R. Howlett)

v5:
- update zone_device_page_init() in patch #1 to reinitialize large
  zone device private folios

v6:
- fix drm_pagemap change in patch #1 to allow applying to 6.19 and
  add some comments

v7:
- now that patch #1 is merged, rebase and resend for CI

v8:
- rebase on 7.0.0-rc3

Francois Dugast (3):
  drm/pagemap: Unlock and put folios when possible
  drm/pagemap: Add helper to access zone_device_data
  drm/pagemap: Enable THP support for GPU memory migration

Matthew Brost (1):
  drm/pagemap: Correct cpages calculation for migrate_vma_setup

 drivers/gpu/drm/drm_gpusvm.c  |   7 +-
 drivers/gpu/drm/drm_pagemap.c | 157 +++++++++++++++++++++++++++-------
 include/drm/drm_pagemap.h     |  14 +++
 3 files changed, 147 insertions(+), 31 deletions(-)

-- 
2.43.0


^ permalink raw reply	[flat|nested] 11+ messages in thread

end of thread, other threads:[~2026-03-13  4:02 UTC | newest]

Thread overview: 11+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2026-03-12 19:20 [PATCH v9 0/4] Enable THP support in drm_pagemap Francois Dugast
2026-03-12 19:20 ` [PATCH v9 1/4] drm/pagemap: Unlock and put folios when possible Francois Dugast
2026-03-13  3:55   ` Claude review: " Claude Code Review Bot
2026-03-12 19:20 ` [PATCH v9 2/4] drm/pagemap: Add helper to access zone_device_data Francois Dugast
2026-03-13  3:55   ` Claude review: " Claude Code Review Bot
2026-03-12 19:20 ` [PATCH v9 3/4] drm/pagemap: Correct cpages calculation for migrate_vma_setup Francois Dugast
2026-03-13  3:55   ` Claude review: " Claude Code Review Bot
2026-03-12 19:20 ` [PATCH v9 4/4] drm/pagemap: Enable THP support for GPU memory migration Francois Dugast
2026-03-13  3:55   ` Claude review: " Claude Code Review Bot
2026-03-13  3:55 ` Claude review: Enable THP support in drm_pagemap Claude Code Review Bot
  -- strict thread matches above, loose matches on Subject: below --
2026-03-12 15:16 [PATCH v8 0/4] " Francois Dugast
2026-03-12 15:16 ` [PATCH v8 4/4] drm/pagemap: Enable THP support for GPU memory migration Francois Dugast
2026-03-13  4:02   ` Claude review: " Claude Code Review Bot

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox