Hi Willy,
On Tue, Nov 7, 2023 at 10:27 PM Matthew Wilcox (Oracle)
wrote:
> Instead of unmapping the folio after copying the data to it, then mapping
> it again to zero the tail, provide folio_zero_tail() to zero the tail
> of an already-mapped folio.
>
> Signed-off-by: Matthew Wilcox (Oracle)
>
On Wed, Nov 08, 2023 at 03:06:06PM -0800, Andrew Morton wrote:
> >
> > +/**
> > + * folio_zero_tail - Zero the tail of a folio.
> > + * @folio: The folio to zero.
> > + * @kaddr: The address the folio is currently mapped to.
> > + * @offset: The byte offset in the folio to start zeroing at.
>
>
On Thu, 9 Nov 2023 01:12:15 +0100 Andreas Grünbacher
wrote:
> Andrew,
>
> Andrew Morton schrieb am Do., 9. Nov. 2023, 00:06:
> > > +
> > > + if (folio_test_highmem(folio)) {
> > > + size_t max = PAGE_SIZE - offset_in_page(offset);
> > > +
> > > + while (len > max)
Andrew,
Andrew Morton schrieb am Do., 9. Nov. 2023, 00:06:
> > +
> > + if (folio_test_highmem(folio)) {
> > + size_t max = PAGE_SIZE - offset_in_page(offset);
> > +
> > + while (len > max) {
>
> Shouldn't this be `while (len)'? AFAICT this code can fail to clear
>
On Tue, 7 Nov 2023 21:26:40 + "Matthew Wilcox (Oracle)"
wrote:
> Instead of unmapping the folio after copying the data to it, then mapping
> it again to zero the tail, provide folio_zero_tail() to zero the tail
> of an already-mapped folio.
>
> ...
>
> --- a/include/linux/highmem.h
> +++
Instead of unmapping the folio after copying the data to it, then mapping
it again to zero the tail, provide folio_zero_tail() to zero the tail
of an already-mapped folio.
Signed-off-by: Matthew Wilcox (Oracle)
---
fs/ext4/inline.c| 3 +--
include/linux/highmem.h | 38