Re: [PATCH 3/3] fb_defio: do not use deprecated page->mapping, index fields

2025-02-04 Thread Thomas Zimmermann
Hi Am 04.02.25 um 09:37 schrieb Lorenzo Stoakes: On Tue, Feb 04, 2025 at 09:21:55AM +0100, Thomas Zimmermann wrote: Hi Am 31.01.25 um 19:28 schrieb Lorenzo Stoakes: With the introduction of mapping_wrprotect_page() there is no need to use folio_mkclean() in order to write-protect mappings o

Re: [PATCH 3/3] fb_defio: do not use deprecated page->mapping, index fields

2025-02-04 Thread Lorenzo Stoakes
On Tue, Feb 04, 2025 at 09:21:55AM +0100, Thomas Zimmermann wrote: > Hi > > > Am 31.01.25 um 19:28 schrieb Lorenzo Stoakes: > > With the introduction of mapping_wrprotect_page() there is no need to use > > folio_mkclean() in order to write-protect mappings of frame buffer pages, > > and therefore n

Re: [PATCH 3/3] fb_defio: do not use deprecated page->mapping, index fields

2025-02-04 Thread Thomas Zimmermann
Hi Am 31.01.25 um 19:28 schrieb Lorenzo Stoakes: With the introduction of mapping_wrprotect_page() there is no need to use folio_mkclean() in order to write-protect mappings of frame buffer pages, and therefore no need to inappropriately set kernel-allocated page->index, mapping fields to permi

Re: [PATCH 3/3] fb_defio: do not use deprecated page->mapping, index fields

2025-02-01 Thread Lorenzo Stoakes
(This time sent in reply to the correct series...) On Fri, Jan 31, 2025 at 06:28:58PM +, Lorenzo Stoakes wrote: > With the introduction of mapping_wrprotect_page() there is no need to use > folio_mkclean() in order to write-protect mappings of frame buffer pages, > and therefore no need to ina

[PATCH 3/3] fb_defio: do not use deprecated page->mapping, index fields

2025-01-31 Thread Lorenzo Stoakes
With the introduction of mapping_wrprotect_page() there is no need to use folio_mkclean() in order to write-protect mappings of frame buffer pages, and therefore no need to inappropriately set kernel-allocated page->index, mapping fields to permit this operation. Instead, store the pointer to the

Re: [RFC PATCH 3/3] fb_defio: do not use deprecated page->mapping, index fields

2025-01-13 Thread Lorenzo Stoakes
On Wed, Jan 08, 2025 at 07:41:31PM +, Lorenzo Stoakes wrote: > On Wed, Jan 08, 2025 at 05:32:54PM +, Matthew Wilcox wrote: > > On Wed, Jan 08, 2025 at 04:18:42PM +, Lorenzo Stoakes wrote: > > > @@ -280,7 +269,10 @@ static void fb_deferred_io_work(struct work_struct > > > *work) > > >

Re: [RFC PATCH 3/3] fb_defio: do not use deprecated page->mapping, index fields

2025-01-13 Thread Lorenzo Stoakes
On Wed, Jan 08, 2025 at 10:12:36PM +0100, David Hildenbrand wrote: > On 08.01.25 21:54, Matthew Wilcox wrote: > > On Wed, Jan 08, 2025 at 09:14:53PM +0100, David Hildenbrand wrote: > > > On 08.01.25 18:32, Matthew Wilcox wrote: > > > > On Wed, Jan 08, 2025 at 04:18:42PM +, Lorenzo Stoakes wrote

Re: [RFC PATCH 3/3] fb_defio: do not use deprecated page->mapping, index fields

2025-01-13 Thread Lorenzo Stoakes
On Wed, Jan 08, 2025 at 11:02:57PM +0100, David Hildenbrand wrote: > On 08.01.25 22:55, Matthew Wilcox wrote: > > On Wed, Jan 08, 2025 at 10:12:36PM +0100, David Hildenbrand wrote: > > > On 08.01.25 21:54, Matthew Wilcox wrote: > > > > Not necessarily! We already do that (since 2022) for DAX (see

Re: [RFC PATCH 3/3] fb_defio: do not use deprecated page->mapping, index fields

2025-01-08 Thread David Hildenbrand
On 08.01.25 22:55, Matthew Wilcox wrote: On Wed, Jan 08, 2025 at 10:12:36PM +0100, David Hildenbrand wrote: On 08.01.25 21:54, Matthew Wilcox wrote: Not necessarily! We already do that (since 2022) for DAX (see 6a8e0596f004). rmap lets you find every place that a given range of a file is mapp

Re: [RFC PATCH 3/3] fb_defio: do not use deprecated page->mapping, index fields

2025-01-08 Thread Matthew Wilcox
On Wed, Jan 08, 2025 at 10:12:36PM +0100, David Hildenbrand wrote: > On 08.01.25 21:54, Matthew Wilcox wrote: > > Not necessarily! We already do that (since 2022) for DAX (see > > 6a8e0596f004). rmap lets you find every place that a given range > > of a file is mapped into user address spaces; bu

Re: [RFC PATCH 3/3] fb_defio: do not use deprecated page->mapping, index fields

2025-01-08 Thread David Hildenbrand
On 08.01.25 21:54, Matthew Wilcox wrote: On Wed, Jan 08, 2025 at 09:14:53PM +0100, David Hildenbrand wrote: On 08.01.25 18:32, Matthew Wilcox wrote: On Wed, Jan 08, 2025 at 04:18:42PM +, Lorenzo Stoakes wrote: @@ -280,7 +269,10 @@ static void fb_deferred_io_work(struct work_struct *work)

Re: [RFC PATCH 3/3] fb_defio: do not use deprecated page->mapping, index fields

2025-01-08 Thread Matthew Wilcox
On Wed, Jan 08, 2025 at 09:14:53PM +0100, David Hildenbrand wrote: > On 08.01.25 18:32, Matthew Wilcox wrote: > > On Wed, Jan 08, 2025 at 04:18:42PM +, Lorenzo Stoakes wrote: > > > @@ -280,7 +269,10 @@ static void fb_deferred_io_work(struct work_struct > > > *work) > > > stru

Re: [RFC PATCH 3/3] fb_defio: do not use deprecated page->mapping, index fields

2025-01-08 Thread David Hildenbrand
On 08.01.25 18:32, Matthew Wilcox wrote: On Wed, Jan 08, 2025 at 04:18:42PM +, Lorenzo Stoakes wrote: @@ -280,7 +269,10 @@ static void fb_deferred_io_work(struct work_struct *work) struct folio *folio = page_folio(pageref->page); folio_lock(folio); - fol

Re: [RFC PATCH 3/3] fb_defio: do not use deprecated page->mapping, index fields

2025-01-08 Thread Lorenzo Stoakes
On Wed, Jan 08, 2025 at 05:32:54PM +, Matthew Wilcox wrote: > On Wed, Jan 08, 2025 at 04:18:42PM +, Lorenzo Stoakes wrote: > > @@ -280,7 +269,10 @@ static void fb_deferred_io_work(struct work_struct > > *work) > > struct folio *folio = page_folio(pageref->page); > > > >

Re: [RFC PATCH 3/3] fb_defio: do not use deprecated page->mapping, index fields

2025-01-08 Thread Matthew Wilcox
On Wed, Jan 08, 2025 at 04:18:42PM +, Lorenzo Stoakes wrote: > @@ -280,7 +269,10 @@ static void fb_deferred_io_work(struct work_struct *work) > struct folio *folio = page_folio(pageref->page); > > folio_lock(folio); > - folio_mkclean(folio); > +

[RFC PATCH 3/3] fb_defio: do not use deprecated page->mapping, index fields

2025-01-08 Thread Lorenzo Stoakes
With the introduction of rmap_wrprotect_file_page() there is no need to use folio_mkclean() in order to write-protect mappings of frame buffer pages, and therefore no need to inappropriately set kernel-allocated page->index, mapping fields to permit this operation. Instead, store the pointer to th