Re: [PATCH v4 5/6] drm/gem-shmem: Track folio accessed/dirty status in mmap

Boris Brezillon
2026-03-13T10:52:39Z

On Fri, 13 Mar 2026 11:29:47 +0100
Thomas Zimmermann <tzimmermann@suse.de> wrote:

> Hi
>
> Am 13.03.26 um 11:18 schrieb Boris Brezillon:
> [...]
> >>>>> + if (drm_WARN_ON(obj->dev, !shmem->pages || page_offset >= num_pages))
> >>>>> + return VM_FAULT_SIGBUS;
> >>>>> +
> >>>>> + file_update_time(vma->vm_file);
> >>>>> +
> >>>>> + folio_mark_dirty(page_folio(shmem->pages[page_offset]));
> > Do we need a folio_mark_dirty_lock() here?
>
> There is a helper for that with some documentation. [1]

I know, I meant using that version instead of folio_mark_dirty().