HomeFreeBSD

aic7xxx: Fix re-building firmware with -fno-common

Description

aic7xxx: Fix re-building firmware with -fno-common

The generated C output for aicasm_scan.l defines yylineno already, so
references to it from other files should use an extern declaration.

The STAILQ_HEAD use in aicasm_symbol.h also provided an identifier,
causing it to both define the struct type and define a variable of that
struct type, causing any C file including the header to define the same
variable. This variable is not used (and confusingly clashes with a
field name just below) and was likely caused by confusion when switching
between defining fields using similar type macros and defining the type
itself.

Reviewed by: imp
MFC after: 1 week
Differential Revision: https://reviews.freebsd.org/D30525

(cherry picked from commit 5e912f5fec025766521f535d1237330ede7f18e2)

Details

Provenance
jrtc27Authored on May 28 2021, 6:07 PM
Reviewer
imp
Differential Revision
D30525: aic7xxx: Fix re-building firmware with -fno-common
Parents
rGc1f4b179fee7: MFV d60fa10fd872db7e3d8cb1e161cfdae026c43b14:
Branches
Unknown
Tags
Unknown