Commit a43b739f authored by Mike Frysinger's avatar Mike Frysinger

Blackfin: push access_ok() L1 attribute down

There is no need for the L1 attribute to be on the prototype of the
access_ok() function as all consumers of the function do not care where it
lives -- they'll always use pcrel calls to get to it.  This prevents
pointless recompiles of most of the system when this config option changes.
Signed-off-by: default avatarMike Frysinger <vapier@gentoo.org>
parent 8d0d8f2a
...@@ -59,12 +59,8 @@ static inline int is_in_rom(unsigned long addr) ...@@ -59,12 +59,8 @@ static inline int is_in_rom(unsigned long addr)
#ifndef CONFIG_ACCESS_CHECK #ifndef CONFIG_ACCESS_CHECK
static inline int _access_ok(unsigned long addr, unsigned long size) { return 1; } static inline int _access_ok(unsigned long addr, unsigned long size) { return 1; }
#else #else
#ifdef CONFIG_ACCESS_OK_L1
extern int _access_ok(unsigned long addr, unsigned long size)__attribute__((l1_text));
#else
extern int _access_ok(unsigned long addr, unsigned long size); extern int _access_ok(unsigned long addr, unsigned long size);
#endif #endif
#endif
/* /*
* The exception table consists of pairs of addresses: the first is the * The exception table consists of pairs of addresses: the first is the
......
...@@ -322,6 +322,9 @@ void finish_atomic_sections (struct pt_regs *regs) ...@@ -322,6 +322,9 @@ void finish_atomic_sections (struct pt_regs *regs)
} }
#if defined(CONFIG_ACCESS_CHECK) #if defined(CONFIG_ACCESS_CHECK)
#ifdef CONFIG_ACCESS_OK_L1
__attribute__((l1_text))
#endif
/* Return 1 if access to memory range is OK, 0 otherwise */ /* Return 1 if access to memory range is OK, 0 otherwise */
int _access_ok(unsigned long addr, unsigned long size) int _access_ok(unsigned long addr, unsigned long size)
{ {
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment