projects
/
platform
/
kernel
/
u-boot.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
d30b310
)
x86: Correct address casts in interrupt code
author
Simon Glass
<sjg@chromium.org>
Mon, 26 Sep 2016 03:33:25 +0000
(21:33 -0600)
committer
Bin Meng
<bmeng.cn@gmail.com>
Tue, 11 Oct 2016 03:55:33 +0000
(11:55 +0800)
We should cast an address to unsigned long, not u32.
Signed-off-by: Simon Glass <sjg@chromium.org>
Reviewed-by: Bin Meng <bmeng.cn@gmail.com>
arch/x86/cpu/interrupts.c
patch
|
blob
|
history
diff --git
a/arch/x86/cpu/interrupts.c
b/arch/x86/cpu/interrupts.c
index
46babe0
..
5f6cdd3
100644
(file)
--- a/
arch/x86/cpu/interrupts.c
+++ b/
arch/x86/cpu/interrupts.c
@@
-182,8
+182,8
@@
static inline void load_idt(const struct desc_ptr *dtr)
void set_vector(u8 intnum, void *routine)
{
- idt[intnum].base_high = (u16)((u
32
)(routine) >> 16);
- idt[intnum].base_low = (u16)((u
32
)(routine) & 0xffff);
+ idt[intnum].base_high = (u16)((u
long
)(routine) >> 16);
+ idt[intnum].base_low = (u16)((u
long
)(routine) & 0xffff);
}
/*