Wait for test server
This commit is contained in:
parent
e9b620220e
commit
5fdea0dabd
@ -31,15 +31,8 @@ void handler(int num)
|
||||
event_get(num, &irs);
|
||||
irs->handler.routine(irs->id, irs->data);
|
||||
}
|
||||
}
|
||||
|
||||
void handler_err(int err, int num)
|
||||
{
|
||||
o_event *irs;
|
||||
|
||||
if (event_exist(num) == ERROR_TRUE)
|
||||
{
|
||||
event_get(num, &irs);
|
||||
irs->handler.routine(irs->id, irs->data);
|
||||
}
|
||||
if (num >= ARCHITECTURE_IDT_IRQ_BASE &&
|
||||
num < ARCHITECTURE_IDT_IRQ_SIZE + ARCHITECTURE_IDT_IRQ_BASE)
|
||||
platform_pic_acknowledge(num - ARCHITECTURE_IDT_IRQ_BASE);
|
||||
}
|
||||
|
File diff suppressed because it is too large
Load Diff
@ -22,16 +22,16 @@ do
|
||||
echo " push %fs" >> $FILEOUT
|
||||
echo " push %gs" >> $FILEOUT
|
||||
echo " push %ss" >> $FILEOUT
|
||||
echo " push \$$i" >> $FILEOUT
|
||||
|
||||
if [ $i -eq 8 ] || [ $i -eq 17 ] || ( [ $i -ge 10 ] && [ $i -lt 15 ])
|
||||
then
|
||||
echo " push \$0" >> $FILEOUT
|
||||
echo " call handler_err" >> $FILEOUT
|
||||
echo " pop %ebx" >> $FILEOUT
|
||||
else
|
||||
echo " mov \$0x10, %ax" >> $FILEOUT
|
||||
echo " mov %ax, %ds" >> $FILEOUT
|
||||
echo " mov %ax, %es" >> $FILEOUT
|
||||
echo " mov %ax, %fs" >> $FILEOUT
|
||||
echo " mov %ax, %gs" >> $FILEOUT
|
||||
echo " mov %ax, %ss" >> $FILEOUT
|
||||
|
||||
echo " push \$$i" >> $FILEOUT
|
||||
echo " call handler" >> $FILEOUT
|
||||
fi
|
||||
echo " pop %ebx" >> $FILEOUT
|
||||
echo " pop %ss" >> $FILEOUT
|
||||
echo " pop %gs" >> $FILEOUT
|
||||
@ -39,6 +39,10 @@ do
|
||||
echo " pop %es" >> $FILEOUT
|
||||
echo " pop %ds" >> $FILEOUT
|
||||
echo " popa" >> $FILEOUT
|
||||
if [ $i -eq 8 ] || [ $i -eq 17 ] || ( [ $i -ge 10 ] && [ $i -lt 15 ])
|
||||
then
|
||||
echo " add \$4, %esp" >> $FILEOUT
|
||||
fi
|
||||
echo " sti" >> $FILEOUT
|
||||
echo " iret" >> $FILEOUT
|
||||
echo "" >> $FILEOUT
|
||||
|
@ -55,8 +55,6 @@
|
||||
|
||||
void handler(int num);
|
||||
|
||||
void handler_err(int err, int num);
|
||||
|
||||
|
||||
/*
|
||||
* eop
|
||||
|
@ -39,8 +39,8 @@ d_event glue_event_dispatch =
|
||||
NULL,
|
||||
glue_event_enable,
|
||||
glue_event_disable,
|
||||
NULL,
|
||||
NULL,
|
||||
glue_event_reserve,
|
||||
glue_event_release,
|
||||
glue_event_initialize,
|
||||
NULL
|
||||
};
|
||||
@ -65,6 +65,28 @@ t_error glue_event_disable(void)
|
||||
MACHINE_LEAVE();
|
||||
}
|
||||
|
||||
t_error glue_event_reserve(i_event id,
|
||||
t_type type,
|
||||
u_event_handler h,
|
||||
t_data data)
|
||||
{
|
||||
if (id >= ARCHITECTURE_IDT_IRQ_BASE &&
|
||||
id < ARCHITECTURE_IDT_IRQ_SIZE + ARCHITECTURE_IDT_IRQ_BASE)
|
||||
platform_pic_enable(id - ARCHITECTURE_IDT_IRQ_BASE);
|
||||
|
||||
|
||||
MACHINE_LEAVE();
|
||||
}
|
||||
|
||||
t_error glue_event_release(i_event id)
|
||||
{
|
||||
if (id >= ARCHITECTURE_IDT_IRQ_BASE &&
|
||||
id < ARCHITECTURE_IDT_IRQ_SIZE + ARCHITECTURE_IDT_IRQ_BASE)
|
||||
platform_pic_disable(id - ARCHITECTURE_IDT_IRQ_BASE);
|
||||
|
||||
MACHINE_LEAVE();
|
||||
}
|
||||
|
||||
t_error glue_event_initialize(void)
|
||||
{
|
||||
t_uint16 i;
|
||||
|
@ -79,6 +79,13 @@ t_error glue_event_enable(void);
|
||||
|
||||
t_error glue_event_disable(void);
|
||||
|
||||
t_error glue_event_reserve(i_event id,
|
||||
t_type type,
|
||||
u_event_handler h,
|
||||
t_data data);
|
||||
|
||||
t_error glue_event_release(i_event id);
|
||||
|
||||
t_error glue_event_initialize(void);
|
||||
|
||||
|
||||
|
Reference in New Issue
Block a user