diff options
| author | Jann Horn <jannh@google.com> | 2019-03-27 21:10:38 +0100 |
|---|---|---|
| committer | Luc Van Oostenryck <luc.vanoostenryck@gmail.com> | 2019-03-27 22:12:24 +0100 |
| commit | 1ed0955919913ad4f314e867fcbc76535acf010c (patch) | |
| tree | cf38b8d8908664d0b0c78b43a40b951e4d9b027d /evaluate.c | |
| parent | 7fd3778e2d3a7b17aefea66819bf07feb7a257d3 (diff) | |
| download | sparse-dev-1ed0955919913ad4f314e867fcbc76535acf010c.tar.gz | |
evaluate: externally_visible functions don't need a declaration
sparse warns for non-static functions that don't have a separate
declaration. The kernel contains several such functions that are marked
as __attribute__((externally_visible)) to mark that they are called from
assembly code. Assembly code doesn't need a header with a declaration to
call a function. Therefore, suppress the warning for functions with
__attribute__((externally_visible)).
Signed-off-by: Jann Horn <jannh@google.com>
Signed-off-by: Luc Van Oostenryck <luc.vanoostenryck@gmail.com>
Diffstat (limited to 'evaluate.c')
| -rw-r--r-- | evaluate.c | 2 |
1 files changed, 1 insertions, 1 deletions
@@ -3387,7 +3387,7 @@ void check_duplicates(struct symbol *sym) } if (!declared) { unsigned long mod = sym->ctype.modifiers; - if (mod & (MOD_STATIC | MOD_REGISTER)) + if (mod & (MOD_STATIC | MOD_REGISTER | MOD_EXT_VISIBLE)) return; if (!(mod & MOD_TOPLEVEL)) return; |
