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
45f59fc7
Commit
45f59fc7
authored
Apr 02, 2003
by
Linus Torvalds
Browse files
Options
Browse Files
Download
Plain Diff
Merge
bk://kernel.bkbits.net/gregkh/linux/i2c-2.5
into home.transmeta.com:/home/torvalds/v2.5/linux
parents
202b1705
5279bb94
Changes
4
Hide whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
14 additions
and
10 deletions
+14
-10
drivers/usb/serial/generic.c
drivers/usb/serial/generic.c
+1
-0
include/linux/module.h
include/linux/module.h
+1
-1
kernel/module.c
kernel/module.c
+9
-7
scripts/Makefile.modpost
scripts/Makefile.modpost
+3
-2
No files found.
drivers/usb/serial/generic.c
View file @
45f59fc7
...
...
@@ -17,6 +17,7 @@
#include <linux/tty_flip.h>
#include <linux/module.h>
#include <linux/usb.h>
#include <asm/uaccess.h>
#ifdef CONFIG_USB_SERIAL_DEBUG
static
int
debug
=
1
;
...
...
include/linux/module.h
View file @
45f59fc7
...
...
@@ -233,7 +233,7 @@ struct module
#ifdef CONFIG_KALLSYMS
/* We keep the symbol and string tables for kallsyms. */
Elf_Sym
*
symtab
;
unsigned
long
num_
kallsyms
;
unsigned
long
num_
symtab
;
char
*
strtab
;
#endif
...
...
kernel/module.c
View file @
45f59fc7
...
...
@@ -839,12 +839,13 @@ static inline int check_modstruct_version(Elf_Shdr *sechdrs,
unsigned
int
versindex
,
struct
module
*
mod
)
{
unsigned
int
i
;
struct
kernel_symbol_group
*
ksg
;
const
unsigned
long
*
crc
;
struct
module
*
owner
;
if
(
!
__find_symbol
(
"struct_module"
,
&
ksg
,
&
i
,
1
))
if
(
!
__find_symbol
(
"struct_module"
,
&
owner
,
&
crc
,
1
))
BUG
();
return
check_version
(
sechdrs
,
versindex
,
"struct_module"
,
mod
,
ksg
,
i
);
return
check_version
(
sechdrs
,
versindex
,
"struct_module"
,
mod
,
crc
);
}
/* First part is kernel version, which we ignore. */
...
...
@@ -1283,7 +1284,8 @@ static struct module *load_module(void *umod,
mod
->
gpl_crcs
=
(
void
*
)
sechdrs
[
gplcrcindex
].
sh_addr
;
#ifdef CONFIG_MODVERSIONS
if
((
mod
->
num_kallsyms
&&
!
crcindex
)
||
(
mod
->
num_gpl_syms
&&
!
gplcrcindex
))
{
if
((
mod
->
num_syms
&&
!
crcindex
)
||
(
mod
->
num_gpl_syms
&&
!
gplcrcindex
))
{
printk
(
KERN_WARNING
"%s: No versions for exported symbols."
" Tainting kernel.
\n
"
,
mod
->
name
);
tainted
|=
TAINT_FORCED_MODULE
;
...
...
@@ -1309,7 +1311,7 @@ static struct module *load_module(void *umod,
#ifdef CONFIG_KALLSYMS
mod
->
symtab
=
(
void
*
)
sechdrs
[
symindex
].
sh_addr
;
mod
->
num_
kallsyms
=
sechdrs
[
symindex
].
sh_size
/
sizeof
(
Elf_Sym
);
mod
->
num_
symtab
=
sechdrs
[
symindex
].
sh_size
/
sizeof
(
Elf_Sym
);
mod
->
strtab
=
(
void
*
)
sechdrs
[
strindex
].
sh_addr
;
#endif
err
=
module_finalize
(
hdr
,
sechdrs
,
mod
);
...
...
@@ -1452,7 +1454,7 @@ static const char *get_ksymbol(struct module *mod,
/* Scan for closest preceeding symbol, and next symbol. (ELF
starts real symbols at 1). */
for
(
i
=
1
;
i
<
mod
->
num_
kallsyms
;
i
++
)
{
for
(
i
=
1
;
i
<
mod
->
num_
symtab
;
i
++
)
{
if
(
mod
->
symtab
[
i
].
st_shndx
==
SHN_UNDEF
)
continue
;
...
...
scripts/Makefile.modpost
View file @
45f59fc7
...
...
@@ -35,10 +35,11 @@ targets += $(modules)
# Compile version info for unresolved symbols
quiet_cmd_cc_o_c
=
CC
$@
cmd_cc_o_c
=
$(CC)
$(CFLAGS)
$(CFLAGS_MODULE)
-c
-o
$@
$<
cmd_cc_o_c
=
$(CC)
-Wp
,-MD,
$(depfile)
$(CFLAGS)
$(CFLAGS_MODULE)
\
-c
-o
$@
$<
$(modules
:
.ko=.mod.o): %.mod.o: %.mod.c FORCE
$(
call
if_changed,cc_o_c
)
$(
call
if_changed
_dep
,cc_o_c
)
targets
+=
$(modules:.ko=.mod.o)
...
...
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