aboutsummaryrefslogtreecommitdiffstats
path: root/arch/microblaze
diff options
context:
space:
mode:
authorMichal Simek <michal.simek@xilinx.com>2014-12-18 09:51:30 -0500
committerMichal Simek <michal.simek@xilinx.com>2015-01-05 06:36:44 -0500
commitb6db0a56218c38455e52780338ad61e284a67e4c (patch)
tree7694069bfd8faf362adcb0de70342863cd007b75 /arch/microblaze
parente14ebe417c7c4e58c50ef143d99d797757749762 (diff)
microblaze: Change extern inline to static inline
With compilers which follow the C99 standard (like modern versions of gcc and clang), "extern inline" does the opposite thing from older versions of gcc (emits code for an externally linkable version of the inline function). "static inline" does the intended behavior in all cases instead. Description taken from: "staging, rtl8192e, LLVMLinux: Change extern inline to static inline" (sha1: 6d91857d4826b382b3fd4fad95f52713be646f96) The patch removes compilation warnings W=1: ./arch/microblaze/include/asm/delay.h:18:20: warning: no previous prototype for '__delay' [-Wmissing-prototypes] extern inline void __delay(unsigned long loops) ./arch/microblaze/include/asm/delay.h:46:20: warning: no previous prototype for '__udelay' [-Wmissing-prototypes] extern inline void __udelay(unsigned int x) ./arch/microblaze/include/asm/pgalloc.h:63:22: warning: no previous prototype for 'get_pgd_slow' [-Wmissing-prototypes] extern inline pgd_t *get_pgd_slow(void) ./arch/microblaze/include/asm/pgalloc.h:73:22: warning: no previous prototype for 'get_pgd_fast' [-Wmissing-prototypes] extern inline pgd_t *get_pgd_fast(void) ./arch/microblaze/include/asm/pgalloc.h:87:20: warning: no previous prototype for 'free_pgd_fast' [-Wmissing-prototypes] extern inline void free_pgd_fast(pgd_t *pgd) ./arch/microblaze/include/asm/pgalloc.h:94:20: warning: no previous prototype for 'free_pgd_slow' [-Wmissing-prototypes] extern inline void free_pgd_slow(pgd_t *pgd) ./arch/microblaze/include/asm/pgalloc.h:149:20: warning: no previous prototype for 'pte_free_fast' [-Wmissing-prototypes] extern inline void pte_free_fast(pte_t *pte) ./arch/microblaze/include/asm/pgalloc.h:156:20: warning: no previous prototype for 'pte_free_kernel' [-Wmissing-prototypes] extern inline void pte_free_kernel(struct mm_struct *mm, pte_t *pte) ./arch/microblaze/include/asm/pgalloc.h:161:20: warning: no previous prototype for 'pte_free_slow' [-Wmissing-prototypes] extern inline void pte_free_slow(struct page *ptepage) Signed-off-by: Michal Simek <michal.simek@xilinx.com>
Diffstat (limited to 'arch/microblaze')
-rw-r--r--arch/microblaze/include/asm/delay.h4
-rw-r--r--arch/microblaze/include/asm/pgalloc.h14
2 files changed, 9 insertions, 9 deletions
diff --git a/arch/microblaze/include/asm/delay.h b/arch/microblaze/include/asm/delay.h
index 60cb39deb533..ea2a9cd9b159 100644
--- a/arch/microblaze/include/asm/delay.h
+++ b/arch/microblaze/include/asm/delay.h
@@ -15,7 +15,7 @@
15 15
16#include <linux/param.h> 16#include <linux/param.h>
17 17
18extern inline void __delay(unsigned long loops) 18static inline void __delay(unsigned long loops)
19{ 19{
20 asm volatile ("# __delay \n\t" \ 20 asm volatile ("# __delay \n\t" \
21 "1: addi %0, %0, -1\t\n" \ 21 "1: addi %0, %0, -1\t\n" \
@@ -43,7 +43,7 @@ extern inline void __delay(unsigned long loops)
43 43
44extern unsigned long loops_per_jiffy; 44extern unsigned long loops_per_jiffy;
45 45
46extern inline void __udelay(unsigned int x) 46static inline void __udelay(unsigned int x)
47{ 47{
48 48
49 unsigned long long tmp = 49 unsigned long long tmp =
diff --git a/arch/microblaze/include/asm/pgalloc.h b/arch/microblaze/include/asm/pgalloc.h
index 7fdf7fabc7d7..61436d69775c 100644
--- a/arch/microblaze/include/asm/pgalloc.h
+++ b/arch/microblaze/include/asm/pgalloc.h
@@ -60,7 +60,7 @@ extern unsigned long get_zero_page_fast(void);
60 60
61extern void __bad_pte(pmd_t *pmd); 61extern void __bad_pte(pmd_t *pmd);
62 62
63extern inline pgd_t *get_pgd_slow(void) 63static inline pgd_t *get_pgd_slow(void)
64{ 64{
65 pgd_t *ret; 65 pgd_t *ret;
66 66
@@ -70,7 +70,7 @@ extern inline pgd_t *get_pgd_slow(void)
70 return ret; 70 return ret;
71} 71}
72 72
73extern inline pgd_t *get_pgd_fast(void) 73static inline pgd_t *get_pgd_fast(void)
74{ 74{
75 unsigned long *ret; 75 unsigned long *ret;
76 76
@@ -84,14 +84,14 @@ extern inline pgd_t *get_pgd_fast(void)
84 return (pgd_t *)ret; 84 return (pgd_t *)ret;
85} 85}
86 86
87extern inline void free_pgd_fast(pgd_t *pgd) 87static inline void free_pgd_fast(pgd_t *pgd)
88{ 88{
89 *(unsigned long **)pgd = pgd_quicklist; 89 *(unsigned long **)pgd = pgd_quicklist;
90 pgd_quicklist = (unsigned long *) pgd; 90 pgd_quicklist = (unsigned long *) pgd;
91 pgtable_cache_size++; 91 pgtable_cache_size++;
92} 92}
93 93
94extern inline void free_pgd_slow(pgd_t *pgd) 94static inline void free_pgd_slow(pgd_t *pgd)
95{ 95{
96 free_page((unsigned long)pgd); 96 free_page((unsigned long)pgd);
97} 97}
@@ -146,19 +146,19 @@ static inline pte_t *pte_alloc_one_fast(struct mm_struct *mm,
146 return (pte_t *)ret; 146 return (pte_t *)ret;
147} 147}
148 148
149extern inline void pte_free_fast(pte_t *pte) 149static inline void pte_free_fast(pte_t *pte)
150{ 150{
151 *(unsigned long **)pte = pte_quicklist; 151 *(unsigned long **)pte = pte_quicklist;
152 pte_quicklist = (unsigned long *) pte; 152 pte_quicklist = (unsigned long *) pte;
153 pgtable_cache_size++; 153 pgtable_cache_size++;
154} 154}
155 155
156extern inline void pte_free_kernel(struct mm_struct *mm, pte_t *pte) 156static inline void pte_free_kernel(struct mm_struct *mm, pte_t *pte)
157{ 157{
158 free_page((unsigned long)pte); 158 free_page((unsigned long)pte);
159} 159}
160 160
161extern inline void pte_free_slow(struct page *ptepage) 161static inline void pte_free_slow(struct page *ptepage)
162{ 162{
163 __free_page(ptepage); 163 __free_page(ptepage);
164} 164}