* [PATCH] flush_icache_range: Export symbol to fix build errors
@ 2014-08-18 4:24 Pranith Kumar
2014-08-18 6:35 ` Max Filippov
0 siblings, 1 reply; 3+ messages in thread
From: Pranith Kumar @ 2014-08-18 4:24 UTC (permalink / raw)
To: Vineet Gupta, Steven Miao, David Howells, Richard Kuo,
James Hogan, Chris Metcalf, Chris Zankel, Max Filippov,
Noam Camus, Andrew Morton, Geert Uytterhoeven, Masami Hiramatsu,
Tony Lu, Kirill Tkhai, open list,
moderated list:BLACKFIN ARCHITEC...,
open list:QUALCOMM HEXAGON..., open list:METAG ARCHITECTURE,
open list:SUPERH, open list:TENSILICA XTENSA...
Fix building errors occuring due to a missing export of flush_icache_range() in
architectures missing the export.
Signed-off-by: Pranith Kumar <bobby.prani@gmail.com>
Reported-by: Geert Uytterhoeven <geert@linux-m68k.org>
CC: Andrew Morton <akpm@linux-foundation.org>
---
arch/arc/mm/cache_arc700.c | 1 +
arch/blackfin/include/asm/cacheflush.h | 1 +
arch/frv/include/asm/cacheflush.h | 1 +
arch/hexagon/mm/cache.c | 1 +
arch/metag/include/asm/cacheflush.h | 1 +
arch/sh/mm/cache.c | 1 +
arch/tile/kernel/smp.c | 1 +
arch/xtensa/kernel/smp.c | 1 +
8 files changed, 8 insertions(+)
diff --git a/arch/arc/mm/cache_arc700.c b/arch/arc/mm/cache_arc700.c
index 4670afc..e88ddbf 100644
--- a/arch/arc/mm/cache_arc700.c
+++ b/arch/arc/mm/cache_arc700.c
@@ -581,6 +581,7 @@ void flush_icache_range(unsigned long kstart, unsigned long kend)
tot_sz -= sz;
}
}
+EXPORT_SYMBOL(flush_icache_range);
/*
* General purpose helper to make I and D cache lines consistent.
diff --git a/arch/blackfin/include/asm/cacheflush.h b/arch/blackfin/include/asm/cacheflush.h
index 9a5b2c5..0e2eb8c 100644
--- a/arch/blackfin/include/asm/cacheflush.h
+++ b/arch/blackfin/include/asm/cacheflush.h
@@ -70,6 +70,7 @@ static inline void flush_icache_range(unsigned start, unsigned end)
}
#endif
}
+EXPORT_SYMBOL(flush_icache_range);
#define copy_to_user_page(vma, page, vaddr, dst, src, len) \
do { memcpy(dst, src, len); \
diff --git a/arch/frv/include/asm/cacheflush.h b/arch/frv/include/asm/cacheflush.h
index edbac54..07ee4b3 100644
--- a/arch/frv/include/asm/cacheflush.h
+++ b/arch/frv/include/asm/cacheflush.h
@@ -72,6 +72,7 @@ static inline void flush_icache_range(unsigned long start, unsigned long end)
{
frv_cache_wback_inv(start, end);
}
+EXPORT_SYMBOL(flush_icache_range);
#ifdef CONFIG_MMU
extern void flush_icache_user_range(struct vm_area_struct *vma, struct page *page,
diff --git a/arch/hexagon/mm/cache.c b/arch/hexagon/mm/cache.c
index fe14ccf..0c76c80 100644
--- a/arch/hexagon/mm/cache.c
+++ b/arch/hexagon/mm/cache.c
@@ -68,6 +68,7 @@ void flush_icache_range(unsigned long start, unsigned long end)
);
local_irq_restore(flags);
}
+EXPORT_SYMBOL(flush_icache_range);
void hexagon_clean_dcache_range(unsigned long start, unsigned long end)
{
diff --git a/arch/metag/include/asm/cacheflush.h b/arch/metag/include/asm/cacheflush.h
index 7787ec5..117c212 100644
--- a/arch/metag/include/asm/cacheflush.h
+++ b/arch/metag/include/asm/cacheflush.h
@@ -124,6 +124,7 @@ static inline void flush_icache_range(unsigned long address,
metag_code_cache_flush((void *) address, endaddr - address);
#endif
}
+EXPORT_SYMBOL(flush_icache_range);
static inline void flush_cache_sigtramp(unsigned long addr, int size)
{
diff --git a/arch/sh/mm/cache.c b/arch/sh/mm/cache.c
index 097c2cd..f770e39 100644
--- a/arch/sh/mm/cache.c
+++ b/arch/sh/mm/cache.c
@@ -229,6 +229,7 @@ void flush_icache_range(unsigned long start, unsigned long end)
cacheop_on_each_cpu(local_flush_icache_range, (void *)&data, 1);
}
+EXPORT_SYMBOL(flush_icache_range);
void flush_icache_page(struct vm_area_struct *vma, struct page *page)
{
diff --git a/arch/tile/kernel/smp.c b/arch/tile/kernel/smp.c
index 01e8ab2..19eaa62 100644
--- a/arch/tile/kernel/smp.c
+++ b/arch/tile/kernel/smp.c
@@ -183,6 +183,7 @@ void flush_icache_range(unsigned long start, unsigned long end)
preempt_enable();
}
}
+EXPORT_SYMBOL(flush_icache_range);
/* Called when smp_send_reschedule() triggers IRQ_RESCHEDULE. */
diff --git a/arch/xtensa/kernel/smp.c b/arch/xtensa/kernel/smp.c
index 40b5a37..4d02e38 100644
--- a/arch/xtensa/kernel/smp.c
+++ b/arch/xtensa/kernel/smp.c
@@ -571,6 +571,7 @@ void flush_icache_range(unsigned long start, unsigned long end)
};
on_each_cpu(ipi_flush_icache_range, &fd, 1);
}
+EXPORT_SYMBOL(flush_icache_range);
/* ------------------------------------------------------------------------- */
--
1.7.9.5
^ permalink raw reply related [flat|nested] 3+ messages in thread
* Re: [PATCH] flush_icache_range: Export symbol to fix build errors
2014-08-18 4:24 [PATCH] flush_icache_range: Export symbol to fix build errors Pranith Kumar
@ 2014-08-18 6:35 ` Max Filippov
2014-08-18 6:59 ` Geert Uytterhoeven
0 siblings, 1 reply; 3+ messages in thread
From: Max Filippov @ 2014-08-18 6:35 UTC (permalink / raw)
To: Pranith Kumar
Cc: Vineet Gupta, Steven Miao, David Howells, Richard Kuo,
James Hogan, Chris Metcalf, Chris Zankel, Noam Camus,
Andrew Morton, Geert Uytterhoeven, Masami Hiramatsu, Tony Lu,
Kirill Tkhai, open list, moderated list:BLACKFIN ARCHITEC...,
open list:QUALCOMM HEXAGON..., open list:METAG ARCHITECTURE,
open list:SUPERH, open list:TENSILICA XTENSA...
Hi Pranith,
On Mon, Aug 18, 2014 at 8:24 AM, Pranith Kumar <bobby.prani@gmail.com> wrote:
> Fix building errors occuring due to a missing export of flush_icache_range() in
> architectures missing the export.
Can you be a little more specific here, what build errors?
[...]
> diff --git a/arch/frv/include/asm/cacheflush.h b/arch/frv/include/asm/cacheflush.h
> index edbac54..07ee4b3 100644
> --- a/arch/frv/include/asm/cacheflush.h
> +++ b/arch/frv/include/asm/cacheflush.h
> @@ -72,6 +72,7 @@ static inline void flush_icache_range(unsigned long start, unsigned long end)
> {
> frv_cache_wback_inv(start, end);
> }
> +EXPORT_SYMBOL(flush_icache_range);
EXPORT_SYMBOL should not be placed into header file as it defines
a non-static variable.
[...]
> diff --git a/arch/metag/include/asm/cacheflush.h b/arch/metag/include/asm/cacheflush.h
> index 7787ec5..117c212 100644
> --- a/arch/metag/include/asm/cacheflush.h
> +++ b/arch/metag/include/asm/cacheflush.h
> @@ -124,6 +124,7 @@ static inline void flush_icache_range(unsigned long address,
> metag_code_cache_flush((void *) address, endaddr - address);
> #endif
> }
> +EXPORT_SYMBOL(flush_icache_range);
Same here.
--
Thanks.
-- Max
^ permalink raw reply [flat|nested] 3+ messages in thread
* Re: [PATCH] flush_icache_range: Export symbol to fix build errors
2014-08-18 6:35 ` Max Filippov
@ 2014-08-18 6:59 ` Geert Uytterhoeven
0 siblings, 0 replies; 3+ messages in thread
From: Geert Uytterhoeven @ 2014-08-18 6:59 UTC (permalink / raw)
To: Max Filippov
Cc: Pranith Kumar, Vineet Gupta, Steven Miao, David Howells,
Richard Kuo, James Hogan, Chris Metcalf, Chris Zankel, Noam Camus,
Andrew Morton, Masami Hiramatsu, Tony Lu, Kirill Tkhai, open list,
moderated list:BLACKFIN ARCHITEC...,
open list:QUALCOMM HEXAGON..., open list:METAG ARCHITECTURE,
open list:SUPERH, open list:TENSILICA XTENSA...
On Mon, Aug 18, 2014 at 8:35 AM, Max Filippov <jcmvbkbc@gmail.com> wrote:
> On Mon, Aug 18, 2014 at 8:24 AM, Pranith Kumar <bobby.prani@gmail.com> wrote:
>> Fix building errors occuring due to a missing export of flush_icache_range() in
>> architectures missing the export.
>
> Can you be a little more specific here, what build errors?
kisskb.ellerman.id.au/kisskb/buildresult/11677809/
ERROR: "flush_icache_range" [drivers/misc/lkdtm.ko] undefined!
> [...]
>
>> diff --git a/arch/frv/include/asm/cacheflush.h b/arch/frv/include/asm/cacheflush.h
>> index edbac54..07ee4b3 100644
>> --- a/arch/frv/include/asm/cacheflush.h
>> +++ b/arch/frv/include/asm/cacheflush.h
>> @@ -72,6 +72,7 @@ static inline void flush_icache_range(unsigned long start, unsigned long end)
>> {
>> frv_cache_wback_inv(start, end);
>> }
>> +EXPORT_SYMBOL(flush_icache_range);
>
> EXPORT_SYMBOL should not be placed into header file as it defines
> a non-static variable.
Indeed.
Gr{oetje,eeting}s,
Geert
--
Geert Uytterhoeven -- There's lots of Linux beyond ia32 -- geert@linux-m68k.org
In personal conversations with technical people, I call myself a hacker. But
when I'm talking to journalists I just say "programmer" or something like that.
-- Linus Torvalds
^ permalink raw reply [flat|nested] 3+ messages in thread
end of thread, other threads:[~2014-08-18 7:00 UTC | newest]
Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2014-08-18 4:24 [PATCH] flush_icache_range: Export symbol to fix build errors Pranith Kumar
2014-08-18 6:35 ` Max Filippov
2014-08-18 6:59 ` Geert Uytterhoeven
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox