[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <CAHk-=whajv8Fw2VcBqZUs0hfx1Dq4fYj3TEEx4yfR3E8+rLS1A@mail.gmail.com>
Date: Thu, 18 Apr 2019 08:49:32 -0700
From: Linus Torvalds <torvalds@...ux-foundation.org>
To: Martin Schwidefsky <schwidefsky@...ibm.com>
Cc: Christoph Hellwig <hch@...radead.org>,
Linux List Kernel Mailing <linux-kernel@...r.kernel.org>,
Michael Ellerman <mpe@...erman.id.au>,
linuxppc-dev@...ts.ozlabs.org,
linux-s390 <linux-s390@...r.kernel.org>
Subject: Re: Linux 5.1-rc5
On Thu, Apr 18, 2019 at 1:02 AM Martin Schwidefsky
<schwidefsky@...ibm.com> wrote:
>
> The problematic lines in the generic gup code are these three:
>
> 1845: pmdp = pmd_offset(&pud, addr);
> 1888: pudp = pud_offset(&p4d, addr);
> 1916: p4dp = p4d_offset(&pgd, addr);
>
> Passing the pointer of a *copy* of a page table entry to pxd_offset() does
> not work with the page table folding on s390.
Hmm. I wonder why. x86 too does the folding thing for the p4d and pud case.
The folding works with the local copy just the same way it works with
the orignal value.
But I see that s390 does some other kind of folding and does that
addition of the p*d_index() unconditionally.
I guess that does mean that s390 will just have to have its own walker.
For the issue of the page refcount overflow it really isn't a huge
deal. Adding the refcount checking is simple (see the example patch I
gave for powerpc - you'll just have a couple of extra cases since you
do it all, rather than just the special hugetlb cases).
Obviously in general it would have been nicer to share as much code as
possible, but let's not make things unnecessarily complex if s390 is
just fundamentally different..
Linus
Powered by blists - more mailing lists