linux-mm.kvack.org archive mirror
 help / color / mirror / Atom feed
* [PATCH 1/1] mm/early_ioremap.c: remove redundant early_ioremap_shutdown()
@ 2021-09-01  8:29 Weizhao Ouyang
  2021-09-01 10:11 ` David Hildenbrand
  0 siblings, 1 reply; 2+ messages in thread
From: Weizhao Ouyang @ 2021-09-01  8:29 UTC (permalink / raw)
  To: arnd, akpm; +Cc: linux-arch, linux-kernel, linux-mm, Weizhao Ouyang

early_ioremap_reset() reserved a weak function so that architectures can
provide a specific cleanup. Now no architectures use it, remove this
redundant function.

Signed-off-by: Weizhao Ouyang <o451686892@gmail.com>
---
 include/asm-generic/early_ioremap.h | 6 ------
 mm/early_ioremap.c                  | 5 -----
 2 files changed, 11 deletions(-)

diff --git a/include/asm-generic/early_ioremap.h b/include/asm-generic/early_ioremap.h
index 9def22e6e2b3..9d0479f50f97 100644
--- a/include/asm-generic/early_ioremap.h
+++ b/include/asm-generic/early_ioremap.h
@@ -19,12 +19,6 @@ extern void *early_memremap_prot(resource_size_t phys_addr,
 extern void early_iounmap(void __iomem *addr, unsigned long size);
 extern void early_memunmap(void *addr, unsigned long size);
 
-/*
- * Weak function called by early_ioremap_reset(). It does nothing, but
- * architectures may provide their own version to do any needed cleanups.
- */
-extern void early_ioremap_shutdown(void);
-
 #if defined(CONFIG_GENERIC_EARLY_IOREMAP) && defined(CONFIG_MMU)
 /* Arch-specific initialization */
 extern void early_ioremap_init(void);
diff --git a/mm/early_ioremap.c b/mm/early_ioremap.c
index 164607c7cdf1..74984c23a87e 100644
--- a/mm/early_ioremap.c
+++ b/mm/early_ioremap.c
@@ -38,13 +38,8 @@ pgprot_t __init __weak early_memremap_pgprot_adjust(resource_size_t phys_addr,
 	return prot;
 }
 
-void __init __weak early_ioremap_shutdown(void)
-{
-}
-
 void __init early_ioremap_reset(void)
 {
-	early_ioremap_shutdown();
 	after_paging_init = 1;
 }
 
-- 
2.30.2



^ permalink raw reply related	[flat|nested] 2+ messages in thread

* Re: [PATCH 1/1] mm/early_ioremap.c: remove redundant early_ioremap_shutdown()
  2021-09-01  8:29 [PATCH 1/1] mm/early_ioremap.c: remove redundant early_ioremap_shutdown() Weizhao Ouyang
@ 2021-09-01 10:11 ` David Hildenbrand
  0 siblings, 0 replies; 2+ messages in thread
From: David Hildenbrand @ 2021-09-01 10:11 UTC (permalink / raw)
  To: Weizhao Ouyang, arnd, akpm; +Cc: linux-arch, linux-kernel, linux-mm

On 01.09.21 10:29, Weizhao Ouyang wrote:
> early_ioremap_reset() reserved a weak function so that architectures can
> provide a specific cleanup. Now no architectures use it, remove this
> redundant function.
> 
> Signed-off-by: Weizhao Ouyang <o451686892@gmail.com>
> ---
>   include/asm-generic/early_ioremap.h | 6 ------
>   mm/early_ioremap.c                  | 5 -----
>   2 files changed, 11 deletions(-)
> 
> diff --git a/include/asm-generic/early_ioremap.h b/include/asm-generic/early_ioremap.h
> index 9def22e6e2b3..9d0479f50f97 100644
> --- a/include/asm-generic/early_ioremap.h
> +++ b/include/asm-generic/early_ioremap.h
> @@ -19,12 +19,6 @@ extern void *early_memremap_prot(resource_size_t phys_addr,
>   extern void early_iounmap(void __iomem *addr, unsigned long size);
>   extern void early_memunmap(void *addr, unsigned long size);
>   
> -/*
> - * Weak function called by early_ioremap_reset(). It does nothing, but
> - * architectures may provide their own version to do any needed cleanups.
> - */
> -extern void early_ioremap_shutdown(void);
> -
>   #if defined(CONFIG_GENERIC_EARLY_IOREMAP) && defined(CONFIG_MMU)
>   /* Arch-specific initialization */
>   extern void early_ioremap_init(void);
> diff --git a/mm/early_ioremap.c b/mm/early_ioremap.c
> index 164607c7cdf1..74984c23a87e 100644
> --- a/mm/early_ioremap.c
> +++ b/mm/early_ioremap.c
> @@ -38,13 +38,8 @@ pgprot_t __init __weak early_memremap_pgprot_adjust(resource_size_t phys_addr,
>   	return prot;
>   }
>   
> -void __init __weak early_ioremap_shutdown(void)
> -{
> -}
> -
>   void __init early_ioremap_reset(void)
>   {
> -	early_ioremap_shutdown();
>   	after_paging_init = 1;
>   }
>   
> 

Reviewed-by: David Hildenbrand <david@redhat.com>

-- 
Thanks,

David / dhildenb



^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2021-09-01 10:11 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2021-09-01  8:29 [PATCH 1/1] mm/early_ioremap.c: remove redundant early_ioremap_shutdown() Weizhao Ouyang
2021-09-01 10:11 ` 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).