Skip to content

Commit 77a4157

Browse files
wangdichengmartinkpetersen
wangdicheng
authored andcommitted
scsi: aic7xxx: Fix build 'aicasm' warning
When building with CONFIG_AIC7XXX_BUILD_FIRMWARE=y or CONFIG_AIC79XX_BUILD_FIRMWARE=y, the warning messages are as follows: aicasm_gram.tab.c:1722:16: warning: implicit declaration of function ‘yylex’ [-Wimplicit-function-declaration] aicasm_macro_gram.c:68:25: warning: implicit declaration of function ‘mmlex’ [-Wimplicit-function-declaration] aicasm_scan.l:417:6: warning: implicit declaration of function ‘mm_switch_to_buffer’ aicasm_scan.l:418:6: warning: implicit declaration of function ‘mmparse’ aicasm_scan.l:421:6: warning: implicit declaration of function ‘mm_delete_buffer’ The solution is to add the corresponding function declaration to the corresponding file. Signed-off-by: wangdicheng <[email protected]> Signed-off-by: huanglei <[email protected]> Link: https://lore.kernel.org/r/[email protected] Signed-off-by: Martin K. Petersen <[email protected]>
1 parent 815940b commit 77a4157

File tree

3 files changed

+5
-0
lines changed

3 files changed

+5
-0
lines changed

drivers/scsi/aic7xxx/aicasm/aicasm_gram.y

+1
Original file line numberDiff line numberDiff line change
@@ -102,6 +102,7 @@ static void add_conditional(symbol_t *symbol);
102102
static void add_version(const char *verstring);
103103
static int is_download_const(expression_t *immed);
104104
static int is_location_address(symbol_t *symbol);
105+
int yylex();
105106
void yyerror(const char *string);
106107

107108
#define SRAM_SYMNAME "SRAM_BASE"

drivers/scsi/aic7xxx/aicasm/aicasm_macro_gram.y

+1
Original file line numberDiff line numberDiff line change
@@ -61,6 +61,7 @@
6161
static symbol_t *macro_symbol;
6262

6363
static void add_macro_arg(const char *argtext, int position);
64+
int mmlex();
6465
void mmerror(const char *string);
6566

6667
%}

drivers/scsi/aic7xxx/aicasm/aicasm_scan.l

+3
Original file line numberDiff line numberDiff line change
@@ -64,6 +64,9 @@ static char *string_buf_ptr;
6464
static int parren_count;
6565
static int quote_count;
6666
static char buf[255];
67+
void mm_switch_to_buffer(YY_BUFFER_STATE);
68+
void mmparse();
69+
void mm_delete_buffer(YY_BUFFER_STATE);
6770
%}
6871

6972
PATH ([/]*[-A-Za-z0-9_.])+

0 commit comments

Comments
 (0)