* [merged] mm-bring-sparc-pte_index-semantics-inline-with-other-platforms.patch removed from -mm tree
@ 2020-04-12 6:44 akpm
0 siblings, 0 replies; only message in thread
From: akpm @ 2020-04-12 6:44 UTC (permalink / raw)
To: arjunroy.kdev, arjunroy, davem, edumazet, jgg, mm-commits, rppt,
sfr, soheil, willy
The patch titled
Subject: mm: bring sparc pte_index() semantics inline with other platforms
has been removed from the -mm tree. Its filename was
mm-bring-sparc-pte_index-semantics-inline-with-other-platforms.patch
This patch was dropped because it was merged into mainline or a subsystem tree
------------------------------------------------------
From: Arjun Roy <arjunroy@google.com>
Subject: mm: bring sparc pte_index() semantics inline with other platforms
pte_index() on platforms other than sparc return a numerical index. On
sparc, it returns a pte_t*. This presents an issue for vm_insert_pages(),
which relies on pte_index() to find the offset for a pte within a pmd, for
batched inserts.
This patch:
1. Modifies pte_index() for sparc to return a numerical index, like
other platforms,
2. Defines pte_entry() for sparc which returns a pte_t*
(as pte_index() used to),
3. Converts existing sparc callers for pte_index() to use pte_entry().
[sfr@canb.auug.org.au: remove pte_entry and just directly modified pte_offset_kernel instead]
Link: http://lkml.kernel.org/r/20200227105045.6b421d9f@canb.auug.org.au
Signed-off-by: Arjun Roy <arjunroy@google.com>
Signed-off-by: Stephen Rothwell <sfr@canb.auug.org.au>
Reviewed-by: Mike Rapoport <rppt@linux.ibm.com>
Cc: Eric Dumazet <edumazet@google.com>
Cc: Soheil Hassas Yeganeh <soheil@google.com>
Cc: David Miller <davem@davemloft.net>
Cc: Matthew Wilcox <willy@infradead.org>
Cc: Arjun Roy <arjunroy.kdev@gmail.com>
Cc: Jason Gunthorpe <jgg@ziepe.ca>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
---
arch/sparc/include/asm/pgtable_64.h | 10 +++++-----
1 file changed, 5 insertions(+), 5 deletions(-)
--- a/arch/sparc/include/asm/pgtable_64.h~mm-bring-sparc-pte_index-semantics-inline-with-other-platforms
+++ a/arch/sparc/include/asm/pgtable_64.h
@@ -907,11 +907,11 @@ static inline unsigned long pud_pfn(pud_
(((address) >> PMD_SHIFT) & (PTRS_PER_PMD-1)))
/* Find an entry in the third-level page table.. */
-#define pte_index(dir, address) \
- ((pte_t *) __pmd_page(*(dir)) + \
- ((address >> PAGE_SHIFT) & (PTRS_PER_PTE - 1)))
-#define pte_offset_kernel pte_index
-#define pte_offset_map pte_index
+#define pte_index(address) \
+ ((address >> PAGE_SHIFT) & (PTRS_PER_PTE - 1))
+#define pte_offset_kernel(dir, address) \
+ ((pte_t *) __pmd_page(*(dir)) + pte_index(address))
+#define pte_offset_map(dir, address) pte_offset_kernel((dir), (address))
#define pte_unmap(pte) do { } while (0)
/* We cannot include <linux/mm_types.h> at this point yet: */
_
Patches currently in -mm which might be from arjunroy@google.com are
net-zerocopy-use-vm_insert_pages-for-tcp-rcv-zerocopy.patch
^ permalink raw reply [flat|nested] only message in thread
only message in thread, other threads:[~2020-04-12 6:45 UTC | newest]
Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2020-04-12 6:44 [merged] mm-bring-sparc-pte_index-semantics-inline-with-other-platforms.patch removed from -mm tree akpm
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).