Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
L
linux
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
Analytics
Analytics
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
nexedi
linux
Commits
bbd3f4fb
Commit
bbd3f4fb
authored
Jan 30, 2010
by
Uwe Kleine-König
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
modpost: give most mismatch constants a better name
Signed-off-by:
Uwe Kleine-König
<
u.kleine-koenig@pengutronix.de
>
parent
4a31a229
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
28 additions
and
28 deletions
+28
-28
scripts/mod/modpost.c
scripts/mod/modpost.c
+28
-28
No files found.
scripts/mod/modpost.c
View file @
bbd3f4fb
...
...
@@ -836,14 +836,14 @@ static const char *linker_symbols[] =
enum
mismatch
{
NO_MISMATCH
,
TEXT_TO_INIT
,
DATA_TO_INIT
,
TEXT_TO_EXIT
,
DATA_TO_EXIT
,
XXXINIT_TO_INIT
,
XXXEXIT_TO_EXIT
,
INIT_TO
_EXIT
,
EXIT_TO
_INIT
,
TEXT_TO_
ANY_
INIT
,
DATA_TO_
ANY_
INIT
,
TEXT_TO_
ANY_
EXIT
,
DATA_TO_
ANY_
EXIT
,
XXXINIT_TO_
SOME_
INIT
,
XXXEXIT_TO_
SOME_
EXIT
,
ANY_INIT_TO_ANY
_EXIT
,
ANY_EXIT_TO_ANY
_INIT
,
EXPORT_TO_INIT_EXIT
,
};
...
...
@@ -860,70 +860,70 @@ const struct sectioncheck sectioncheck[] = {
{
.
fromsec
=
{
TEXT_SECTIONS
,
NULL
},
.
tosec
=
{
ALL_INIT_SECTIONS
,
NULL
},
.
mismatch
=
TEXT_TO_INIT
,
.
mismatch
=
TEXT_TO_
ANY_
INIT
,
},
{
.
fromsec
=
{
DATA_SECTIONS
,
NULL
},
.
tosec
=
{
ALL_INIT_SECTIONS
,
NULL
},
.
mismatch
=
DATA_TO_INIT
,
.
mismatch
=
DATA_TO_
ANY_
INIT
,
},
{
.
fromsec
=
{
TEXT_SECTIONS
,
NULL
},
.
tosec
=
{
ALL_EXIT_SECTIONS
,
NULL
},
.
mismatch
=
TEXT_TO_EXIT
,
.
mismatch
=
TEXT_TO_
ANY_
EXIT
,
},
{
.
fromsec
=
{
DATA_SECTIONS
,
NULL
},
.
tosec
=
{
ALL_EXIT_SECTIONS
,
NULL
},
.
mismatch
=
DATA_TO_EXIT
,
.
mismatch
=
DATA_TO_
ANY_
EXIT
,
},
/* Do not reference init code/data from devinit/cpuinit/meminit code/data */
{
.
fromsec
=
{
ALL_XXXINIT_SECTIONS
,
NULL
},
.
tosec
=
{
INIT_SECTIONS
,
NULL
},
.
mismatch
=
XXXINIT_TO_INIT
,
.
mismatch
=
XXXINIT_TO_
SOME_
INIT
,
},
/* Do not reference cpuinit code/data from meminit code/data */
{
.
fromsec
=
{
MEM_INIT_SECTIONS
,
NULL
},
.
tosec
=
{
CPU_INIT_SECTIONS
,
NULL
},
.
mismatch
=
XXXINIT_TO_INIT
,
.
mismatch
=
XXXINIT_TO_
SOME_
INIT
,
},
/* Do not reference meminit code/data from cpuinit code/data */
{
.
fromsec
=
{
CPU_INIT_SECTIONS
,
NULL
},
.
tosec
=
{
MEM_INIT_SECTIONS
,
NULL
},
.
mismatch
=
XXXINIT_TO_INIT
,
.
mismatch
=
XXXINIT_TO_
SOME_
INIT
,
},
/* Do not reference exit code/data from devexit/cpuexit/memexit code/data */
{
.
fromsec
=
{
ALL_XXXEXIT_SECTIONS
,
NULL
},
.
tosec
=
{
EXIT_SECTIONS
,
NULL
},
.
mismatch
=
XXXEXIT_TO_EXIT
,
.
mismatch
=
XXXEXIT_TO_
SOME_
EXIT
,
},
/* Do not reference cpuexit code/data from memexit code/data */
{
.
fromsec
=
{
MEM_EXIT_SECTIONS
,
NULL
},
.
tosec
=
{
CPU_EXIT_SECTIONS
,
NULL
},
.
mismatch
=
XXXEXIT_TO_EXIT
,
.
mismatch
=
XXXEXIT_TO_
SOME_
EXIT
,
},
/* Do not reference memexit code/data from cpuexit code/data */
{
.
fromsec
=
{
CPU_EXIT_SECTIONS
,
NULL
},
.
tosec
=
{
MEM_EXIT_SECTIONS
,
NULL
},
.
mismatch
=
XXXEXIT_TO_EXIT
,
.
mismatch
=
XXXEXIT_TO_
SOME_
EXIT
,
},
/* Do not use exit code/data from init code */
{
.
fromsec
=
{
ALL_INIT_SECTIONS
,
NULL
},
.
tosec
=
{
ALL_EXIT_SECTIONS
,
NULL
},
.
mismatch
=
INIT_TO
_EXIT
,
.
mismatch
=
ANY_INIT_TO_ANY
_EXIT
,
},
/* Do not use init code/data from exit code */
{
.
fromsec
=
{
ALL_EXIT_SECTIONS
,
NULL
},
.
tosec
=
{
ALL_INIT_SECTIONS
,
NULL
},
.
mismatch
=
EXIT_TO
_INIT
,
.
mismatch
=
ANY_EXIT_TO_ANY
_INIT
,
},
/* Do not export init/exit functions or data */
{
...
...
@@ -1190,7 +1190,7 @@ static void report_sec_mismatch(const char *modname, enum mismatch mismatch,
tosym
,
to_p
);
switch
(
mismatch
)
{
case
TEXT_TO_INIT
:
case
TEXT_TO_
ANY_
INIT
:
fprintf
(
stderr
,
"The function %s%s() references
\n
"
"the %s %s%s%s.
\n
"
...
...
@@ -1200,7 +1200,7 @@ static void report_sec_mismatch(const char *modname, enum mismatch mismatch,
to
,
sec2annotation
(
tosec
),
tosym
,
to_p
,
fromsym
,
sec2annotation
(
tosec
),
tosym
);
break
;
case
DATA_TO_INIT
:
{
case
DATA_TO_
ANY_
INIT
:
{
const
char
**
s
=
symbol_white_list
;
fprintf
(
stderr
,
"The variable %s references
\n
"
...
...
@@ -1214,14 +1214,14 @@ static void report_sec_mismatch(const char *modname, enum mismatch mismatch,
fprintf
(
stderr
,
"
\n
"
);
break
;
}
case
TEXT_TO_EXIT
:
case
TEXT_TO_
ANY_
EXIT
:
fprintf
(
stderr
,
"The function %s() references a %s in an exit section.
\n
"
"Often the %s %s%s has valid usage outside the exit section
\n
"
"and the fix is to remove the %sannotation of %s.
\n
"
,
fromsym
,
to
,
to
,
tosym
,
to_p
,
sec2annotation
(
tosec
),
tosym
);
break
;
case
DATA_TO_EXIT
:
{
case
DATA_TO_
ANY_
EXIT
:
{
const
char
**
s
=
symbol_white_list
;
fprintf
(
stderr
,
"The variable %s references
\n
"
...
...
@@ -1235,8 +1235,8 @@ static void report_sec_mismatch(const char *modname, enum mismatch mismatch,
fprintf
(
stderr
,
"
\n
"
);
break
;
}
case
XXXINIT_TO_INIT
:
case
XXXEXIT_TO_EXIT
:
case
XXXINIT_TO_
SOME_
INIT
:
case
XXXEXIT_TO_
SOME_
EXIT
:
fprintf
(
stderr
,
"The %s %s%s%s references
\n
"
"a %s %s%s%s.
\n
"
...
...
@@ -1246,7 +1246,7 @@ static void report_sec_mismatch(const char *modname, enum mismatch mismatch,
to
,
sec2annotation
(
tosec
),
tosym
,
to_p
,
tosym
,
fromsym
,
tosym
);
break
;
case
INIT_TO
_EXIT
:
case
ANY_INIT_TO_ANY
_EXIT
:
fprintf
(
stderr
,
"The %s %s%s%s references
\n
"
"a %s %s%s%s.
\n
"
...
...
@@ -1259,7 +1259,7 @@ static void report_sec_mismatch(const char *modname, enum mismatch mismatch,
to
,
sec2annotation
(
tosec
),
tosym
,
to_p
,
sec2annotation
(
tosec
),
tosym
,
to_p
);
break
;
case
EXIT_TO
_INIT
:
case
ANY_EXIT_TO_ANY
_INIT
:
fprintf
(
stderr
,
"The %s %s%s%s references
\n
"
"a %s %s%s%s.
\n
"
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment