Skip to content
Toggle navigation
P
Projects
G
Groups
S
Snippets
Help
triazo
/
kernel
This project
Loading...
Sign in
Toggle navigation
Go to a project
Project
Repository
Issues
3
Merge Requests
0
Wiki
Settings
Activity
Graph
Charts
Create a new issue
Commits
Issue Boards
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Commit
7b01b9a2
authored
Oct 13, 2015
by
malcolm
Browse files
Options
_('Browse Files')
Download
Email Patches
Plain Diff
Update idt.c
parent
51ad7510
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
6 additions
and
5 deletions
src/idt.c
src/idt.c
View file @
7b01b9a2
...
...
@@ -33,7 +33,7 @@ idt_desc* get_ir(uint32_t i)
{
if
(
i
>
MAX_IDT_INT
)
{
return
0
;
return
0
;
}
return
&
_idt
[
i
];
}
...
...
@@ -42,11 +42,11 @@ int install_ir(uint32_t i, uint16_t flags, uint16_t code_sel, IRQ_HANDLER irq)
{
if
(
i
>
MAX_IDT_INT
)
{
return
0
;
return
0
;
}
if
(
!
irq
)
{
return
0
;
return
0
;
}
uint64_t
uiBase
=
(
uintptr_t
)(
&
(
*
irq
));
_idt
[
i
].
low_base
=
(
uint16_t
)(
uiBase
&
0xffff
);
...
...
@@ -64,9 +64,9 @@ int idt_init(uint16_t code_sel)
memset
((
void
*
)
&
_idt
[
0
],
0
,
sizeof
(
idt_desc
)
*
MAX_IDT_INT
-
1
);
for
(
int
i
=
0
;
i
<
MAX_IDT_INT
;
i
++
)
{
install_ir
(
i
,
IDT_PR
|
IDT_32
,
code_sel
,
(
IRQ_HANDLER
)
default_handler
);
install_ir
(
i
,
IDT_PR
|
IDT_32
,
code_sel
,
(
IRQ_HANDLER
)
default_handler
);
}
idt_install
();
return
0
;
}
#pragma GCC pop_options
#pragma GCC pop_options
\ No newline at end of file
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