* [PATCH] mm: Remove guard around pgd_offset_k() macro
@ 2024-03-16 11:52 Christophe Leroy
2024-03-18 12:19 ` David Hildenbrand
0 siblings, 1 reply; 2+ messages in thread
From: Christophe Leroy @ 2024-03-16 11:52 UTC (permalink / raw)
To: Andrew Morton; +Cc: Christophe Leroy, linux-kernel, linux-mm
The last architecture redefining pgd_offset_k() was IA64 and it was
removed by commit cf8e8658100d ("arch: Remove Itanium (IA-64)
architecture")
There is no need anymore to guard generic version of pgd_offset_k()
with #ifndef pgd_offset_k
Signed-off-by: Christophe Leroy <christophe.leroy@csgroup.eu>
---
include/linux/pgtable.h | 2 --
1 file changed, 2 deletions(-)
diff --git a/include/linux/pgtable.h b/include/linux/pgtable.h
index 85fc7554cd52..bd9c7180718c 100644
--- a/include/linux/pgtable.h
+++ b/include/linux/pgtable.h
@@ -149,9 +149,7 @@ static inline pgd_t *pgd_offset_pgd(pgd_t *pgd, unsigned long address)
* a shortcut which implies the use of the kernel's pgd, instead
* of a process's
*/
-#ifndef pgd_offset_k
#define pgd_offset_k(address) pgd_offset(&init_mm, (address))
-#endif
/*
* In many cases it is known that a virtual address is mapped at PMD or PTE
--
2.43.0
^ permalink raw reply related [flat|nested] 2+ messages in thread* Re: [PATCH] mm: Remove guard around pgd_offset_k() macro
2024-03-16 11:52 [PATCH] mm: Remove guard around pgd_offset_k() macro Christophe Leroy
@ 2024-03-18 12:19 ` David Hildenbrand
0 siblings, 0 replies; 2+ messages in thread
From: David Hildenbrand @ 2024-03-18 12:19 UTC (permalink / raw)
To: Christophe Leroy, Andrew Morton; +Cc: linux-kernel, linux-mm
On 16.03.24 12:52, Christophe Leroy wrote:
> The last architecture redefining pgd_offset_k() was IA64 and it was
> removed by commit cf8e8658100d ("arch: Remove Itanium (IA-64)
> architecture")
>
> There is no need anymore to guard generic version of pgd_offset_k()
> with #ifndef pgd_offset_k
>
> Signed-off-by: Christophe Leroy <christophe.leroy@csgroup.eu>
> ---
> include/linux/pgtable.h | 2 --
> 1 file changed, 2 deletions(-)
>
> diff --git a/include/linux/pgtable.h b/include/linux/pgtable.h
> index 85fc7554cd52..bd9c7180718c 100644
> --- a/include/linux/pgtable.h
> +++ b/include/linux/pgtable.h
> @@ -149,9 +149,7 @@ static inline pgd_t *pgd_offset_pgd(pgd_t *pgd, unsigned long address)
> * a shortcut which implies the use of the kernel's pgd, instead
> * of a process's
> */
> -#ifndef pgd_offset_k
> #define pgd_offset_k(address) pgd_offset(&init_mm, (address))
> -#endif
>
> /*
> * In many cases it is known that a virtual address is mapped at PMD or PTE
Reviewed-by: David Hildenbrand <david@redhat.com>
--
Cheers,
David / dhildenb
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~2024-03-18 12:19 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2024-03-16 11:52 [PATCH] mm: Remove guard around pgd_offset_k() macro Christophe Leroy
2024-03-18 12:19 ` David Hildenbrand
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).