* [Suggestion] ARM:kernel: memcpy, checking the length before copy.
@ 2013-01-28 10:36 Chen Gang
0 siblings, 0 replies; only message in thread
From: Chen Gang @ 2013-01-28 10:36 UTC (permalink / raw)
To: linux-arm-kernel
Hello Russell King:
in arch/arm/kernel/fiq.c:
since the function set_fiq_handler is an EXPORT_SYMBOL function.
do we need checking memory length, before copy ?
(have to understand the madly using by outside users)
if really it is, maybe also need provide the return value for failure.
Regards
gchen.
80 void set_fiq_handler(void *start, unsigned int length)
81 {
82 #if defined(CONFIG_CPU_USE_DOMAINS)
83 memcpy((void *)0xffff001c, start, length);
84 #else
85 memcpy(vectors_page + 0x1c, start, length);
86 #endif
87 flush_icache_range(0xffff001c, 0xffff001c + length);
88 if (!vectors_high())
89 flush_icache_range(0x1c, 0x1c + length);
90 }
91
...
137 EXPORT_SYMBOL(set_fiq_handler);
^ permalink raw reply [flat|nested] only message in thread
only message in thread, other threads:[~2013-01-28 10:36 UTC | newest]
Thread overview: (only message) (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2013-01-28 10:36 [Suggestion] ARM:kernel: memcpy, checking the length before copy Chen Gang
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox