kernel-janitors.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH] MIPS: ralink: bootrom: mark a function as __init to save some memory
@ 2020-05-31 10:06 Christophe JAILLET
  2020-05-31 12:32 ` Thomas Bogendoerfer
  0 siblings, 1 reply; 2+ messages in thread
From: Christophe JAILLET @ 2020-05-31 10:06 UTC (permalink / raw)
  To: john, tsbogend
  Cc: linux-mips, linux-kernel, kernel-janitors, Christophe JAILLET

'bootrom_setup()' is only called via 'postcore_initcall'.
It can be marked as __init to save a few bytes of memory.

Signed-off-by: Christophe JAILLET <christophe.jaillet@wanadoo.fr>
---
 arch/mips/ralink/bootrom.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/arch/mips/ralink/bootrom.c b/arch/mips/ralink/bootrom.c
index 88bcce59beeb..94ca8379b83c 100644
--- a/arch/mips/ralink/bootrom.c
+++ b/arch/mips/ralink/bootrom.c
@@ -31,7 +31,7 @@ static const struct file_operations bootrom_file_ops = {
 	.release	= single_release,
 };
 
-static int bootrom_setup(void)
+static int __init bootrom_setup(void)
 {
 	debugfs_create_file("bootrom", 0444, NULL, NULL, &bootrom_file_ops);
 	return 0;
-- 
2.25.1

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

* Re: [PATCH] MIPS: ralink: bootrom: mark a function as __init to save some memory
  2020-05-31 10:06 [PATCH] MIPS: ralink: bootrom: mark a function as __init to save some memory Christophe JAILLET
@ 2020-05-31 12:32 ` Thomas Bogendoerfer
  0 siblings, 0 replies; 2+ messages in thread
From: Thomas Bogendoerfer @ 2020-05-31 12:32 UTC (permalink / raw)
  To: Christophe JAILLET; +Cc: john, linux-mips, linux-kernel, kernel-janitors

On Sun, May 31, 2020 at 12:06:03PM +0200, Christophe JAILLET wrote:
> 'bootrom_setup()' is only called via 'postcore_initcall'.
> It can be marked as __init to save a few bytes of memory.
> 
> Signed-off-by: Christophe JAILLET <christophe.jaillet@wanadoo.fr>
> ---
>  arch/mips/ralink/bootrom.c | 2 +-
>  1 file changed, 1 insertion(+), 1 deletion(-)

applied to mips-next.

Thomas.

-- 
Crap can work. Given enough thrust pigs will fly, but it's not necessarily a
good idea.                                                [ RFC1925, 2.3 ]

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

end of thread, other threads:[~2020-05-31 12:32 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2020-05-31 10:06 [PATCH] MIPS: ralink: bootrom: mark a function as __init to save some memory Christophe JAILLET
2020-05-31 12:32 ` Thomas Bogendoerfer

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).